<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-stable.git/drivers/net/wireless/ath, branch v3.6</title>
<subtitle>Linux kernel stable tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/'/>
<entry>
<title>ath9k: make PA linearization optional, disabled by default and fix checks</title>
<updated>2012-09-10T18:42:43+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-09-08T13:24:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=74673db99ca3c09d34ea479f684522ceedb65eb9'/>
<id>74673db99ca3c09d34ea479f684522ceedb65eb9</id>
<content type='text'>
Some checks for PA linearization support checked ATH9K_HW_CAP_PAPRD and some
used the EEPROM ops, leading to issues in tx power handling, since those
two can be out of sync.

Disable the feature by default, since it has been reported that it can
cause damage to the rx path under some circumstances. It can now be enabled
for testing via debugfs.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some checks for PA linearization support checked ATH9K_HW_CAP_PAPRD and some
used the EEPROM ops, leading to issues in tx power handling, since those
two can be out of sync.

Disable the feature by default, since it has been reported that it can
cause damage to the rx path under some circumstances. It can now be enabled
for testing via debugfs.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k: Fix a crash in 2 WIRE btcoex chipsets</title>
<updated>2012-09-05T18:53:33+00:00</updated>
<author>
<name>Mohammed Shafi Shajakhan</name>
<email>mohammed@qca.qualcomm.com</email>
</author>
<published>2012-08-28T06:44:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=5d9b6f263995d7f43202d76cf2e23d43f9240a90'/>
<id>5d9b6f263995d7f43202d76cf2e23d43f9240a90</id>
<content type='text'>
Generic timers for BTCOEX functionality is applicable
only for 3 WIRE BTCOEX (and MCI) chipsets.
Hence btcoex-&gt;no_stomp_timer is allocated only 3 WIRE
btcoex chipsets and in all the other cases its NULL.
Make sure we stop the generic timer only if
'btcoex-&gt;hw_timer_enabled' is true(only if its up and
running)

Fixes the following crash

	[68757.020454] BUG: unable to handle kernel NULL pointer dereference at 0000000c
	[68757.020916] IP: [&lt;f9b055c3&gt;] ath9k_hw_gen_timer_stop+0x13/0x80 [ath9k_hw]
	[68757.021251] *pde = 00000000
	[68757.024384] EIP: 0060:[&lt;f9b055c3&gt;] EFLAGS: 00010082 CPU: 0
	[68757.024384] EIP is at ath9k_hw_gen_timer_stop+0x13/0x80 [ath9k_hw]
	[68757.024384] EAX: d32d0000 EBX: d32d0000 ECX: 00000000 EDX: 00000000
	[68757.024384] ESI: e67c24c0 EDI: 00000296 EBP: e137be2c ESP: e137be20
	[68757.024384]  DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
	[68757.024384] CR0: 8005003b CR2: 0000000c CR3: 00b99000 CR4: 000407d0
	[68757.024384] DR0: 00000000 DR1: 00000000 DR2: 00000000 DR3: 00000000
	[68757.024384] DR6: ffff0ff0 DR7: 00000400
	[68757.024384] Process kworker/u:2 (pid: 8917, ti=e137a000 task=ea7a6860 task.ti=e137a000)
	[68757.024384] Stack:
	[68757.024384]  c06c4676 d32d0000 e67c24c0 e137be38 f81c9590 e67c1ca0 e137be40 f81c95d9
	[68757.024384]  e137be64 f81cd1c5 00000246 00000002 d32d0000 e67c05e0 e67c1ca0 e67c05e0
	[68757.024384]  00000000 e137beac f81cdfa0 e137be84 00000246 00000246 e67c1ca0 e67c1ca0
	[68757.024384] Call Trace:
	[68757.024384]  [&lt;c06c4676&gt;] ? _raw_spin_lock_irqsave+0x86/0xa0
	[68757.024384]  [&lt;f81c9590&gt;] ath9k_gen_timer_stop+0x10/0x40 [ath9k]
	[68757.024384]  [&lt;f81c95d9&gt;] ath9k_btcoex_stop_gen_timer+0x19/0x20 [ath9k]
	[68757.024384]  [&lt;f81cd1c5&gt;] ath9k_ps_restore+0x85/0x110 [ath9k]
	[68757.024384]  [&lt;f81cdfa0&gt;] ath9k_config+0x220/0x520 [ath9k]
	[68757.024384]  [&lt;f81cd47d&gt;] ? ath9k_flush+0x15d/0x1b0 [ath9k]
	[68757.024384]  [&lt;f85c7ca5&gt;] ieee80211_hw_config+0x135/0x2c0 [mac80211]
	[68757.024384]  [&lt;f860e3c8&gt;] ieee80211_dynamic_ps_enable_work+0x198/0x5f0 [mac80211]

