God save ipw3945 (aka iwl3945 sucks)
I’ve been using ipw3945 driver ever since I’ve had a laptop with Intel 3945ABG wireless adapter. Despite few issues it had in the beginning, I was really happy to have that driver on-board, as the very latest version 1.2.1 of ipw3945 proved to be very stable and reliable. However, some time ago, someone decided to drop ipw3945 development in favour of iwl3945 / mac80211 projects. If you’re interested what do I think about it, read on.
Disclaimer
Just to make it clear – I really don’t want to get into details why exactly ipw has been dropped, who decided on that, what are the issues standing behind it, or anything like that. I am just a regular user, who expect things just work, and this post is written solely from that perspective.
Say hello to iwl3945 (or at least try)
Anyway, iwl3945 was included by default in Fedora 7, hence Intel 3945ABG cards were supposed to work in F7 out of the box. In fact, they didn’t very well. But I wasn’t worried too much, disabling iwl and installing ipw manually solved issues straight away, so my laptop was wireless again.
Fedora 7 has been released, time was passing by, Fedora 8 has been released (again with iwl, that I quickly replaced with ipw), time was passing by… But one day, around few weeks ago, I’ve had an idea – hey, let’s check how iwl3945 is going on? Because what is the point of using external and no longer developed driver, while fresh driver for my wireless card is already built into kernel. Sounds reasonable, right? So I’ve uninstalled ipw3945, removed iwl3945 from /etc/modprobe.d/blacklist, and… reverted back to ipw3945 after less than two days. I just couldn’t bear with opening terminal and reloading iwl3945 kernel module all the time. During that couple of days I’ve had way more issues with iwl, than I used to have with ipw during a month. So, despite my truly good intentions towards iwl3945, I’ve found out that since Fedora 7 release it hasn’t been really much improved, and ipw3945 was again the driver of my choice. Comparing to iwl3945 it was just flawless…
Kernel 2.6.24 – welcome on board!
Flawlessness of ipw3945 finished couple of days ago along with 2.6.24 kernel release in Fedora updates. While booting machine with new and shiny kernel, dkms_autoinstaller refused to compile ipw3945 kernel module, just throwing meaningless Bad exit status: 10 error. Google wasn’t much helpful, so I was forced to get iwl3945 and mac80211 out of blacklist again, hoping that since my horrible experience it gained some improvement. However, it was needless to look too far – modinfo iwl3945 command revealed that new kernel brings exactly the same iwl3945 module version as before, when I first tried to use it couple of months before! What a whopping improvement that is! Oh, what a joy…
So, why exactly iwl3945 sucks?
OK, to be honest, I must admit that I get the general idea of iwl3945 / mac80211 project. Here is the driver that doesn’t require any extra daemon (ipw3945d), that is built into kernel and enabled by default, and provides wireless networking out of the box. That’s great. There is only one slight issue – it doesn’t work quite right. What exactly? Here you go:
- LED light doesn’t work
Ha! That tiny, green light with WiFi logo on it – who’d care about it anyway?! – you might ask. I bet everyone who used ipw3945 before would be an answer. That little, green light had three simple states: OFF – wireless switched off; blinking green – wireless switched on, but not connected to any network (scanning mode); solid green – on and associated with network. These three simple states used to give me instant and exact overview of current state of wireless hardware in my laptop, as quite often software connection managers are reacting with little delay to hardware state changes. So, what iwl3945 gives mi instead? Nothing. Literally.
- Scanning for networks? You’d be better off playing the lottery
If you ever felt hunger for excitement, please try to scan for wireless networks with iwl3945. (Dis)satisfaction guaranteed. It’s slow and returns inaccurate results. When I first stepped into that problem, I thought there might be something wrong with my home router, as iwl3945 DID find wireless networks from across the street, but DIDN’T find a router which was just behind the wall, and the one it was actually connected to! Sometimes it’s even funnier – it cannot find ANY network at all. However, to be fair, I need to admit that sometimes it actually finds all nearby networks, including mine. Nice. Needless to say, ipw3945 never had such issues.
- Using hardware kill switch a lot? Better leave terminal window opened
Speaking about little, simple things, like LED light above? Take wireless hardware switch as another example. My Dell D620 has convenient on/off switch on the left side of chassis, which is extremely helpful to conserve battery power while on the move and WiFi is not needed. Even monkey could use it, but not with iwl3945. Driver is kind enough to detect switch being in OFF position (sometimes), but never bothers to notice it back into ON position. Solution?rmmod iwl3945 && modprobe iwl3945– quite convenient, isn’t it?
- Using sleep/resume a lot? Better leave terminal window opened
I’m not sure, but I believe I’ve stepped into article on the web saying that ipw3945d regulatory daemon prevented computer from being successfully resumed out of suspend/hibernation. Indeed, that was the case with earlier versions of ipw3945, but the latest one had absolutely no issues with it. After resume I’ve just had to wait ~10 secs for automagic reconnection, and I was back on track. The new and shiny iwl3945 gives way better experience, however. When computer wakes up, it seems that network connection is present straight away (hence way better experience). Gnome-panel network icon shows full coverage, eth1 interface is up, just perfect. In fact, nothing works. Connection is up, but simply dead. Like a dummy in crash-test. Solution? You know the solution already.
- I just want to use the internet, can I?
Yes you can. Just keep terminal opened at all times, for quick driver reload when needed. Here’s another example – I wanted to listen to my favourite online radio station yesterday. I’ve fired up Rhythmbox, selected radio from the list, hit play, and music filled the room instantly. But shortly after, every few seconds connection to the server was dropped, forcing player to re-buffer the stream over and over again. Initially I thought maybe connection to the ISP was slower than usual, but I did quick test first – connected my mobile phone to home router, and fired up Proton Radio from that little device. Sound stream was flawless, with no re-buffering at all. Surprised? Ha! You’ve guessed it. Reloading iwl3945 driver made 128kbps audio stream over 3 Mbps connection just work…
Who cares, anyway?
Initially I thought I would be good thing to submit all these things to the bugzilla dedicated exclusively to ipw* / iwl* / mac80211 projects. Before submitting any bugs into official project bugtracks, I usually check if someone did that already, just to avoid annoying duplicates. First off I’ve tried with LED light issue. Bingo! But.. hang on, issue has been submitted on 14th of February 2007, which makes it a little over a year old now. It’s still open, unresolved and there were several duplicate bugs submitted in-between. OK, there are some patches attached, that are supposed to make LED light work in certain kernel environments, but these are still just patches, hence issue itself is not resolved, and doesn’t seem to be resolved anytime soon! Over a year later! Lovely. I wasn’t even bothered to look for other issues, not to mention submitting anything there… :/
The ultimate solution
Since it looks like iwl3945 won’t get into decent state anytime in near future, and ipw3945 won’t work with 2.6.24 kernel, I somehow need to survive. To make my life easier, I’ve wrote /usr/local/bin/iwl_reload bash script:
#!/bin/sh ifconfig eth1 down rmmod iwl3945 sleep 2 modprobe iwl3945 sleep 5 /opt/wicd/autoconnect.py & <-- I'm using wicd to manage connections, so please change that line accordingly
So, reloading a driver and reconnecting to the network is now just a matter of running that single script. Unfortunately, I need to run it quite often lately…
Also, it’s nice to have /etc/pm/sleep.d/06iwl_reload file:
#!/bin/sh
case "$1" in
resume|thaw)
/usr/local/bin/iwl_reload
;;
*)
;;
esac
exit $?
Hence iwl gets reloaded automatically after resuming from suspend or hibernation, saving manual reload in terminal. Note: that file has to be executable, so chmod a+x /etc/pm/sleep.d/06iwl_reload is probably a good thing to do.
Final word
I am a web developer. I don’t use any kind of low level language. I don’t know how to write a device driver. I know, however, how hard it is to hear complaints about my own software, especially not supported by any details. I also understand that certain things in programming world are not as easy as it seems. This is why I’m always trying to resolve a problem myself instead of moaning out loud about it. But in this particular case I just couldn’t resist to shout. Someone, somewhere decided to replace good thing with much worse, and then convince all of us it’s actually better. While in fact it’s anywhere, but not even next to good, and it doesn’t seem like to be better (at least anytime soon)…
Oh, almost forgot
Version of iwl3945 module that I’m spilling all my beans onto, is 1.2.23kds running under kernel 2.6.24.3-12.fc8 (at the moment of writing). I know there is 1.2.25 version released already, and I truly wanted to try it out, but make simply fails with several error messages. I don’t know why. I’m too annoyed and tired to go through any README / INSTALL / GOF*CKYOURSELF files at the moment. Please check back later…
March 17, 2008 at 14:24
Just to let you know, there is a bugzilla file on report for 2.6.24.3-12.fc8. It’s a VERY buggy kernel. I actually, on my d620 went back to the 2.6.23.15-137.fc8 kernel. The ipw3945 wouldn’t compile for me under the 2.6.24 kernel either. I’m waiting for a better version of this kernel to roll out. Actually, I even had trouble with my display remaining stable.
Good luck,
Jon
March 21, 2008 at 1:04
I use gentoo rather than Fedora, but guess what, I agree with every single word you wrote there…It describes exactly my experience. But I guess the Intel guys and the kernel developers are very happy keeping us busy and nuts.
Oh, and I just dropped from my wi-fi and had to reconnect as I wrote that. Solution? Yeah, it’s what you are thinking ;)
March 28, 2008 at 0:17
Hey, you may want to check this website, it has a patch for building the IPW3945 driver againts the 2.6.24 kernel! This could be the solution to the nightmare, at least for now :D
http://james.colannino.org/downloads.html
March 28, 2008 at 7:32
Thanks! I’ll might give it a try, however I never installed ipw3945 from sources, relying on dkms version from FreshRPMs repository.
March 28, 2008 at 17:12
I think you need take a look at http://forum.mandriva.com/viewtopic.php?t=75963&sid=2b1c5aa11eec60e0028f56d2687bc46b
And all is ok. I ping my router about a day =) and there no any missed packets =)
March 28, 2008 at 17:38
If you mean adding ‘options iwl3945 disable_hw_scan=1′ module option, then I’ve already tried that. In my case, it actually gone much worse, and I’ve got driver crashing at almost every scan. :(
March 28, 2008 at 18:34
Your connection goes down becouse driver start scanning for new access points. If you use this option and setup it to static settings all will be ok!
— 192.168.0.1 ping statistics —
6773 packets transmitted, 6773 received, 0% packet loss, time 6801040ms
rtt min/avg/max/mdev = 0.999/1.419/43.530/1.051 ms
Yeh =)
May 11, 2008 at 10:22
The solution that Evincar provided works flawlessly with me.
1. Download ipw3945 microcode (http://ipw3945.sourceforge.net) and copy it into /lib/firmware/(`uname -r`)/
2. Download ipw3945 regulatory daemon (http://ipw3945.sourceforge.net) and copy it into /sbin/
3. Download ipw3945 source (http://ipw3945.sourceforge.net)
4. Apply patch from http://james.colannino.org/downloads.html
5. Make & make install
6. Add these lines to /etc/modprobe.d/ipw3945 (Creating the file if it doesn’t exist)
install ipw3945 /sbin/modprobe –ignore-install ipw3945 ; sleep 0.5 ; /sbin/ipw3945d –quiet
remove ipw3945 /sbin/ipw3945d –kill ; /sbin/modprobe -r –ignore-remove ipw3945
7. modprobe ipw3945
8. blacklist iwl3945 (put ipw3945 into /etc/modprobe.d/blacklist)
And voila! ipw3945 on linux 2.6.24!
May 23, 2008 at 17:18
All true. I am suffering from same problems. Fiddling with these drivers to lessen impact have taken 10 hours or so. For the moment bugzilla have 5 (!) blockers and 4 critical bugs. What can truly signify about iwl3945′s state as the state of SHIT!
May 26, 2008 at 23:55
Thanks for the great post summarizing just how much of a regression the switch from ipw3945->iwl3945 was.
All the issues you listed are issues for me. And I, like you, have resorted to writing my own module reload script and having it run at all sorts of opportune moments.
In general, the sad thing is that this driver just seems to perform worse than ipw3945. Slower to scan, slower to come up after a module reload, just generally slower. Really a damn shame.
I hope the F/OSS folks working on this driver fix the issues soon…
July 23, 2008 at 21:52
For anyone using Gentoo, it seems there is a problem with openrc restarting the wlan0 interface and that a rmmod/modprobe is not required (under 2.6.26 — Wireless LED works now too).
Try this command when you down the wlan0 interface before you start it again:
iwconfig wlan0 txpower on
http://bugs.gentoo.org/show_bug.cgi?id=217992
July 31, 2008 at 18:41
Hey, although you use fedora, ubuntu users have the very same problem. So I encourage you to support my idea regarding the iwl3945 issue in ubuntu: http://brainstorm.ubuntu.com/idea/10744/
August 3, 2008 at 10:53
Thanks for that link – I’ve added my support there.
August 15, 2008 at 8:54
Matthew
I blew off a few hours and found lots of dead end this afternoon and your little
iwconfig wlan0 txpower on
script in a preup function for the wireless interface works a treat
I cant say that ipw3945 or iwl3945 are much better or worse than each other
but at least iwl3945 is a little more open
I find them both annoying can cant be asked popping open my laptop to put a atheros card in
Sam
August 15, 2008 at 8:55
oh yeah, also having it native in the kernel tree is a good thing too
October 20, 2008 at 14:15
Hi,
I recently posted a patch to get ipw3945 driver to work with kernel 2.6.27 on http://www.funknetztest.de
Hoping this helps…
November 17, 2008 at 17:46
hi,
i hate iwl3945 because it doesnt support non us channels, so i have to work with windows :(
i tried to add options cfg80211 ieee80211_regdom=EU and options cfg80211 ieee80211_regdom=JP to /etc/modprobe.de/options but after rebooting the system or/and reloading the driver i just can´t join the ad-hoc network on channel 13.
dmesg says:
WARNING: at /build/buildd/linux-2.6.27/net/mac80211/main.c:987
eth1: IBSS not allowed on frequency 2472 MHz
pls help me, i wont work on windows anymore… i mean i can´t!
best regards
andreas
November 26, 2008 at 23:57
Hi,
Giving ieee80211_regdom=JP as module parameter also didn’t work for me. Changing regdom in source worked…
Change the line
static char *ieee80211_regdom = “US”;
in /usr/src/linux/net/wireless/reg.c
to
static char *ieee80211_regdom = “JP”;
then recompile. Afterwards channel 13 should work.I also tried this before switching back to ipw for performance reasons…
Juergen
January 5, 2009 at 6:07
It goes like this for me: (ubuntu 8.10)
iwl3945 – hardly lets me download with more than 100k/s.
ipw3945 – can’t get it to compile (2.4.28-git6 kernel)
ndiswrapper – works like a champ but WPA/WEP doesn’t work.
Pretty pathetic…
February 1, 2009 at 2:43
I’ve been having similar problems with iwl3945.
My wife’s laptop also has the intel 3945 card but it must be a new revision so believe it or not iwl3945 works OK there. But my laptop is a year older and the only way to get it to work properly was the ipw3945. Now I upgraded the kernel and I’m back to the same problems I had when I first tried iwl3945 a year ago. High packet loss and high latency causing really bad performance. Sometimes it sort of works for a while, but then goes back to 100kbps.
This is what happens when ideology gets in the way of progress.
I’m going to have to fork out $$$ for a new wireless card for this laptop so that my driver could be “free” and someone could win his ideological battles. THIS SUCKS!!!
February 1, 2009 at 4:31
Mr Real: I have exactly same issues right now, especially after installing Fedora 10. Driver used to work rather OK in Fedora 9, but in Fedora 10 it’s somewhat like a lottery – sometimes wireless works fine, and sometimes I have packet loss while pinging my own wireless router, not to mention max throughput of ~100-200 KB/s (at best).
I’ve filed a bugzilla issue for this, but I don’t believe it would change anything. :/
See: https://bugzilla.redhat.com/show_bug.cgi?id=479547