2002-01-08 Yoshinori K. Okuji <okuji@gnu.org>
* stage2/common.c [SUPPORT_DISKLESS] (setup_diskless_environment): Removed. The feature is moved to the preset menu. * stage2/stage2.c [SUPPORT_DISKLESS] (preset_menu): Set to the string "bootp\n". [SUPPORT_DISKLESS] (preset_menu_offset): Defined, as if PRESET_MENU_STRING is defined. [SUPPORT_DISKLESS] (open_preset_menu): Likewise. [SUPPORT_DISKLESS] (read_from_preset_menu): Likewise. [SUPPORT_DISKLESS] (close_preset_menu): Likewise.
This commit is contained in:
parent
686f75d678
commit
843ddd9712
3 changed files with 22 additions and 28 deletions
13
ChangeLog
13
ChangeLog
|
@ -1,3 +1,16 @@
|
||||||
|
2002-01-08 Yoshinori K. Okuji <okuji@gnu.org>
|
||||||
|
|
||||||
|
* stage2/common.c [SUPPORT_DISKLESS]
|
||||||
|
(setup_diskless_environment): Removed. The feature is moved to
|
||||||
|
the preset menu.
|
||||||
|
* stage2/stage2.c [SUPPORT_DISKLESS] (preset_menu): Set to the
|
||||||
|
string "bootp\n".
|
||||||
|
[SUPPORT_DISKLESS] (preset_menu_offset): Defined, as if
|
||||||
|
PRESET_MENU_STRING is defined.
|
||||||
|
[SUPPORT_DISKLESS] (open_preset_menu): Likewise.
|
||||||
|
[SUPPORT_DISKLESS] (read_from_preset_menu): Likewise.
|
||||||
|
[SUPPORT_DISKLESS] (close_preset_menu): Likewise.
|
||||||
|
|
||||||
2002-01-06 Yoshinori K. Okuji <okuji@gnu.org>
|
2002-01-06 Yoshinori K. Okuji <okuji@gnu.org>
|
||||||
|
|
||||||
The preset menu has a priority over the configuration file.
|
The preset menu has a priority over the configuration file.
|
||||||
|
|
|
@ -135,25 +135,6 @@ mmap_avail_at (unsigned long bottom)
|
||||||
}
|
}
|
||||||
#endif /* ! STAGE1_5 */
|
#endif /* ! STAGE1_5 */
|
||||||
|
|
||||||
#ifdef SUPPORT_DISKLESS
|
|
||||||
/* Set up the diskless environment so that GRUB can get a configuration
|
|
||||||
file from a network. */
|
|
||||||
static int
|
|
||||||
setup_diskless_environment (void)
|
|
||||||
{
|
|
||||||
/* For now, there is no difference between BOOTP and DHCP in GRUB. */
|
|
||||||
if (! bootp ())
|
|
||||||
{
|
|
||||||
grub_printf ("BOOTP/DHCP fails.\n");
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* This will be erased soon, though... */
|
|
||||||
print_network_configuration ();
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
#endif /* SUPPORT_DISKLESS */
|
|
||||||
|
|
||||||
/* This queries for BIOS information. */
|
/* This queries for BIOS information. */
|
||||||
void
|
void
|
||||||
init_bios_info (void)
|
init_bios_info (void)
|
||||||
|
@ -333,12 +314,6 @@ init_bios_info (void)
|
||||||
|
|
||||||
#endif /* STAGE1_5 */
|
#endif /* STAGE1_5 */
|
||||||
|
|
||||||
#ifdef SUPPORT_DISKLESS
|
|
||||||
/* If SUPPORT_DISKLESS is defined, initialize the network here. */
|
|
||||||
if (! setup_diskless_environment ())
|
|
||||||
return;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Set boot drive and partition. */
|
/* Set boot drive and partition. */
|
||||||
saved_drive = boot_drive;
|
saved_drive = boot_drive;
|
||||||
saved_partition = install_partition;
|
saved_partition = install_partition;
|
||||||
|
|
|
@ -21,9 +21,15 @@
|
||||||
|
|
||||||
grub_jmp_buf restart_env;
|
grub_jmp_buf restart_env;
|
||||||
|
|
||||||
#ifdef PRESET_MENU_STRING
|
#if defined(PRESET_MENU_STRING) || defined(SUPPORT_DISKLESS)
|
||||||
|
|
||||||
|
# if defined(PRESET_MENU_STRING)
|
||||||
static const char *preset_menu = PRESET_MENU_STRING;
|
static const char *preset_menu = PRESET_MENU_STRING;
|
||||||
|
# elif defined(SUPPORT_DISKLESS)
|
||||||
|
/* Execute the command "bootp" automatically. */
|
||||||
|
static const char *preset_menu = "bootp\n";
|
||||||
|
# endif /* SUPPORT_DISKLESS */
|
||||||
|
|
||||||
static int preset_menu_offset;
|
static int preset_menu_offset;
|
||||||
|
|
||||||
static int
|
static int
|
||||||
|
@ -54,13 +60,13 @@ close_preset_menu (void)
|
||||||
preset_menu = 0;
|
preset_menu = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#else /* ! PRESET_MENU_STRING */
|
#else /* ! PRESET_MENU_STRING && ! SUPPORT_DISKLESS */
|
||||||
|
|
||||||
#define open_preset_menu() 0
|
#define open_preset_menu() 0
|
||||||
#define read_from_preset_menu(buf, maxlen) 0
|
#define read_from_preset_menu(buf, maxlen) 0
|
||||||
#define close_preset_menu()
|
#define close_preset_menu()
|
||||||
|
|
||||||
#endif /* ! PRESET_MENU_STRING */
|
#endif /* ! PRESET_MENU_STRING && ! SUPPORT_DISKLESS */
|
||||||
|
|
||||||
|
|
||||||
static char *
|
static char *
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue