Fit to be TIed

The Android G1 phone uses the TI 1251 for Wifi.   This is pretty useful for when you need an internet connection for the laptop and there are no alternatives: you can bridge the wifi and the 3G connection and then connect to the wifi device using ad-hoc mode.  However, I normally keep the wireless off because it sucks down battery like mad.

But Kalle Valo from Nokia is working on a driver for the chip called wl12xx, and he is putting a lot of effort into making sure it uses power conservatively (presumably some future version of the Nokia internet tablets will be using this device).  This driver is SPI, whereas the G1 uses the same chip in SDIO mode.  So I started writing the SDIO port for the driver — hopefully it will be ready when wl12xx is included in mainline.

The TI reference code that actually runs on the G1 is, sorry to say, total crap.  It registers an interrupt handler that printk()s a static string.  It has unbalanced sdio_claim_host() calls.  And from a code style standpoint, well, there is none.  I suspect Valo’s driver will be a big step up if and when it can run on the Android.

Oh, and Google’s open source tree for the Android hasn’t built all weekend.  Great job!