Subversion Repositories HelenOS-historic

Compare Revisions

Ignore whitespace Rev 663 → Rev 664

/kernel/trunk/generic/include/interrupt.h
30,12 → 30,15
#define __INTERRUPT_H__
 
#include <arch/interrupt.h>
#include <typedefs.h>
 
#ifndef IVT_ITEMS
# define IVT_ITEMS 0
# define IVT_ITEMS 0
#endif
 
typedef void (* iroutine)(int n, void *stack);
#ifndef IVT_FIRST
# define IVT_FIRST 0
#endif
 
extern iroutine exc_register(int n, const char *name, iroutine f);
extern void exc_dispatch(int n, void *stack);
/kernel/trunk/generic/include/typedefs.h
86,4 → 86,6
typedef struct cmd_arg cmd_arg_t;
typedef struct cmd_info cmd_info_t;
 
typedef void (* iroutine)(int n, void *stack);
 
#endif
/kernel/trunk/generic/src/interrupt/interrupt.c
74,7 → 74,7
{
ASSERT(n < IVT_ITEMS);
exc_table[n].f(n, stack);
exc_table[n].f(n + IVT_FIRST, stack);
}
 
/** Default 'null' exception handler */
83,7 → 83,7
panic("Unhandled exception %d.", n);
}
 
/** KConsole cmd - print all exceptions */
/** kconsole cmd - print all exceptions */
static int exc_print_cmd(cmd_arg_t *argv)
{
int i;
95,7 → 95,7
symbol = get_symtab_entry((__native)exc_table[i].f);
if (!symbol)
symbol = "not found";
printf("%d %s 0x%p(%s)\n",i,exc_table[i].name,
printf("%d %s 0x%p(%s)\n", i + IVT_FIRST, exc_table[i].name,
exc_table[i].f,symbol);
if (!((i+1) % 20)) {
printf("Press any key to continue.");