Updating Thinkpad X61 BIOS


TL;DR

WARNING 1: the update is done at your own risk and may brick your computer.

WARNING 2: this will wipe all data on the target USB device.

WARNING 3: do not use SYSLINUX MEMDISK driver to boot it directly with eg. Grub. The Lenovo BIOS updater use the DOS HIMEM driver which is not compatible with SYSLINUX MEMDISK. A real, cold boot from USB is recommended.

To update your Thinkpad X61 BIOS to use Middleton's BIOS:

  1. Activate Allow firmware updates over LAN in the BIOS
  2. Download my BIOS updater USB image and flash it to your USB device (WARNING: this will wipe all data on the USB device):

    curl http://www.benou.fr/~ben/bin/bios.img.xz | unxz | dd of=/dev/sdX bs=1M
    
  3. Reboot on the USB device

  4. Run the BIOS updater:
    C:\>cd bios
    C:\BIOS>lcreflsh
    

Note: I also added the Intel® Ethernet Connections Boot Utility and Preboot Images which can be used to fix the integrated Intel 82566MM Gigabit Ethernet adapter. You can find it in the NIC directory:

C:\>cd nic
C:\NIC>bootutil -all -defaultconfig

How to generate your own USB image from Lenovo ISO

Lenovo provides BIOS updates either as Windows updater or ISO bootable images. The 2nd alternative is the only viable option under Linux, but is far from ideal because Lenovo ISO requires a real ATAPI/IDE CD drive to be attached to the computer. In order to generate my USB image I more-or-less followed this steps:

  1. Download the ISO of interest (in my case this was Middleton's BIOS)
  2. Download FreeDOS bootdisk and mount it in order to update it with the Lenovo updater files:

    curl http://www.fdos.org/bootdisks/autogen/FDSTD10.zip | unzip /dev/stdin
    losetup --partscan /dev/loop0 ./FDSTD10.IMG
    mkdir /tmp/FDSTD10
    mount /dev/loop0p1 /tmp/FDSTD10
    
  3. Extract the ISO El-Torito bootsector using geteltorito from the genisoimage package to inspect the boot configuration (esp. CONFIG.SYS, you will need to replicate the settings such as HIMEM etc.):

    geteltorito ./7nuj22uc.iso > ./boot.img
    mkdir /tmp/boot
    mount ./boot.img /tmp/boot
    
  4. Mount the ISO main partition to copy the Lenovo updater files:

    losetup --partscan /dev/loop1 ./7nuj22uc.iso
    mkdir /tmp/iso
    mount /dev/loop1p1 /tmp/iso
    
  5. Copy the Lenovo updater files to your bootable FreeDOS image:

    cp -a /tmp/iso /tmp/FDSTD10/
    
  6. Mimic the boot configuration (esp. CONFIG.SYS) as best as you can:

    vimdiff /tmp/boot/CONFIG.SYS /tmp/FDSTD10/CONFIG.SYS
    
  7. Unmount and voila!

    umount /tmp/iso
    umount /tmp/boot
    umount /tmp/FDSTD10
    losetup -D
    

You can do a quick smoke-test on your new image using qemu (the updater should complain about unrecognized system, which is expected):

qemu-system-x86_64 -curses -drive format=raw,file=./FDSTD10.IMG

Questions? Remarks? Do not hesitated to contact me!