Cc: Rajkumar Manoharan &lt;rmanohar@qca.qualcomm.com&gt;
Cc: Bala Shanmugam &lt;bkamatch@qca.qualcomm.com&gt;
Signed-off-by: Mohammed Shafi Shajakhan &lt;mohammed@qca.qualcomm.com&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Generic timers for BTCOEX functionality is applicable
only for 3 WIRE BTCOEX (and MCI) chipsets.
Hence btcoex-&gt;no_stomp_timer is allocated only 3 WIRE
btcoex chipsets and in all the other cases its NULL.
Make sure we stop the generic timer only if
'btcoex-&gt;hw_timer_enabled' is true(only if its up and
running)

Fixes the following crash

	[68757.020454] BUG: unable to handle kernel NULL pointer dereference at 0000000c
	[68757.020916] IP: [&lt;f9b055c3&gt;] ath9k_hw_gen_timer_stop+0x13/0x80 [ath9k_hw]
	[68757.021251] *pde = 00000000
	[68757.024384] EIP: 0060:[&lt;f9b055c3&gt;] EFLAGS: 00010082 CPU: 0
	[68757.024384] EIP is at ath9k_hw_gen_timer_stop+0x13/0x80 [ath9k_hw]
	[68757.024384] EAX: d32d0000 EBX: d32d0000 ECX: 00000000 EDX: 00000000
	[68757.024384] ESI: e67c24c0 EDI: 00000296 EBP: e137be2c ESP: e137be20
	[68757.024384]  DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
	[68757.024384] CR0: 8005003b CR2: 0000000c CR3: 00b99000 CR4: 000407d0
	[68757.024384] DR0: 00000000 DR1: 00000000 DR2: 00000000 DR3: 00000000
	[68757.024384] DR6: ffff0ff0 DR7: 00000400
	[68757.024384] Process kworker/u:2 (pid: 8917, ti=e137a000 task=ea7a6860 task.ti=e137a000)
	[68757.024384] Stack:
	[68757.024384]  c06c4676 d32d0000 e67c24c0 e137be38 f81c9590 e67c1ca0 e137be40 f81c95d9
	[68757.024384]  e137be64 f81cd1c5 00000246 00000002 d32d0000 e67c05e0 e67c1ca0 e67c05e0
	[68757.024384]  00000000 e137beac f81cdfa0 e137be84 00000246 00000246 e67c1ca0 e67c1ca0
	[68757.024384] Call Trace:
	[68757.024384]  [&lt;c06c4676&gt;] ? _raw_spin_lock_irqsave+0x86/0xa0
	[68757.024384]  [&lt;f81c9590&gt;] ath9k_gen_timer_stop+0x10/0x40 [ath9k]
	[68757.024384]  [&lt;f81c95d9&gt;] ath9k_btcoex_stop_gen_timer+0x19/0x20 [ath9k]
	[68757.024384]  [&lt;f81cd1c5&gt;] ath9k_ps_restore+0x85/0x110 [ath9k]
	[68757.024384]  [&lt;f81cdfa0&gt;] ath9k_config+0x220/0x520 [ath9k]
	[68757.024384]  [&lt;f81cd47d&gt;] ? ath9k_flush+0x15d/0x1b0 [ath9k]
	[68757.024384]  [&lt;f85c7ca5&gt;] ieee80211_hw_config+0x135/0x2c0 [mac80211]
	[68757.024384]  [&lt;f860e3c8&gt;] ieee80211_dynamic_ps_enable_work+0x198/0x5f0 [mac80211]

Cc: Rajkumar Manoharan &lt;rmanohar@qca.qualcomm.com&gt;
Cc: Bala Shanmugam &lt;bkamatch@qca.qualcomm.com&gt;
Signed-off-by: Mohammed Shafi Shajakhan &lt;mohammed@qca.qualcomm.com&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k_hw: enable PA linearization</title>
<updated>2012-09-05T18:53:33+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-08-27T15:00:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=b3ccc1a56280119fe1fbf9929a76b4034358bfef'/>
<id>b3ccc1a56280119fe1fbf9929a76b4034358bfef</id>
<content type='text'>
This feature had been disabled in ath9k because the code to support
it was incomplete, but now the code is in sync with the internal QCA
codebase, so it's time to enable it.

On many newer devices, the calibration is assumed to be done with PA
linearization enabled.

Tests with a particular AR933x device showed that the signal emitted
at full power was highly distorted and unreliable with PA linearization
disabled. With this patch, the signal becomes clear and stability
is improved.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This feature had been disabled in ath9k because the code to support
it was incomplete, but now the code is in sync with the internal QCA
codebase, so it's time to enable it.

On many newer devices, the calibration is assumed to be done with PA
linearization enabled.

