opnsense-src/sys/boot/i386
John Baldwin e1b4a23921 The recent change to increase the zfsboot size to 64k made a few BIOSes
unhappy (probably they don't handle crossing the 64k boundary, etc.).
Fix this by changing zfsldr to use a loop reading from the disk one
sector at a time.  To avoid trashing the saved copy of the MBR which is
used for disk I/O, read zfsboot2 at address 0x9000.  This has the
advantage that BTX no longer needs to be relocated as it is read into
the correct location.  However, the loop to relocate zfsboot2.bin can
now cross a 64k boundary, so change it to use relative segments instead.
(This will need further work if zfsboot2.bin ever exceeds 64k.)

While here, stop storing a relocated copy of zfsldr at 0x700.  This was
only used by the xread hack which has recently been removed (and even
that use was dubious).  Also, include the BIOS error code as hex when
reporting read errors to aid in debugging.

Much thanks to Henri Hennebert for patiently testing various iterations
of the patch as well as fixing the zfsboot2.bin relocation to use
relative segments.

MFC after:	1 week
2011-06-23 15:53:17 +00:00
..
boot0 Upgrade our copy of llvm/clang to r126079, from upstream's trunk. 2011-02-20 19:33:47 +00:00
boot0ext Thanks to David's patches, we can now simplify these makefiles 2004-04-28 21:31:21 +00:00
boot0sio Thanks to David's patches, we can now simplify these makefiles 2004-04-28 21:31:21 +00:00
boot2 Fine-tune llvm optimization for sys/boot/i386/boot2, which shaves off 2011-05-05 18:47:24 +00:00
btx Upgrade our copy of llvm/clang to r126079, from upstream's trunk. 2011-02-20 19:33:47 +00:00
cdboot Remove duplicate "in". 2011-03-01 11:47:51 +00:00
common Due to space constraints, the UFS boot2 and boot1 use an evil hack where 2011-04-28 17:44:24 +00:00
efi Use new output format 'elf64-x86-64-freebsd' instead of 'elf64-x86-64', 2010-11-01 20:20:31 +00:00
gptboot Remove all object files during 'make clean'. 2011-03-11 13:11:15 +00:00
gptzfsboot Remove all object files during 'make clean'. 2011-04-21 14:17:36 +00:00
kgzldr NOSHARED -> NO_SHARED 2004-12-21 09:59:45 +00:00
libfirewire MF tbemd: Minor tweaks, prefer MACHINE_CPUARCH generally to MACHINE_ARCH 2010-08-23 01:42:09 +00:00
libi386 Fix clang warnings. 2011-06-18 13:56:33 +00:00
loader New boot loader menus from Devin Teske. 2011-05-28 08:50:38 +00:00
mbr Use -Wl,-N instead of the undocumented -N option for GCC. 2010-06-03 17:42:32 +00:00
pmbr Use -Wl,-N instead of the undocumented -N option for GCC. 2010-06-03 17:42:32 +00:00
pxeldr Upgrade our copy of llvm/clang to r126079, from upstream's trunk. 2011-02-20 19:33:47 +00:00
zfsboot The recent change to increase the zfsboot size to 64k made a few BIOSes 2011-06-23 15:53:17 +00:00
zfsloader For consistency, change all 'i386' and MACHINE_ARCH to x86. 2010-08-31 19:01:12 +00:00
Makefile Don't build zfsboot, gptzfsboot, and zfsloader if WITHOUT_ZFS is enabled. 2009-12-22 20:56:33 +00:00
Makefile.inc On i386 and amd64, consistently use the following options whenever we 2011-01-05 22:24:33 +00:00