Module Name: src
Committed By: maxv
Date: Sun Jun 5 14:06:31 UTC 2016
Modified Files:
src/sys/arch/i386/stand/lib: biosdisk.c exec.c
Log Message:
The bootinfo is refreshed each time the bootloader tries to execute a
kernel, so there's no point in using this global variable. Because of
this variable, only one "boot" command can be issued in the prompt, and
you have to reboot the machine if you mistyped the kernel name.
To generate a diff of this commit:
cvs rdiff -u -r1.44 -r1.45 src/sys/arch/i386/stand/lib/biosdisk.c
cvs rdiff -u -r1.59 -r1.60 src/sys/arch/i386/stand/lib/exec.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/i386/stand/lib/biosdisk.c
diff -u src/sys/arch/i386/stand/lib/biosdisk.c:1.44 src/sys/arch/i386/stand/lib/biosdisk.c:1.45
--- src/sys/arch/i386/stand/lib/biosdisk.c:1.44 Sun Jan 18 20:18:07 2015
+++ src/sys/arch/i386/stand/lib/biosdisk.c Sun Jun 5 14:06:31 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: biosdisk.c,v 1.44 2015/01/18 20:18:07 jakllsch Exp $ */
+/* $NetBSD: biosdisk.c,v 1.45 2016/06/05 14:06:31 maxv Exp $ */
/*
* Copyright (c) 1996, 1998
@@ -701,24 +701,13 @@ biosdisk_findpartition(int biosdev, dadd
static void
add_biosdisk_bootinfo(void)
{
- static bool done;
-
if (bootinfo == NULL) {
- done = false;
return;
}
-
- if (done)
- return;
-
BI_ADD(&bi_disk, BTINFO_BOOTDISK, sizeof(bi_disk));
BI_ADD(&bi_wedge, BTINFO_BOOTWEDGE, sizeof(bi_wedge));
-
- done = true;
-
return;
}
-
#endif
int
Index: src/sys/arch/i386/stand/lib/exec.c
diff -u src/sys/arch/i386/stand/lib/exec.c:1.59 src/sys/arch/i386/stand/lib/exec.c:1.60
--- src/sys/arch/i386/stand/lib/exec.c:1.59 Sun Apr 6 19:18:00 2014
+++ src/sys/arch/i386/stand/lib/exec.c Sun Jun 5 14:06:31 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: exec.c,v 1.59 2014/04/06 19:18:00 jakllsch Exp $ */
+/* $NetBSD: exec.c,v 1.60 2016/06/05 14:06:31 maxv Exp $ */
/*-
* Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
@@ -411,7 +411,7 @@ exec_netbsd(const char *file, physaddr_t
out:
BI_FREE();
- bootinfo = 0;
+ bootinfo = NULL;
return -1;
}