diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/i386/include/biosvar.h | 6 | ||||
-rw-r--r-- | sys/arch/i386/stand/boot/kentry.c | 22 | ||||
-rw-r--r-- | sys/arch/i386/stand/libsa/libsa.h | 5 |
3 files changed, 22 insertions, 11 deletions
diff --git a/sys/arch/i386/include/biosvar.h b/sys/arch/i386/include/biosvar.h index 2ebedc1e8d6..e19ee16a37f 100644 --- a/sys/arch/i386/include/biosvar.h +++ b/sys/arch/i386/include/biosvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: biosvar.h,v 1.4 1997/08/02 22:25:30 mickey Exp $ */ +/* $OpenBSD: biosvar.h,v 1.5 1997/08/05 17:45:55 mickey Exp $ */ /* * Copyright (c) 1997 Michael Shalayeff @@ -40,7 +40,7 @@ #define BOOTC_GETENV 0x02 #define BOOTC_SETENV 0x03 #define BOOTV_BOOTDEV 1 -#define BOOTV_BDGEOM 2 +#define BOOTV_BDGMTRY 2 #define BOOTV_CONSDEV 3 #define BOOTV_APMCONN 4 #define BOOTC_GETC 0x10 @@ -211,8 +211,6 @@ extern struct BIOS_regs { u_int32_t biosr_es; } BIOS_regs; -int kentry __P((u_int, void *)); - #ifdef _KERNEL #include <machine/bus.h> diff --git a/sys/arch/i386/stand/boot/kentry.c b/sys/arch/i386/stand/boot/kentry.c index 6a8be5eda5d..09e7814d8bc 100644 --- a/sys/arch/i386/stand/boot/kentry.c +++ b/sys/arch/i386/stand/boot/kentry.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kentry.c,v 1.1 1997/08/02 22:23:08 mickey Exp $ */ +/* $OpenBSD: kentry.c,v 1.2 1997/08/05 17:45:55 mickey Exp $ */ /* * Copyright (c) 1997 Michael Shalayeff @@ -34,23 +34,35 @@ #include <sys/param.h> #include <machine/biosvar.h> +#include <libsa.h> #include "cmd.h" int -kentry(cmd, data) +kentry(cmd, arg) u_int cmd; - void *data; + u_int arg; { switch(cmd) { case BOOTC_CHECK: return 0; case BOOTC_BOOT: + exit(); return 0; case BOOTC_GETENV: + switch(arg) { + case BOOTV_BOOTDEV: + return bootdev; + case BOOTV_BDGMTRY: + return bootdev_geometry; + case BOOTV_CONSDEV: + return consdev; + case BOOTV_APMCONN: + return (int)&apminfo; + } return 0; case BOOTC_SETENV: return 0; + default: + return -1; } - - return -1; } diff --git a/sys/arch/i386/stand/libsa/libsa.h b/sys/arch/i386/stand/libsa/libsa.h index d070ba276e1..ba1f5570cf4 100644 --- a/sys/arch/i386/stand/libsa/libsa.h +++ b/sys/arch/i386/stand/libsa/libsa.h @@ -1,4 +1,4 @@ -/* $OpenBSD: libsa.h,v 1.10 1997/08/04 21:53:35 mickey Exp $ */ +/* $OpenBSD: libsa.h,v 1.11 1997/08/05 17:45:56 mickey Exp $ */ /* * Copyright (c) 1996 Michael Shalayeff @@ -40,7 +40,8 @@ void devboot __P((dev_t, char *)); void *alloca __P((size_t)); void machdep __P((void)); u_int apm_init __P((void)); - +int kentry __P((u_int, u_int)); + extern int boothowto; /* XXX filled in assumption that last file opened is kernel */ extern int bootdev, bootdev_geometry; |