diff --git a/ChangeLog b/ChangeLog index 0160dced1..d7b2c3f30 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2001-12-10 Yoshinori K. Okuji + + * stage2/shared.h (ERR_NO_DISK_SPACE): New constant. + * stage2/common.c (err_list): Added an entry for + ERR_NO_DISK_SPACE. + * docs/grub.texi (Stage2 errors): Added the description. + * stage2/builtins.c (embed_func): Use ERR_NO_DISK_SPACE instead + of ERR_DEV_VALUES when the spare space is too small. Suggested + by Eric Mumpower . + 2001-12-10 Yoshinori K. Okuji * grub/asmstub.c: Include . diff --git a/docs/grub.texi b/docs/grub.texi index c32313241..7daa65c2d 100644 --- a/docs/grub.texi +++ b/docs/grub.texi @@ -3056,6 +3056,12 @@ enter a correct password before running such an entry. @item 33 : Serial device not configured This error is returned if you try to change your terminal to a serial one before initializing any serial device. + +@item 34 : No spare sectors on the disk +This error is returned if a disk doesn't have enough spare space. This +happens when you try to embed Stage 1.5 into the unused sectors after +the MBR, but the first partition starts right after the MBR or they are +used by EZ-BIOS. @end table diff --git a/docs/mbchk.1 b/docs/mbchk.1 index a611a29cd..5e395229e 100644 --- a/docs/mbchk.1 +++ b/docs/mbchk.1 @@ -1,5 +1,5 @@ .\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.23. -.TH MBCHK "1" "November 2001" "mbchk (GNU GRUB 0.90)" FSF +.TH MBCHK "1" "December 2001" "mbchk (GNU GRUB 0.90)" FSF .SH NAME mbchk \- check the format of a Multiboot kernel .SH SYNOPSIS diff --git a/docs/stamp-vti b/docs/stamp-vti index c81ca723b..0889a637a 100644 --- a/docs/stamp-vti +++ b/docs/stamp-vti @@ -1,4 +1,4 @@ -@set UPDATED 12 November 2001 -@set UPDATED-MONTH November 2001 +@set UPDATED 10 December 2001 +@set UPDATED-MONTH December 2001 @set EDITION 0.90 @set VERSION 0.90 diff --git a/docs/version.texi b/docs/version.texi index c81ca723b..0889a637a 100644 --- a/docs/version.texi +++ b/docs/version.texi @@ -1,4 +1,4 @@ -@set UPDATED 12 November 2001 -@set UPDATED-MONTH November 2001 +@set UPDATED 10 December 2001 +@set UPDATED-MONTH December 2001 @set EDITION 0.90 @set VERSION 0.90 diff --git a/stage2/builtins.c b/stage2/builtins.c index 8b546d020..976dfd6cc 100644 --- a/stage2/builtins.c +++ b/stage2/builtins.c @@ -1034,7 +1034,7 @@ embed_func (char *arg, int flags) /* Check if the disk can store the Stage 1.5. */ if (PC_SLICE_START (mbr, 0) - 1 < size) { - errnum = ERR_DEV_VALUES; + errnum = ERR_NO_DISK_SPACE; return 1; } @@ -1051,7 +1051,7 @@ embed_func (char *arg, int flags) /* The space after the MBR is used by EZ-BIOS which we must * not overwrite. */ - errnum = ERR_DEV_VALUES; + errnum = ERR_NO_DISK_SPACE; return 1; } diff --git a/stage2/common.c b/stage2/common.c index b50f43d1e..c47be49b7 100644 --- a/stage2/common.c +++ b/stage2/common.c @@ -74,6 +74,7 @@ char *err_list[] = [ERR_NEED_MB_KERNEL] = "Multiboot kernel must be loaded before modules", [ERR_NEED_SERIAL] = "Serial device not configured", [ERR_NO_DISK] = "Selected disk does not exist", + [ERR_NO_DISK_SPACE] = "No spare sectors on the disk", [ERR_NO_PART] = "No such partition", [ERR_NUMBER_PARSING] = "Error while parsing number", [ERR_OUTSIDE_PART] = "Attempt to access block outside partition", diff --git a/stage2/shared.h b/stage2/shared.h index f12457a50..8b050e3fe 100644 --- a/stage2/shared.h +++ b/stage2/shared.h @@ -547,6 +547,7 @@ typedef enum ERR_UNALIGNED, ERR_PRIVILEGED, ERR_NEED_SERIAL, + ERR_NO_DISK_SPACE, MAX_ERR_NUM } grub_error_t;