Tests with a particular AR933x device showed that the signal emitted
at full power was highly distorted and unreliable with PA linearization
disabled. With this patch, the signal becomes clear and stability
is improved.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k: fix PA linearization calibration related crash</title>
<updated>2012-09-05T18:53:32+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-08-27T15:00:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=51dea9be7e01d7e825ed1882246693f09c21374c'/>
<id>51dea9be7e01d7e825ed1882246693f09c21374c</id>
<content type='text'>
Before PAPRD training can run, the card needs to have sent a packet for
thermal calibration. Sending a dummy packet with the PAPRD training flag
set causes a crash under some circumstance.
Fix the code by replacing the dummy tx with a delay that waits for a
real packet tx to have occurred.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Before PAPRD training can run, the card needs to have sent a packet for
thermal calibration. Sending a dummy packet with the PAPRD training flag
set causes a crash under some circumstance.
Fix the code by replacing the dummy tx with a delay that waits for a
real packet tx to have occurred.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k_hw: disable PA linearization for AR9462</title>
<updated>2012-09-05T18:53:32+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-08-27T15:00:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=1630d25fd00f195f0923d4b895e0529fdbba83c3'/>
<id>1630d25fd00f195f0923d4b895e0529fdbba83c3</id>
<content type='text'>
Support for it is incomplete

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Support for it is incomplete

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k_hw: calibrate PA input for PA predistortion</title>
<updated>2012-09-05T18:53:31+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-08-27T15:00:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=381c726c09bb43aea8088ede5ce24eaa158289dc'/>
<id>381c726c09bb43aea8088ede5ce24eaa158289dc</id>
<content type='text'>
Re-train if the calibrated PA linearization curve is out of bounds
(affects AR933x and AR9485).

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Re-train if the calibrated PA linearization curve is out of bounds
(affects AR933x and AR9485).

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k_hw: clear the AM2PM predistortion mask on AR933x</title>
<updated>2012-09-05T18:53:31+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-08-27T15:00:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=26228959938b25bd41311a3f133a695b9da60e72'/>
<id>26228959938b25bd41311a3f133a695b9da60e72</id>
<content type='text'>
That predistortion type is not supported

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
That predistortion type is not supported

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath9k_hw: do not enable the MIB interrupt in the interrupt mask register</title>
<updated>2012-09-05T18:53:30+00:00</updated>
<author>
<name>Felix Fietkau</name>
<email>nbd@openwrt.org</email>
</author>
<published>2012-08-27T15:00:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=280b9a9de19b0819dcf1ab38c88e37bb82dbea0c'/>
<id>280b9a9de19b0819dcf1ab38c88e37bb82dbea0c</id>
<content type='text'>
The interrupt is no longer handling it. While it shouldn't fire (wraparound
is highly unlikely), the consequences would be fatal (interrupt storm).
Disable the interrupt to prevent that from happening.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The interrupt is no longer handling it. While it shouldn't fire (wraparound
is highly unlikely), the consequences would be fatal (interrupt storm).
Disable the interrupt to prevent that from happening.

Signed-off-by: Felix Fietkau &lt;nbd@openwrt.org&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath5k: fix wrong max power per rate eeprom reads for 802.11a</title>
<updated>2012-08-21T18:58:20+00:00</updated>
<author>
<name>Thomas Huehn</name>
<email>thomas@net.t-labs.tu-berlin.de</email>
</author>
<published>2012-08-15T20:48:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=3a245cbef6a9e4398456bd733b0b4b7cb3f11994'/>
<id>3a245cbef6a9e4398456bd733b0b4b7cb3f11994</id>
<content type='text'>
This patch reduces the per rate target power eeprom reads for
AR5K_EEPROM_MODE_11A from 10 to 8, as there are only 8 valid
power curve entries on the eeprom. The former 10 reads lead to
equal max power limits per rate and this causes an increasing
distortion for all rates above 24 MBit and leads to a needless
poor performance in 802.11a mode.

Signed-off-by: Thomas Huehn &lt;thomas@net.t-labs.tu-berlin.de&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch reduces the per rate target power eeprom reads for
AR5K_EEPROM_MODE_11A from 10 to 8, as there are only 8 valid
power curve entries on the eeprom. The former 10 reads lead to
equal max power limits per rate and this causes an increasing
distortion for all rates above 24 MBit and leads to a needless
poor performance in 802.11a mode.

Signed-off-by: Thomas Huehn &lt;thomas@net.t-labs.tu-berlin.de&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ath5k: fix spin_lock_irqsave/spin_lock_bh nesting in mesh</title>
<updated>2012-08-13T19:17:25+00:00</updated>
<author>
<name>Bob Copeland</name>
<email>me@bobcopeland.com</email>
</author>
<published>2012-08-13T01:18:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=7dd6753f6d2e7e0ccbf2263cef3a9fff6bc89988'/>
<id>7dd6753f6d2e7e0ccbf2263cef3a9fff6bc89988</id>
<content type='text'>
Lockdep found an inconsistent lock state when joining a mesh with
ath5k.  The problem is that ath5k takes the lock for its beacon state,
ah-&gt;block, with spin_lock_irqsave(), while mesh internally takes the
sync_offset_lock with spin_lock_bh() in mesh_sync_offset_adjust_tbtt(),
which in turn is called under ah-&gt;block.

This could deadlock if the beacon tasklet was run on the processor
that held the beacon lock during the do_softirq() in spin_unlock_bh().

We probably shouldn't hold the lock around the callbacks, but the
easiest fix is to switch to spin_lock_bh for ah-&gt;block: it doesn't
need interrupts disabled anyway as the data in question is only accessed
in softirq or process context.

Fixes the following lockdep warning:

