Signed-off-by: Luca Dariz <l...@orpolo.org> --- device/cirbuf.c | 4 ++-- i386/i386/debug_i386.c | 1 + i386/i386at/biosmem.c | 2 -- i386/i386at/com.c | 2 +- i386/i386at/mem.c | 1 + kern/boot_script.c | 1 + kern/bootstrap.h | 5 ++++- kern/exception.c | 1 + vm/vm_debug.c | 1 + vm/vm_map.c | 2 +- vm/vm_page.c | 2 -- vm/vm_pageout.c | 2 -- 12 files changed, 13 insertions(+), 11 deletions(-)
diff --git a/device/cirbuf.c b/device/cirbuf.c index 391297ce..a3c9407a 100644 --- a/device/cirbuf.c +++ b/device/cirbuf.c @@ -51,10 +51,10 @@ void cb_check(struct cirbuf *cb) { if (!(cb->c_cf >= cb->c_start && cb->c_cf < cb->c_end)) - panic("cf %x out of range [%x..%x)", + panic("cf %p out of range [%p..%p)", cb->c_cf, cb->c_start, cb->c_end); if (!(cb->c_cl >= cb->c_start && cb->c_cl < cb->c_end)) - panic("cl %x out of range [%x..%x)", + panic("cl %p out of range [%p..%p)", cb->c_cl, cb->c_start, cb->c_end); if (cb->c_cf <= cb->c_cl) { if (!(cb->c_cc == cb->c_cl - cb->c_cf)) diff --git a/i386/i386/debug_i386.c b/i386/i386/debug_i386.c index 233caa72..4b8804cd 100644 --- a/i386/i386/debug_i386.c +++ b/i386/i386/debug_i386.c @@ -26,6 +26,7 @@ #include "thread.h" #include "trap.h" #include "debug.h" +#include "spl.h" void dump_ss(const struct i386_saved_state *st) { diff --git a/i386/i386at/biosmem.c b/i386/i386at/biosmem.c index 78e7bb21..fafdc048 100644 --- a/i386/i386at/biosmem.c +++ b/i386/i386at/biosmem.c @@ -29,8 +29,6 @@ #include <sys/types.h> #include <vm/vm_page.h> -#define DEBUG 0 - #define __boot #define __bootdata #define __init diff --git a/i386/i386at/com.c b/i386/i386at/com.c index 1f305b23..d5842d8f 100644 --- a/i386/i386at/com.c +++ b/i386/i386at/com.c @@ -191,7 +191,7 @@ comcnprobe(struct consdev *cp) if (strncmp(kernel_cmdline, CONSOLE_PARAMETER + 1, strlen(CONSOLE_PARAMETER) - 1) == 0) - mach_atoi(kernel_cmdline + strlen(CONSOLE_PARAMETER) - 1, + mach_atoi((u_char*)kernel_cmdline + strlen(CONSOLE_PARAMETER) - 1, &rcline); maj = 0; diff --git a/i386/i386at/mem.c b/i386/i386at/mem.c index 07acc169..ac0fd301 100644 --- a/i386/i386at/mem.c +++ b/i386/i386at/mem.c @@ -26,6 +26,7 @@ #include <device/io_req.h> #include <i386/model_dep.h> +#include <i386at/biosmem.h> /* This provides access to any memory that is not main RAM */ diff --git a/kern/boot_script.c b/kern/boot_script.c index 9e8f60a7..7e31075f 100644 --- a/kern/boot_script.c +++ b/kern/boot_script.c @@ -6,6 +6,7 @@ #include <string.h> #include <kern/printf.h> #include "boot_script.h" +#include "bootstrap.h" /* This structure describes a symbol. */ diff --git a/kern/bootstrap.h b/kern/bootstrap.h index b8ed8d9f..edf1f7f4 100644 --- a/kern/bootstrap.h +++ b/kern/bootstrap.h @@ -19,6 +19,9 @@ #ifndef _KERN_BOOTSTRAP_H_ #define _KERN_BOOTSTRAP_H_ -extern void bootstrap_create(void); +#include <kern/boot_script.h> + +void bootstrap_create(void); +int boot_script_ramdisk_create(struct cmd *cmd, char **name); #endif /* _KERN_BOOTSTRAP_H_ */ diff --git a/kern/exception.c b/kern/exception.c index 246c1419..6a812490 100644 --- a/kern/exception.c +++ b/kern/exception.c @@ -45,6 +45,7 @@ #include <kern/task.h> #include <kern/thread.h> #include <kern/processor.h> +#include <kern/printf.h> #include <kern/sched.h> #include <kern/sched_prim.h> #include <kern/exception.h> diff --git a/vm/vm_debug.c b/vm/vm_debug.c index 2dff2296..4b5c1521 100644 --- a/vm/vm_debug.c +++ b/vm/vm_debug.c @@ -48,6 +48,7 @@ #include <vm/vm_object.h> #include <kern/task.h> #include <kern/host.h> +#include <kern/printf.h> #include <ipc/ipc_port.h> diff --git a/vm/vm_map.c b/vm/vm_map.c index 7fe3e141..9f5eb13d 100644 --- a/vm/vm_map.c +++ b/vm/vm_map.c @@ -737,7 +737,7 @@ restart: max_size = size + mask; if (max_size < size) { - printf("max_size %x got smaller than size %x with mask %lx\n", + printf("max_size %lx got smaller than size %lx with mask %lx\n", max_size, size, mask); goto error; } diff --git a/vm/vm_page.c b/vm/vm_page.c index 06d62c97..f8b9afb1 100644 --- a/vm/vm_page.c +++ b/vm/vm_page.c @@ -48,8 +48,6 @@ #include <vm/vm_page.h> #include <vm/vm_pageout.h> -#define DEBUG 0 - #define __init #define __initdata #define __read_mostly diff --git a/vm/vm_pageout.c b/vm/vm_pageout.c index 575a9f5d..5e7bcff7 100644 --- a/vm/vm_pageout.c +++ b/vm/vm_pageout.c @@ -55,8 +55,6 @@ #include <vm/vm_pageout.h> #include <machine/locore.h> -#define DEBUG 0 - /* * Maximum delay, in milliseconds, between two pageout scans. */ -- 2.30.2