2003-02-17 Yoshinori K. Okuji <okuji@enbug.org>

* lib/device.c (check_device): If DEVICE is empty, just return
	1.
	(get_scsi_disk_name) [__QNXNTO__]: Make NAME empty, because SCSI
	disks are detected as IDE disks on QNX RTP.

	From Taketo Kabe <kabe@sra-tohoku.co.jp>:
	* lib/device.c (get_ide_disk_name) [__QNXNTO__]: Set NAME to
	"/dev/hdX".
	(get_floppy_disk_name) [__QNXNTO__]: Set NAME to "/dev/fdX".
	* stage2/mb_info.h (struct AddrRangeDesc): Specified with the
	attribute packed.
	* stage2/shared.h (struct mmar_desc): Likewise.
This commit is contained in:
okuji 2003-02-17 12:35:30 +00:00
parent da7278fc6d
commit cd23d85031
8 changed files with 41 additions and 7 deletions

View file

@ -1,3 +1,18 @@
2003-02-17 Yoshinori K. Okuji <okuji@enbug.org>
* lib/device.c (check_device): If DEVICE is empty, just return
1.
(get_scsi_disk_name) [__QNXNTO__]: Make NAME empty, because SCSI
disks are detected as IDE disks on QNX RTP.
From Taketo Kabe <kabe@sra-tohoku.co.jp>:
* lib/device.c (get_ide_disk_name) [__QNXNTO__]: Set NAME to
"/dev/hdX".
(get_floppy_disk_name) [__QNXNTO__]: Set NAME to "/dev/fdX".
* stage2/mb_info.h (struct AddrRangeDesc): Specified with the
attribute packed.
* stage2/shared.h (struct mmar_desc): Likewise.
2003-01-29 Yoshinori K. Okuji <okuji@enbug.org>
From Ilguiz Latypov:

1
NEWS
View file

@ -7,6 +7,7 @@ New:
* Add a workaround for buggy BIOSes (notably HP Vectra series) which
don't pass the boot drive correctly.
* Display "GNU GRUB" instead of "GRUB" in the menu.
* Add support QNX RTP into the grub shell.
New in 0.93 - 2002-12-08:
* Define the behavior of the boot loader when the load end address is

1
THANKS
View file

@ -91,6 +91,7 @@ Stefan Ondrejicka <ondrej@idata.sk>
Stephen Early <steve@greenend.org.uk>
Steven Dick <ssd.gnu@mmae.ucf.edu>
Takehiro Suzuki <takehiro@coral.ocn.ne.jp>
Taketo Kabe <kabe@sra-tohoku.co.jp>
Thierry DELHAISE <thierry.delhaise@delhaise.com>
Thierry Laronde <thierry.laronde@polynum.com>
Thomas Schweikle <tschweikle@fiducia.de>

View file

@ -1,5 +1,5 @@
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.23.
.TH GRUB "8" "January 2003" "grub (GNU GRUB 0.93)" FSF
.TH GRUB "8" "February 2003" "grub (GNU GRUB 0.93)" FSF
.SH NAME
grub \- the grub shell
.SH SYNOPSIS

View file

@ -1,5 +1,5 @@
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.23.
.TH MBCHK "1" "January 2003" "mbchk (GNU GRUB 0.93)" FSF
.TH MBCHK "1" "February 2003" "mbchk (GNU GRUB 0.93)" FSF
.SH NAME
mbchk \- check the format of a Multiboot kernel
.SH SYNOPSIS

View file

@ -1,7 +1,7 @@
/* device.c - Some helper functions for OS devices and BIOS drives */
/*
* GRUB -- GRand Unified Bootloader
* Copyright (C) 1999,2000,2001,2002 Free Software Foundation, Inc.
* Copyright (C) 1999,2000,2001,2002,2003 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -208,6 +208,9 @@ get_floppy_disk_name (char *name, int unit)
#elif defined(__OpenBSD__)
/* OpenBSD */
sprintf (name, "/dev/rfd%dc", unit);
#elif defined(__QNXNTO__)
/* QNX RTP */
sprintf (name, "/dev/fd%d", unit);
#else
# warning "BIOS floppy drives cannot be guessed in your operating system."
/* Set NAME to a bogus string. */
@ -245,6 +248,11 @@ get_ide_disk_name (char *name, int unit)
#elif defined(__OpenBSD__)
/* OpenBSD */
sprintf (name, "/dev/rwd%dc", unit);
#elif defined(__QNXNTO__)
/* QNX RTP */
/* Actually, QNX RTP doesn't distinguish IDE from SCSI, so this could
contain SCSI disks. */
sprintf (name, "/dev/hd%d", unit);
#else
# warning "BIOS IDE drives cannot be guessed in your operating system."
/* Set NAME to a bogus string. */
@ -278,6 +286,11 @@ get_scsi_disk_name (char *name, int unit)
#elif defined(__OpenBSD__)
/* OpenBSD */
sprintf (name, "/dev/rsd%dc", unit);
#elif defined(__QNXNTO__)
/* QNX RTP */
/* QNX RTP doesn't distinguish SCSI from IDE, so it is better to
disable the detection of SCSI disks here. */
*name = 0;
#else
# warning "BIOS SCSI drives cannot be guessed in your operating system."
/* Set NAME to a bogus string. */
@ -301,6 +314,10 @@ check_device (const char *device)
char buf[512];
FILE *fp;
/* If DEVICE is empty, just return 1. */
if (*device == 0)
return 1;
fp = fopen (device, "r");
if (! fp)
{

View file

@ -1,6 +1,6 @@
/*
* GRUB -- GRand Unified Bootloader
* Copyright (C) 2000 Free Software Foundation, Inc.
* Copyright (C) 2000,2003 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -50,7 +50,7 @@ struct AddrRangeDesc
unsigned long Type;
/* unspecified optional padding... */
};
} __attribute__ ((packed));
/* usable memory "Type", all others are reserved. */
#define MB_ARD_MEMORY 1

View file

@ -1,7 +1,7 @@
/* shared.h - definitions used in all GRUB-specific code */
/*
* GRUB -- GRand Unified Bootloader
* Copyright (C) 1999,2000,2001,2002 Free Software Foundation, Inc.
* Copyright (C) 1999,2000,2001,2002,2003 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -412,7 +412,7 @@ struct mmar_desc
unsigned long long addr; /* Base address. */
unsigned long long length; /* Length in bytes. */
unsigned long type; /* Type of address range. */
};
} __attribute__ ((packed));
/* VBE controller information. */
struct vbe_controller