[  446.892304] WARNING: at kernel/softirq.c:159 _local_bh_enable_ip+0x38/0xa6()
[  446.892306] Hardware name: MacBook1,1
[  446.892309] Modules linked in: tcp_lp fuse sunrpc cpufreq_ondemand acpi_cpufreq mperf ip6t_REJECT nf_conntrack_ipv6 nf_defrag_ipv6 nf_conntrack_ipv4 ip6table_filter nf_defrag_ipv4 xt_state nf_conntrack ip6_tables ext2 arc4 btusb bluetooth snd_hda_codec_idt snd_hda_intel carl9170 snd_hda_codec coretemp joydev ath5k snd_hwdep snd_seq isight_firmware ath snd_seq_device snd_pcm applesmc appletouch mac80211 input_polldev snd_timer microcode cfg80211 snd lpc_ich pcspkr i2c_i801 mfd_core soundcore rfkill snd_page_alloc sky2 tpm_infineon virtio_net kvm_intel kvm i915 drm_kms_helper drm i2c_algo_bit i2c_core video
[  446.892385] Pid: 1892, comm: iw Not tainted 3.6.0-rc1-wl+ #296
[  446.892387] Call Trace:
[  446.892394]  [&lt;c0432958&gt;] warn_slowpath_common+0x7c/0x91
[  446.892398]  [&lt;c04399d7&gt;] ? _local_bh_enable_ip+0x38/0xa6
[  446.892403]  [&lt;c04399d7&gt;] ? _local_bh_enable_ip+0x38/0xa6
[  446.892459]  [&lt;f7f9ae3b&gt;] ? mesh_sync_offset_adjust_tbtt+0x95/0x99 [mac80211]
[  446.892464]  [&lt;c043298f&gt;] warn_slowpath_null+0x22/0x24
[  446.892468]  [&lt;c04399d7&gt;] _local_bh_enable_ip+0x38/0xa6
[  446.892473]  [&lt;c0439a52&gt;] local_bh_enable_ip+0xd/0xf
[  446.892479]  [&lt;c088004f&gt;] _raw_spin_unlock_bh+0x34/0x37
[  446.892527]  [&lt;f7f9ae3b&gt;] mesh_sync_offset_adjust_tbtt+0x95/0x99 [mac80211]
[  446.892569]  [&lt;f7f7650f&gt;] ieee80211_beacon_get_tim+0x28f/0x4e0 [mac80211]
[  446.892575]  [&lt;c047ceeb&gt;] ? trace_hardirqs_on_caller+0x10e/0x13f
[  446.892591]  [&lt;f7fdc541&gt;] ath5k_beacon_update+0x40/0x26b [ath5k]
[  446.892597]  [&lt;c047ad67&gt;] ? lock_acquired+0x1f5/0x21e
[  446.892612]  [&lt;f7fdf9fb&gt;] ? ath5k_bss_info_changed+0x167/0x1b2 [ath5k]
[  446.892617]  [&lt;c087f9ea&gt;] ? _raw_spin_lock_irqsave+0x78/0x82
[  446.892632]  [&lt;f7fdf9fb&gt;] ? ath5k_bss_info_changed+0x167/0x1b2 [ath5k]
[  446.892647]  [&lt;f7fdfa09&gt;] ath5k_bss_info_changed+0x175/0x1b2 [ath5k]
[  446.892651]  [&lt;c0479dd4&gt;] ? lock_is_held+0x73/0x7b
[  446.892662]  [&lt;c0458fd5&gt;] ? __might_sleep+0xa7/0x17a
[  446.892698]  [&lt;f7f5d8f7&gt;] ieee80211_bss_info_change_notify+0x1ed/0x21a [mac80211]
[  446.892703]  [&lt;c0449875&gt;] ? queue_work+0x24/0x32
[  446.892718]  [&lt;f7fdf894&gt;] ? ath5k_configure_filter+0x163/0x163 [ath5k]
[  446.892766]  [&lt;f7f95fa4&gt;] ieee80211_start_mesh+0xb9/0xbd [mac80211]
[  446.892806]  [&lt;f7f6e610&gt;] ieee80211_join_mesh+0x10c/0x116 [mac80211]
[  446.892834]  [&lt;f7a96b90&gt;] __cfg80211_join_mesh+0x176/0x1b3 [cfg80211]
[  446.892855]  [&lt;f7a96c1c&gt;] cfg80211_join_mesh+0x4f/0x6a [cfg80211]
[  446.892875]  [&lt;f7a89891&gt;] nl80211_join_mesh+0x1de/0x1ed [cfg80211]
[  446.892908]  [&lt;f7a8db99&gt;] ? nl80211_set_wiphy+0x4cf/0x4cf [cfg80211]
[  446.892919]  [&lt;c07cfa36&gt;] genl_rcv_msg+0x1d5/0x1f3
[  446.892940]  [&lt;c07cf861&gt;] ? genl_rcv+0x25/0x25
[  446.892946]  [&lt;c07cf009&gt;] netlink_rcv_skb+0x37/0x78
[  446.892950]  [&lt;c07cf85a&gt;] genl_rcv+0x1e/0x25
[  446.892955]  [&lt;c07cebf3&gt;] netlink_unicast+0xc3/0x12d
[  446.892959]  [&lt;c07cee46&gt;] netlink_sendmsg+0x1e9/0x213
[  446.892966]  [&lt;c079f282&gt;] sock_sendmsg+0x79/0x96
[  446.892972]  [&lt;c04eb90d&gt;] ? might_fault+0x9d/0xa3
[  446.892978]  [&lt;c07a81d8&gt;] ? copy_from_user+0x8/0xa
[  446.892983]  [&lt;c07a852c&gt;] ? verify_iovec+0x43/0x77
[  446.892987]  [&lt;c079f4d8&gt;] __sys_sendmsg+0x180/0x215
[  446.892993]  [&lt;c045f107&gt;] ? sched_clock_cpu+0x134/0x144
[  446.892997]  [&lt;c047992f&gt;] ? trace_hardirqs_off+0xb/0xd
[  446.893002]  [&lt;c047bf88&gt;] ? __lock_acquire+0x46b/0xb6e
[  446.893006]  [&lt;c047992f&gt;] ? trace_hardirqs_off+0xb/0xd
[  446.893010]  [&lt;c045f149&gt;] ? local_clock+0x32/0x49
[  446.893015]  [&lt;c0479ec1&gt;] ? lock_release_holdtime.part.9+0x4b/0x51
[  446.893020]  [&lt;c0479dd4&gt;] ? lock_is_held+0x73/0x7b
[  446.893025]  [&lt;c050d127&gt;] ? fcheck_files+0x97/0xcd
[  446.893029]  [&lt;c050d4df&gt;] ? fget_light+0x2d/0x81
[  446.893034]  [&lt;c07a01f3&gt;] sys_sendmsg+0x3b/0x52
[  446.893038]  [&lt;c07a07b4&gt;] sys_socketcall+0x238/0x2a2
[  446.893044]  [&lt;c0885edf&gt;] sysenter_do_call+0x12/0x38
[  446.893047] ---[ end trace a9af5998f929270f ]---
[  447.627222]
[  447.627232] =================================
[  447.627237] [ INFO: inconsistent lock state ]
[  447.627244] 3.6.0-rc1-wl+ #296 Tainted: G        W
[  447.627248] ---------------------------------
[  447.627253] inconsistent {SOFTIRQ-ON-W} -&gt; {IN-SOFTIRQ-W} usage.
[  447.627260] swapper/0/0 [HC0[0]:SC1[1]:HE1:SE0] takes:
[  447.627264]  (&amp;(&amp;ah-&gt;block)-&gt;rlock){+.?...}, at: [&lt;f7fdd2d1&gt;] ath5k_tasklet_beacon+0x91/0xa7 [ath5k]
[  447.627299] {SOFTIRQ-ON-W} state was registered at:
[  447.627304]   [&lt;c047cdbf&gt;] mark_held_locks+0x59/0x77
[  447.627316]   [&lt;c047ceeb&gt;] trace_hardirqs_on_caller+0x10e/0x13f
[  447.627324]   [&lt;c047cf27&gt;] trace_hardirqs_on+0xb/0xd
[  447.627332]   [&lt;c0439a3d&gt;] _local_bh_enable_ip+0x9e/0xa6
[  447.627342]   [&lt;c0439a52&gt;] local_bh_enable_ip+0xd/0xf
[  447.627349]   [&lt;c088004f&gt;] _raw_spin_unlock_bh+0x34/0x37
[  447.627359]   [&lt;f7f9ae3b&gt;] mesh_sync_offset_adjust_tbtt+0x95/0x99 [mac80211]
[  447.627451]   [&lt;f7f7650f&gt;] ieee80211_beacon_get_tim+0x28f/0x4e0 [mac80211]
[  447.627526]   [&lt;f7fdc541&gt;] ath5k_beacon_update+0x40/0x26b [ath5k]
[  447.627547]   [&lt;f7fdfa09&gt;] ath5k_bss_info_changed+0x175/0x1b2 [ath5k]
[  447.627569]   [&lt;f7f5d8f7&gt;] ieee80211_bss_info_change_notify+0x1ed/0x21a [mac80211]
[  447.627628]   [&lt;f7f95fa4&gt;] ieee80211_start_mesh+0xb9/0xbd [mac80211]
[  447.627712]   [&lt;f7f6e610&gt;] ieee80211_join_mesh+0x10c/0x116 [mac80211]
[  447.627782]   [&lt;f7a96b90&gt;] __cfg80211_join_mesh+0x176/0x1b3 [cfg80211]
[  447.627816]   [&lt;f7a96c1c&gt;] cfg80211_join_mesh+0x4f/0x6a [cfg80211]
[  447.627845]   [&lt;f7a89891&gt;] nl80211_join_mesh+0x1de/0x1ed [cfg80211]
[  447.627872]   [&lt;c07cfa36&gt;] genl_rcv_msg+0x1d5/0x1f3
[  447.627881]   [&lt;c07cf009&gt;] netlink_rcv_skb+0x37/0x78
[  447.627891]   [&lt;c07cf85a&gt;] genl_rcv+0x1e/0x25
[  447.627898]   [&lt;c07cebf3&gt;] netlink_unicast+0xc3/0x12d
[  447.627907]   [&lt;c07cee46&gt;] netlink_sendmsg+0x1e9/0x213
[  447.627915]   [&lt;c079f282&gt;] sock_sendmsg+0x79/0x96
[  447.627926]   [&lt;c079f4d8&gt;] __sys_sendmsg+0x180/0x215
[  447.627934]   [&lt;c07a01f3&gt;] sys_sendmsg+0x3b/0x52
[  447.627941]   [&lt;c07a07b4&gt;] sys_socketcall+0x238/0x2a2
[  447.627949]   [&lt;c0885edf&gt;] sysenter_do_call+0x12/0x38
[  447.627959] irq event stamp: 1929200
[  447.627963] hardirqs last  enabled at (1929200): [&lt;c043a0e9&gt;] tasklet_hi_action+0x3e/0xbf
[  447.627972] hardirqs last disabled at (1929199): [&lt;c043a0c0&gt;] tasklet_hi_action+0x15/0xbf
[  447.627981] softirqs last  enabled at (1929196): [&lt;c043999d&gt;] _local_bh_enable+0x12/0x14
[  447.627989] softirqs last disabled at (1929197): [&lt;c040443b&gt;] do_softirq+0x63/0xb8
[  447.627999]
[  447.627999] other info that might help us debug this:
[  447.628004]  Possible unsafe locking scenario:
[  447.628004]
[  447.628009]        CPU0
[  447.628012]        ----
[  447.628016]   lock(&amp;(&amp;ah-&gt;block)-&gt;rlock);
[  447.628023]   &lt;Interrupt&gt;
[  447.628027]     lock(&amp;(&amp;ah-&gt;block)-&gt;rlock);
[  447.628034]
[  447.628034]  *** DEADLOCK ***

