# Problems with Intel Wifi

## [n00b@localhost]

I have a Thinkpad T61 with an Intel 4965 AGN network card in it.  It is using the iwl4965 driver compiled into the kernel.

```
garyslaptop ~ # uname -a

Linux garyslaptop 2.6.38-tuxonice-r1 #4 SMP PREEMPT Tue Jun 21 00:22:24 BST 2011 x86_64 Intel(R) Core(TM)2 Duo CPU T7300 @ 2.00GHz GenuineIntel GNU/Linuxgaryslaptop ~ # lspci -vs 03:00.0

03:00.0 Network controller: Intel Corporation PRO/Wireless 4965 AG or AGN [Kedron] Network Connection (rev 61)

        Subsystem: Intel Corporation Lenovo ThinkPad T61

        Flags: bus master, fast devsel, latency 0, IRQ 48

        Memory at df2fe000 (64-bit, non-prefetchable) [size=8K]

        Capabilities: [c8] Power Management version 3

        Capabilities: [d0] MSI: Enable+ Count=1/1 Maskable- 64bit+

        Capabilities: [e0] Express Endpoint, MSI 00

        Capabilities: [100] Advanced Error Reporting

        Capabilities: [140] Device Serial Number 00-13-e8-ff-ff-33-25-1b

        Kernel driver in use: iwlagn

garyslaptop ~ # zcat /proc/config.gz | grep CONFIG_IWL

CONFIG_IWLWIFI=y

# CONFIG_IWLWIFI_DEBUG is not set

CONFIG_IWLAGN=y

CONFIG_IWL4965=y

# CONFIG_IWL5000 is not set

# CONFIG_IWL3945 is not set
```

With some of the recent kernels it has started to have problems keeping a connection to the wireless access point (at home, uni and in the flat).

```
--- 192.168.1.254 ping statistics ---

50 packets transmitted, 44 received, 12% packet loss, time 49047ms

rtt min/avg/max/mdev = 1.135/10.078/72.003/16.327 ms
```

192.168.1.254 is the address of the router.  Sometimes the packet loss is as high as 90% and the time as high as 200ms.  The router is 3 metres away with clear line of sight to my laptop.  wpa_cli also reports lots of "<2>CTRL-EVENT-DISCONNECTED bssid=00:26:44:ef:35:9f reason=0" and "authentication failed" errors.

A quick google reveals these bugs:

https://bugs.launchpad.net/ubuntu/+source/linux/+bug/183796

http://bugzilla.intellinuxwireless.org/show_bug.cgi?id=1598

http://bugzilla.intellinuxwireless.org/show_bug.cgi?id=1669

but none of the solutions mentioned seem to work for me.

Has anyone else experienced similar problems with their wifi (Intel or otherwise)?  Are there any other solutions I can try?

On a somewhat unrelated note:

I seem to remember a website that would display linux kernel module information (device compatibility, kernel versions and, in particular, module parameters and their meanings).  I can't find it now though.  Does anyone else remember it or am I making it up?  BTW I am aware of the modinfo tool but it requires actually having the driver built as a module and not built in as I have.

----------

## John R. Graham

 *[n00b@localhost] wrote:*   

> On a somewhat unrelated note:
> 
> I seem to remember a website that would display linux kernel module information (device compatibility, kernel versions and, in particular, module parameters and their meanings).  I can't find it now though.  Does anyone else remember it or am I making it up?  BTW I am aware of the modinfo tool but it requires actually having the driver built as a module and not built in as I have.

 That would be here.

- John

----------

## [n00b@localhost]

 *John R. Graham wrote:*   

>  *[n00b@localhost] wrote:*   On a somewhat unrelated note:
> 
> I seem to remember a website that would display linux kernel module information (device compatibility, kernel versions and, in particular, module parameters and their meanings).  I can't find it now though.  Does anyone else remember it or am I making it up?  BTW I am aware of the modinfo tool but it requires actually having the driver built as a module and not built in as I have. That would be here.
> 
> - John

 

That doesn't tell you the module parameters though...

As far as I can remember it is something similar to http://www.alsa-project.org/main/index.php/Matrix:Module-hda-intel but for all kernel modules (not just alsa ones).

EDIT:

I actually just worked out a way of finding the kernel module parameters for built in modules through sysfs:

```
gary@garyslaptop ~ $ ls /sys/module/iwlagn/parameters/

11n_disable    amsdu_size_8K     bt_ch_inhibition  fw_restart50  queues_num50  ucode_alternative

11n_disable50  amsdu_size_8K50   disable_hw_scan   plcp_check    swcrypto

ack_check      antenna_coupling  fw_restart        queues_num    swcrypto50
```

----------

## dmpogo

Why are you not using iwlagn driver ?

Also,  I found it a bad idea to have wireless driver compiled into the kernel.  Not that infrequently I see a need to reload the firmware, and it is 

most easily done with removing and inserting back the module.

----------

## asturm

I also recently got the impression that my Intel WiFi 5300 is able to hang wireless routers. It happened with three different ones, the common denominator probably being mixed bg (or just b) operation.

----------

## [n00b@localhost]

 *dmpogo wrote:*   

> Why are you not using iwlagn driver ?

 

I am:

 *[n00b@localhost] wrote:*   

> 
> 
> ```
> Kernel driver in use: iwlagn
> ```
> ...

 

I tend to configure my kernels so that everything that is permanently attached to the computer (i.e. sound card, graphics card, network card, hard disk, etc.) is compiled into the kernel and everything that is removable (DVB-T USB stick, card reader, etc.) is compiled as modules.  That way I minimise the amount of modules/loading and memory.  Or that's the idea anyway...

I've only heard of having drivers built as modules being useful if they malfunction as you can unload them and reload them to reinitialise the hardware (for example when hibernating).

Isn't Linux meant to be monolithic anyway??   :Cool: 

----------

## dmpogo

 *[n00b@localhost] wrote:*   

> 
> 
> I've only heard of having drivers built as modules being useful if they malfunction as you can unload them and reload them to reinitialise the hardware (for example when hibernating).
> 
> 

 

And wireless drivers are exactly the prime example of those !

 *Quote:*   

> 
> 
> Isn't Linux meant to be monolithic anyway??  

 

Where did this idea come from ??   I guess you missed the epoch when Linux had automatic loading and inloading of modules on as needed basis  :Smile: 

----------

## asturm

there were some iwl fixes in 2.6.39.2, you could try that.

----------

## asturm

I can now definitely confirm that this behaviour is related to connecting with routers in mixed mode, and still happening with 2.6.39.2. Each time I do that, the router will crash reliably, three different models.

----------

## [n00b@localhost]

 *genstorm wrote:*   

> I can now definitely confirm that this behaviour is related to connecting with routers in mixed mode, and still happening with 2.6.39.2. Each time I do that, the router will crash reliably, three different models.

 

Excellent!  Sounds like a dodgy router TBH as it shouldn't be able to be hung by connecting clients.

I'm still stuck on 2.6.38.1 as I'm using tuxonice sources although I have now recompiled iwlwifi as modules (iwlcore and iwl4965).  Still doesn't make a difference to how it works (although I didn't expect it to) but I can now reload the modules when it starts playing up.

----------

## asturm

Would be my first guess too, but it happened to Buffalo and TP-Link routers, both running with dd-wrt, and some ancient Netgear router (which has never heard of dd-wrt).

----------

