kernel: trap-dependent state restore, trace fixes
[minix.git] / kernel / kernel.h
blobf205b6785f6a9311205ad93b1a8c6300e9886c9c
1 #ifndef KERNEL_H
2 #define KERNEL_H
4 /* boot verbose */
5 #define CONFIG_BOOT_VERBOSE
7 #ifndef CONFIG_MAX_CPUS
8 #define CONFIG_MAX_CPUS 1
9 #endif
11 /* OXPCIe952 PCIe with 2 UARTs in-kernel support */
12 #define CONFIG_OXPCIE 0
14 /* This is the master header for the kernel. It includes some other files
15 * and defines the principal constants.
17 #define _POSIX_SOURCE 1 /* tell headers to include POSIX stuff */
18 #define _MINIX 1 /* tell headers to include MINIX stuff */
19 #define _SYSTEM 1 /* tell headers that this is the kernel */
22 * we need the defines above in assembly files to configure the kernel
23 * correctly. However we don't need the rest
25 #ifndef __ASSEMBLY__
27 /* The following are so basic, all the *.c files get them automatically. */
28 #include <minix/config.h> /* global configuration, MUST be first */
29 #include <sys/types.h> /* general system types */
30 #include <minix/const.h> /* MINIX specific constants */
31 #include <minix/type.h> /* MINIX specific types, e.g. message */
32 #include <minix/ipc.h> /* MINIX run-time system */
33 #include <minix/sysutil.h> /* MINIX utility library functions */
34 #include <timers.h> /* watchdog timer management */
35 #include <errno.h> /* return codes and error numbers */
36 #include <sys/param.h>
37 #include <minix/param.h>
39 /* Important kernel header files. */
40 #include "config.h" /* configuration, MUST be first */
41 #include "const.h" /* constants, MUST be second */
42 #include "type.h" /* type definitions, MUST be third */
43 #include "proto.h" /* function prototypes */
44 #include "glo.h" /* global variables */
45 #include "ipc.h" /* IPC constants */
46 #include "profile.h" /* system profiling */
47 #include "proc.h" /* process table */
48 #include "cpulocals.h" /* CPU-local variables */
49 #include "debug.h" /* debugging, MUST be last kernel header */
51 #ifndef CONFIG_SMP
52 /* We only support 1 cpu now */
53 #define CONFIG_MAX_CPUS 1
54 #define cpuid 0
55 /* this is always true on an uniprocessor */
56 #define cpu_is_bsp(x) 1
58 #else
60 #include "smp.h"
62 #endif
64 #endif /* __ASSEMBLY__ */
66 #endif /* KERNEL_H */