296 |
boot_drive = saved_drive; |
boot_drive = saved_drive; |
297 |
|
|
298 |
/* Copy the boot partition information to 0x7be-0x7fd, if |
/* Copy the boot partition information to 0x7be-0x7fd, if |
299 |
BOOT_DRIVE is a hard disk drive. */ |
BOOT_DRIVE is a hard disk drive and the address of the boot |
300 |
if (boot_drive & 0x80) |
partition entry is set. */ |
301 |
|
if ((boot_drive & 0x80) && boot_part_addr) |
302 |
{ |
{ |
303 |
char *dst, *src; |
char *dst, *src; |
304 |
int i; |
int i; |
3126 |
if (! open_device () && errnum != ERR_FSYS_MOUNT) |
if (! open_device () && errnum != ERR_FSYS_MOUNT) |
3127 |
return 1; |
return 1; |
3128 |
} |
} |
3129 |
|
else |
3130 |
|
{ |
3131 |
|
/* This is necessary, because the location of a partition table |
3132 |
|
must be set appropriately. */ |
3133 |
|
if (open_partition ()) |
3134 |
|
set_bootdev (0); |
3135 |
|
} |
3136 |
|
|
3137 |
/* Clear ERRNUM. */ |
/* Clear ERRNUM. */ |
3138 |
errnum = 0; |
errnum = 0; |
3139 |
saved_partition = current_partition; |
saved_partition = current_partition; |
3140 |
saved_drive = current_drive; |
saved_drive = current_drive; |
3141 |
|
|
|
/* BSD and chainloading evil hacks !! */ |
|
|
biasptr = skip_to (0, next); |
|
|
safe_parse_maxint (&biasptr, &hdbias); |
|
|
errnum = 0; |
|
|
bootdev = set_bootdev (hdbias); |
|
|
|
|
|
/* Print the type of the filesystem. */ |
|
3142 |
if (attempt_mount) |
if (attempt_mount) |
3143 |
print_fsys_type (); |
{ |
3144 |
|
/* BSD and chainloading evil hacks !! */ |
3145 |
|
biasptr = skip_to (0, next); |
3146 |
|
safe_parse_maxint (&biasptr, &hdbias); |
3147 |
|
errnum = 0; |
3148 |
|
bootdev = set_bootdev (hdbias); |
3149 |
|
|
3150 |
|
/* Print the type of the filesystem. */ |
3151 |
|
print_fsys_type (); |
3152 |
|
} |
3153 |
|
|
3154 |
return 0; |
return 0; |
3155 |
} |
} |
3156 |
|
|