Saturday, November 28, 2009

HP does not want my wireless to work

I'm using an rather oldish, but still functioning hp compaq nc6000. It had built in atheros wireless. Whis is a pain. Because whenever NetworkManager thinks it is a good idea to do background scanning (at least every 2 minutes, I'd guess), the network quality degrades to it being unusable. Not only drops the data rate to ~100 to 200 kbyte/second, even worse, lots of packets get lost, so that working via SSH on a remote host becomes very annoying.
(With a recent kernel. Older kernels actually regularly stopped transmitting and dropped the connection completely during such events). Sometimes, reloading the ath5k module improves the situation (or at least it feels like it does), but then, every 5 reloads or so, the machine locks up hard (no SysRQ!) when reloading ath5k.

Today, that happened again. This was when I decided that I had enough and that I would swap the card for an intel ipw2200 I had lying around here.

But HP, THOSE GREEDY BASTARDS of course thought of a way to avoid that people upgrade their hardware. After putting the card in, the machine only shows an error "104 - we want you to pay lots of money for an HP approved Wireless" and does not boot.

Searching the internet, I found out that I had two possible options: patching the BIOS or patching the ipw2200 card's eeprom.
The second option is possible because there actually are ipw2200 cards that are "certified" by HP and they have different subvendor and subdevice IDs, so that the BIOS can detect them.

I went for a mix of all the procedures I found. The patch for ipw2200 I used is from Obi's Homepage (thanks), also a large part of the procedure is described there, even though he had a different goal.
Which bytes I had to change was described, ironically, in the HP support forum (search for "ethtool" on the page).

So that's what I did:
  • put the card into another notebook that would boot with it

  • build a patched ipw2200 (too bad upstream apparently does not want to take this patch)

  • boot an openSUSE 11.2 live ISO (from an USB stick, of course)

  • unload the original module, load the patched module (important)

  • issue the following commands:

ethtool -E eth0 magic 0x2200 offset 0x8 value 0xf6
ethtool -E eth0 magic 0x2200 offset 0x9 value 0x12
ethtool -E eth0 magic 0x2200 offset 0xa value 0x3c
ethtool -E eth0 magic 0x2200 offset 0xb value 0x10

Note that I did get errors from ethtool for every one of those commands (invalid address and others, pretty confusing ;) ). First I thought that it did not work, but "dmesg" told me that the write function was actually called, and so I just continued.

  • I unloaded and reloaded the patched ipw2200 module. I did expect an eeprom checksum error, but I actually did not get one. So I also did not do the "repair_eeprom=1" routine that Obi describes.

  • Put back the module in the "target" notebook.

Now I have:
02:04.0 Network controller: Intel Corporation PRO/Wireless 2200BG
Subsystem: Hewlett-Packard Company Compaq nw8240/nx8220

and so far it has been working fine.

Attention: according to the forum post in the HP forum, if your card is from the US and not from Europe, you will need
ethtool -E eth0 magic 0x2200 offset 0x8 value 0xf5

instead of the 0xf6 for the european version.

Oh - and if you are too lazy to patch and build your own ipw2200 module - there is the "ipw2200-eepromwrite-kmp" package for 11.2 in the buildservice, project home:seife ;)


  1. [...] seife’s assorted rants Move on, nothing to see here. « HP does not want my wireless to work [...]

  2. I know next to nothing about wireless, but I really enjoyed this post (I'm now in the bed with flu, so I have plenty of time to browse blogs). The way it is written made me laugh :) Thanks