Linux users consistently get the short end of the stick when it comes to BIOS updates. Oftentimes dmesg will show us that something is wrong in the BIOS and we have no way to fix it. This is especially infuriating when you have a laptop with no CDROM drive and it doesn’t like to boot off usb because of… a bug in the BIOS. This is the HP 6730b laptop with the 00D BIOS. It’s a disaster of a monumental scale. It’s a nice laptop when it works, but oftentimes with fedora or suse (or any other distro which uses the intel driver rather than vesa) the screen “flickers” and the laptop runs like junk until you CTRL+ALT+F2 it and back again a few times. The dmesg log will be filled with errors about intel_iommu and the kernel will report a crash.
Officially the problem is a buggy BIOS, what’s actually happening is the iommu register is being mapped to ’0′ rather than any actual address. This means the CPU has it, the BIOS maps it incorrectly and then tells the OS to use ’0′ as the address in memory. If the kernel didn’t do sanity checking your box would crash. As it stands it simply causes an interrupt (the screen flashing) and then it’s caught.
HP’s site is amazingly bad and offers up three options – Bootable CD, USB and floppy. The laptop won’t USB boot, because of the 00D BIOS. The laptop doesn’t have a floppy drive, and who does anymore? The laptop will boot off a CD, but this requires you to actually find a CD. I tried a DVD and booktyped it as a CD just for grins and it didn’t work. How are we supposed to update this crap? Install windows?
The workaround: If you don’t want to do this, the cheap workaround is to turn off “virtualization technology” in the BIOS and set intel_iommu=0 in the grub.conf. You will lose access to virtualization accelleration. It will still cause kernel problems, but it will happen much less frequently. This also fixes the problem with sleeping unless the box had the problem when it started up.
The fix: Ready to take the plunge? Get yourself an HP account first. Registration is free.
Install syslinux. In fedora, this is yum install syslinux and it puts in in /usr/share/syslinux. I would also install the perl stuff if you plan on doing a lot of servers with this. If HP continues this sort of crap for servers that they did with laptops, plan on doing this – a lot.
Grab sp50750. There’s actually an F17 BIOS, but it only affects Windows 7 and appears to have driver updates also. If you want that one instead, use sp51317. As of right now the sp51317 download link doesn’t work, I believe they pulled it.
At this point I used wine to unpack the executable and I used rar to dump out ROM.CAB. Grab the ROM.BIN file and tuck it somewhere safe.
Grab sp50751. This is the F16 BIOS but this is for a different laptop. Do not apply this BIOS to your laptop. You have been warned. I didn’t try to apply the BIOS from that link to this laptop.
When you unpack that one, you will notice an ISO directory. You want to go in to that directory and mount the ROM.ISO – mount -o loop rom.iso tmp will mount the iso to a tmp directory. Create tmp first if it doesn’t exist.
Inside of your tmp directory (which is really the iso), you will see a /boot directory. Inside of that directory is a release.img file. Now we’re getting somewhere! You can run file release.img and see that it’s actually a floppy disk. Sweet! Copy this floppy image out of the ISO.
Mount up the floppy image. mount -o loop release.img tmp will do it, just like the CD. The difference is we can read and write to the floppy image while we can’t do that to a CD image. Doing an ls into our floppy image shows a 68PDD.BIN file, which is the BIOS. How am I so sure? It’s the only BIN file in there. Copy your ROM.BIN file we extracted earlier over the 68PDD.BIN file. Hit yes to overwrite it and then unmount the image.
WHAT DO WE DO WITH IT?
We can boot from it!
Copy release.img and /usr/share/syslinux/memdisk to /boot.
Edit /boot/grub/menu.lst and add the following:
title Floppy Disk Image
Reboot and select “Floppy Disk Image” from the grub menu, and it will boot into freeDOS and flash F16 to your laptop! Next time you boot you’ll have the new BIOS after it does some tests.
[ 0.000000] WARNING: at drivers/pci/dmar.c:633 warn_invalid_dmar+0x7d/0x8d()
[ 0.000000] Hardware name: HP Compaq 6730b (SERIAL NUMBER)
[ 0.000000] Your BIOS is broken; DMAR reported at address 0!
[ 0.000000] BIOS vendor: Hewlett-Packard; Ver: 68PDD Ver. F.16; Product Version: F.16
New F16 bugs! Good thing HP fixes them all!