Signed-off-by: Bob Copeland &lt;me@bobcopeland.com&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Lockdep found an inconsistent lock state when joining a mesh with
ath5k.  The problem is that ath5k takes the lock for its beacon state,
ah-&gt;block, with spin_lock_irqsave(), while mesh internally takes the
sync_offset_lock with spin_lock_bh() in mesh_sync_offset_adjust_tbtt(),
which in turn is called under ah-&gt;block.

This could deadlock if the beacon tasklet was run on the processor
that held the beacon lock during the do_softirq() in spin_unlock_bh().

We probably shouldn't hold the lock around the callbacks, but the
easiest fix is to switch to spin_lock_bh for ah-&gt;block: it doesn't
need interrupts disabled anyway as the data in question is only accessed
in softirq or process context.

Fixes the following lockdep warning:

[  446.892304] WARNING: at kernel/softirq.c:159 _local_bh_enable_ip+0x38/0xa6()
[  446.892306] Hardware name: MacBook1,1
[  446.892309] Modules linked in: tcp_lp fuse sunrpc cpufreq_ondemand acpi_cpufreq mperf ip6t_REJECT nf_conntrack_ipv6 nf_defrag_ipv6 nf_conntrack_ipv4 ip6table_filter nf_defrag_ipv4 xt_state nf_conntrack ip6_tables ext2 arc4 btusb bluetooth snd_hda_codec_idt snd_hda_intel carl9170 snd_hda_codec coretemp joydev ath5k snd_hwdep snd_seq isight_firmware ath snd_seq_device snd_pcm applesmc appletouch mac80211 input_polldev snd_timer microcode cfg80211 snd lpc_ich pcspkr i2c_i801 mfd_core soundcore rfkill snd_page_alloc sky2 tpm_infineon virtio_net kvm_intel kvm i915 drm_kms_helper drm i2c_algo_bit i2c_core video
[  446.892385] Pid: 1892, comm: iw Not tainted 3.6.0-rc1-wl+ #296
[  446.892387] Call Trace:
[  446.892394]  [&lt;c0432958&gt;] warn_slowpath_common+0x7c/0x91
[  446.892398]  [&lt;c04399d7&gt;] ? _local_bh_enable_ip+0x38/0xa6
[  446.892403]  [&lt;c04399d7&gt;] ? _local_bh_enable_ip+0x38/0xa6
[  446.892459]  [&lt;f7f9ae3b&gt;] ? mesh_sync_offset_adjust_tbtt+0x95/0x99 [mac80211]
[  446.892464]  [&lt;c043298f&gt;] warn_slowpath_null+0x22/0x24
[  446.892468]  [&lt;c04399d7&gt;] _local_bh_enable_ip+0x38/0xa6
[  446.892473]  [&lt;c0439a52&gt;] local_bh_enable_ip+0xd/0xf
[  446.892479]  [&lt;c088004f&gt;] _raw_spin_unlock_bh+0x34/0x37
[  446.892527]  [&lt;f7f9ae3b&gt;] mesh_sync_offset_adjust_tbtt+0x95/0x99 [mac80211]
[  446.892569]  [&lt;f7f7650f&gt;] ieee80211_beacon_get_tim+0x28f/0x4e0 [mac80211]
[  446.892575]  [&lt;c047ceeb&gt;] ? trace_hardirqs_on_caller+0x10e/0x13f
[  446.892591]  [&lt;f7fdc541&gt;] ath5k_beacon_update+0x40/0x26b [ath5k]
[  446.892597]  [&lt;c047ad67&gt;] ? lock_acquired+0x1f5/0x21e
[  446.892612]  [&lt;f7fdf9fb&gt;] ? ath5k_bss_info_changed+0x167/0x1b2 [ath5k]
[  446.892617]  [&lt;c087f9ea&gt;] ? _raw_spin_lock_irqsave+0x78/0x82
[  446.892632]  [&lt;f7fdf9fb&gt;] ? ath5k_bss_info_changed+0x167/0x1b2 [ath5k]
[  446.892647]  [&lt;f7fdfa09&gt;] ath5k_bss_info_changed+0x175/0x1b2 [ath5k]
[  446.892651]  [&lt;c0479dd4&gt;] ? lock_is_held+0x73/0x7b
[  446.892662]  [&lt;c0458fd5&gt;] ? __might_sleep+0xa7/0x17a
[  446.892698]  [&lt;f7f5d8f7&gt;] ieee80211_bss_info_change_notify+0x1ed/0x21a [mac80211]
[  446.892703]  [&lt;c0449875&gt;] ? queue_work+0x24/0x32
[  446.892718]  [&lt;f7fdf894&gt;] ? ath5k_configure_filter+0x163/0x163 [ath5k]
[  446.892766]  [&lt;f7f95fa4&gt;] ieee80211_start_mesh+0xb9/0xbd [mac80211]
[  446.892806]  [&lt;f7f6e610&gt;] ieee80211_join_mesh+0x10c/0x116 [mac80211]
[  446.892834]  [&lt;f7a96b90&gt;] __cfg80211_join_mesh+0x176/0x1b3 [cfg80211]
[  446.892855]  [&lt;f7a96c1c&gt;] cfg80211_join_mesh+0x4f/0x6a [cfg80211]
[  446.892875]  [&lt;f7a89891&gt;] nl80211_join_mesh+0x1de/0x1ed [cfg80211]
[  446.892908]  [&lt;f7a8db99&gt;] ? nl80211_set_wiphy+0x4cf/0x4cf [cfg80211]
[  446.892919]  [&lt;c07cfa36&gt;] genl_rcv_msg+0x1d5/0x1f3
[  446.892940]  [&lt;c07cf861&gt;] ? genl_rcv+0x25/0x25
[  446.892946]  [&lt;c07cf009&gt;] netlink_rcv_skb+0x37/0x78
[  446.892950]  [&lt;c07cf85a&gt;] genl_rcv+0x1e/0x25
[  446.892955]  [&lt;c07cebf3&gt;] netlink_unicast+0xc3/0x12d
[  446.892959]  [&lt;c07cee46&gt;] netlink_sendmsg+0x1e9/0x213
[  446.892966]  [&lt;c079f282&gt;] sock_sendmsg+0x79/0x96
[  446.892972]  [&lt;c04eb90d&gt;] ? might_fault+0x9d/0xa3
[  446.892978]  [&lt;c07a81d8&gt;] ? copy_from_user+0x8/0xa
[  446.892983]  [&lt;c07a852c&gt;] ? verify_iovec+0x43/0x77
[  446.892987]  [&lt;c079f4d8&gt;] __sys_sendmsg+0x180/0x215
[  446.892993]  [&lt;c045f107&gt;] ? sched_clock_cpu+0x134/0x144
[  446.892997]  [&lt;c047992f&gt;] ? trace_hardirqs_off+0xb/0xd
[  446.893002]  [&lt;c047bf88&gt;] ? __lock_acquire+0x46b/0xb6e
[  446.893006]  [&lt;c047992f&gt;] ? trace_hardirqs_off+0xb/0xd
[  446.893010]  [&lt;c045f149&gt;] ? local_clock+0x32/0x49
[  446.893015]  [&lt;c0479ec1&gt;] ? lock_release_holdtime.part.9+0x4b/0x51
[  446.893020]  [&lt;c0479dd4&gt;] ? lock_is_held+0x73/0x7b
[  446.893025]  [&lt;c050d127&gt;] ? fcheck_files+0x97/0xcd
[  446.893029]  [&lt;c050d4df&gt;] ? fget_light+0x2d/0x81
[  446.893034]  [&lt;c07a01f3&gt;] sys_sendmsg+0x3b/0x52
[  446.893038]  [&lt;c07a07b4&gt;] sys_socketcall+0x238/0x2a2
[  446.893044]  [&lt;c0885edf&gt;] sysenter_do_call+0x12/0x38
[  446.893047] ---[ end trace a9af5998f929270f ]---
[  447.627222]
[  447.627232] =================================
[  447.627237] [ INFO: inconsistent lock state ]
[  447.627244] 3.6.0-rc1-wl+ #296 Tainted: G        W
[  447.627248] ---------------------------------
[  447.627253] inconsistent {SOFTIRQ-ON-W} -&gt; {IN-SOFTIRQ-W} usage.
[  447.627260] swapper/0/0 [HC0[0]:SC1[1]:HE1:SE0] takes:
[  447.627264]  (&amp;(&amp;ah-&gt;block)-&gt;rlock){+.?...}, at: [&lt;f7fdd2d1&gt;] ath5k_tasklet_beacon+0x91/0xa7 [ath5k]
[  447.627299] {SOFTIRQ-ON-W} state was registered at:
[  447.627304]   [&lt;c047cdbf&gt;] mark_held_locks+0x59/0x77
[  447.627316]   [&lt;c047ceeb&gt;] trace_hardirqs_on_caller+0x10e/0x13f
[  447.627324]   [&lt;c047cf27&gt;] trace_hardirqs_on+0xb/0xd
[  447.627332]   [&lt;c0439a3d&gt;] _local_bh_enable_ip+0x9e/0xa6
[  447.627342]   [&lt;c0439a52&gt;] local_bh_enable_ip+0xd/0xf
[  447.627349]   [&lt;c088004f&gt;] _raw_spin_unlock_bh+0x34/0x37
[  447.627359]   [&lt;f7f9ae3b&gt;] mesh_sync_offset_adjust_tbtt+0x95/0x99 [mac80211]
[  447.627451]   [&lt;f7f7650f&gt;] ieee80211_beacon_get_tim+0x28f/0x4e0 [mac80211]
[  447.627526]   [&lt;f7fdc541&gt;] ath5k_beacon_update+0x40/0x26b [ath5k]
[  447.627547]   [&lt;f7fdfa09&gt;] ath5k_bss_info_changed+0x175/0x1b2 [ath5k]
[  447.627569]   [&lt;f7f5d8f7&gt;] ieee80211_bss_info_change_notify+0x1ed/0x21a [mac80211]
[  447.627628]   [&lt;f7f95fa4&gt;] ieee80211_start_mesh+0xb9/0xbd [mac80211]
[  447.627712]   [&lt;f7f6e610&gt;] ieee80211_join_mesh+0x10c/0x116 [mac80211]
[  447.627782]   [&lt;f7a96b90&gt;] __cfg80211_join_mesh+0x176/0x1b3 [cfg80211]
[  447.627816]   [&lt;f7a96c1c&gt;] cfg80211_join_mesh+0x4f/0x6a [cfg80211]
[  447.627845]   [&lt;f7a89891&gt;] nl80211_join_mesh+0x1de/0x1ed [cfg80211]
[  447.627872]   [&lt;c07cfa36&gt;] genl_rcv_msg+0x1d5/0x1f3
[  447.627881]   [&lt;c07cf009&gt;] netlink_rcv_skb+0x37/0x78
[  447.627891]   [&lt;c07cf85a&gt;] genl_rcv+0x1e/0x25
[  447.627898]   [&lt;c07cebf3&gt;] netlink_unicast+0xc3/0x12d
[  447.627907]   [&lt;c07cee46&gt;] netlink_sendmsg+0x1e9/0x213
[  447.627915]   [&lt;c079f282&gt;] sock_sendmsg+0x79/0x96
[  447.627926]   [&lt;c079f4d8&gt;] __sys_sendmsg+0x180/0x215
[  447.627934]   [&lt;c07a01f3&gt;] sys_sendmsg+0x3b/0x52
[  447.627941]   [&lt;c07a07b4&gt;] sys_socketcall+0x238/0x2a2
[  447.627949]   [&lt;c0885edf&gt;] sysenter_do_call+0x12/0x38
[  447.627959] irq event stamp: 1929200
[  447.627963] hardirqs last  enabled at (1929200): [&lt;c043a0e9&gt;] tasklet_hi_action+0x3e/0xbf
[  447.627972] hardirqs last disabled at (1929199): [&lt;c043a0c0&gt;] tasklet_hi_action+0x15/0xbf
[  447.627981] softirqs last  enabled at (1929196): [&lt;c043999d&gt;] _local_bh_enable+0x12/0x14
[  447.627989] softirqs last disabled at (1929197): [&lt;c040443b&gt;] do_softirq+0x63/0xb8
[  447.627999]
[  447.627999] other info that might help us debug this:
[  447.628004]  Possible unsafe locking scenario:
[  447.628004]
[  447.628009]        CPU0
[  447.628012]        ----
[  447.628016]   lock(&amp;(&amp;ah-&gt;block)-&gt;rlock);
[  447.628023]   &lt;Interrupt&gt;
[  447.628027]     lock(&amp;(&amp;ah-&gt;block)-&gt;rlock);
[  447.628034]
[  447.628034]  *** DEADLOCK ***

Signed-off-by: Bob Copeland &lt;me@bobcopeland.com&gt;
Signed-off-by: John W. Linville &lt;linville@tuxdriver.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
