Ben Hutchings [Sat, 13 Dec 2008 06:09:38 +0000 (22:09 -0800)]
sfc: Fix synchronisation of efx_mtd_{probe,rename,remove}
Currently efx_mtd_rename() can race with the probe() and remove()
functions.
Move probe() before device registration and remove() after
unregistration. Move initialisation/update of all names based on the
netdev name into a new function and call it under the RTNL immediately
after registration.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 06:06:24 +0000 (22:06 -0800)]
sfc: Use mutex_lock_interruptible() for ethtool EEPROM access
ethtool must contend with the MTD driver for the SPI bus lock, which
may carry out long operations such as flash erase. Allow it to be
interrupted while waiting.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 06:05:48 +0000 (22:05 -0800)]
sfc: Specify a meaningful component for loopback RX-side and PHY tests
Our ethtool self-test result names each begin with a component name. For
some results this is "port0", which is not very meaningful. Change that
to "rx" or "phy" as appropriate.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 05:59:24 +0000 (21:59 -0800)]
sfc: Rework MAC, PHY and board event handling
From: Steve Hodgson <shodgson@solarflare.com>
MAC, PHY and board events may be separately enabled and signalled.
Our current arrangement of chaining the polling functions can result
in events being missed. Change them to be more independent.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 05:50:08 +0000 (21:50 -0800)]
sfc: Add support for sub-10G speeds
The SFC4000 has a separate MAC for use at sub-10G speeds. Introduce
an efx_mac_operations structure with implementations for the two MACs.
Switch between the MACs as necessary.
PHY settings are independent of the MAC, so add get_settings() and
set_settings() to efx_phy_operations. Also add macs field to indicate
which MACs the PHY is connected to.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 05:48:57 +0000 (21:48 -0800)]
sfc: Clean up MDIO flag setting
We often want to set or clear a flag in an MDIO register, but avoid
writing if no change is required since this can have side-effects.
Encapsulate this in a function, mdio_clause45_set_flag().
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 05:42:42 +0000 (21:42 -0800)]
sfc: Don't count RX checksum errors during loopback self-test
The loopback self-test checks that IP packets with incorrect checksums
are not altered when sent on a queue with checksum generation off.
These should not contribute to RX error statistics.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Neil Turton [Sat, 13 Dec 2008 05:41:06 +0000 (21:41 -0800)]
sfc: Add option to use a separate channel for TX completions
In a bidirectional forwarding test, we find that the best performance
is achieved by sending the TX completion interrupts from one NIC to a
CPU which shares an L2 cache with RX completion interrupts from the
other NIC. To facilitate this, add an option (through a module
parameter) to create separate channels for RX and TX completion with
separate IRQs when MSI-X is available.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 05:34:25 +0000 (21:34 -0800)]
sfc: Work around unreliable strap pins
The SFC4000 has strap pins indicating the presence of SPI flash and/or
EEPROM. These pins are also used for GPIO, and in some cases they may
be read wrongly at reset. However, on production boards it must boot
from one or the other device, so we can assume the boot device is
present and read the board config from there.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Sat, 13 Dec 2008 05:33:50 +0000 (21:33 -0800)]
sfc: Clean up waits for flash/EEPROM operations
Make falcon_spi_wait() ignore the write timer - it is only relevant to
write commands, it only works for the device that contains VPD, and it
might not be initialised properly at all.
Rename falcon_spi_fast_wait() to falcon_spi_wait_write(), reflecting
its use, and make it wait up to 10 ms (not 1 ms) since buffered writes
to EEPROM may take this long to complete.
Make both wait functions sleep instead of busy-waiting.
Replace wait for command completion at top of falcon_spi_cmd() with a
single poll; no command should be running when the function starts.
Correct some comments.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Hannes Eder [Sat, 13 Dec 2008 05:18:32 +0000 (21:18 -0800)]
mISDN: comment out unused symbols
Fix this sparse warnings:
drivers/isdn/hardware/mISDN/hfcmulti.c:794: warning: 'vpm_check' defined but not used
drivers/isdn/mISDN/dsp_cmx.c:1546: warning: 'dsp_start_jiffies' defined but not used
Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Hannes Eder [Sat, 13 Dec 2008 05:16:06 +0000 (21:16 -0800)]
mISDN: un-export symbol 'plx_lock'
'plx_lock' is only used within hfcmulti.c.
Fix this warning:
drivers/isdn/hardware/mISDN/hfcmulti.c:176:1: warning: symbol 'plx_lock' shadows an earlier one
drivers/isdn/hardware/mISDN/hfcmulti.c:175:19: originally declared here
Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Hannes Eder [Sat, 13 Dec 2008 05:15:17 +0000 (21:15 -0800)]
mISDN: make global symbols static or include header files
The warnings fixed by including an header file for the appropriate
prototype are marked with "*", for all others the corresonponding
symbol has been made static. This patch fixes all such issues in
mISDN.
Fix this sparse warnings:
drivers/isdn/hardware/mISDN/hfcmulti.c:174:5: warning: symbol 'plxsd_master' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:426:1: warning: symbol 'write_fifo_regio' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:447:1: warning: symbol 'write_fifo_pcimem' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:469:1: warning: symbol 'read_fifo_regio' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:491:1: warning: symbol 'read_fifo_pcimem' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:710:1: warning: symbol 'vpm_init' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:793:1: warning: symbol 'vpm_check' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:816:1: warning: symbol 'vpm_echocan_on' was not declared. Should it be static?
drivers/isdn/hardware/mISDN/hfcmulti.c:848:1: warning: symbol 'vpm_echocan_off' was not declared. Should it be static?
* drivers/isdn/mISDN/l1oip_codec.c:224:1: warning: symbol 'l1oip_law_to_4bit' was not declared. Should it be static?
* drivers/isdn/mISDN/l1oip_codec.c:261:1: warning: symbol 'l1oip_4bit_to_law' was not declared. Should it be static?
* drivers/isdn/mISDN/l1oip_codec.c:281:1: warning: symbol 'l1oip_alaw_to_ulaw' was not declared. Should it be static?
* drivers/isdn/mISDN/l1oip_codec.c:294:1: warning: symbol 'l1oip_ulaw_to_alaw' was not declared. Should it be static?
* drivers/isdn/mISDN/l1oip_codec.c:311:1: warning: symbol 'l1oip_4bit_free' was not declared. Should it be static?
* drivers/isdn/mISDN/l1oip_codec.c:322:1: warning: symbol 'l1oip_4bit_alloc' was not declared. Should it be static?
drivers/isdn/mISDN/core.c:29:1: warning: symbol 'device_lock' was not declared. Should it be static?
drivers/isdn/mISDN/core.c:34:1: warning: symbol 'bp_lock' was not declared. Should it be static?
drivers/isdn/mISDN/core.c:196:1: warning: symbol 'mISDNInit' was not declared. Should it be static?
drivers/isdn/mISDN/core.c:227:6: warning: symbol 'mISDN_cleanup' was not declared. Should it be static?
drivers/isdn/mISDN/stack.c:40:1: warning: symbol 'mISDN_queue_message' was not declared. Should it be static?
* drivers/isdn/mISDN/layer1.c:388:1: warning: symbol 'l1_init' was not declared. Should it be static?
* drivers/isdn/mISDN/layer1.c:400:1: warning: symbol 'l1_cleanup' was not declared. Should it be static?
drivers/isdn/mISDN/layer2.c:469:1: warning: symbol 'iframe_error' was not declared. Should it be static?
drivers/isdn/mISDN/layer2.c:487:1: warning: symbol 'super_error' was not declared. Should it be static?
drivers/isdn/mISDN/layer2.c:496:1: warning: symbol 'unnum_error' was not declared. Should it be static?
drivers/isdn/mISDN/layer2.c:509:1: warning: symbol 'UI_error' was not declared. Should it be static?
drivers/isdn/mISDN/layer2.c:522:1: warning: symbol 'FRMR_error' was not declared. Should it be static?
drivers/isdn/mISDN/layer2.c:1069:1: warning: symbol 'enquiry_cr' was not declared. Should it be static?
* drivers/isdn/mISDN/layer2.c:2196:1: warning: symbol 'Isdnl2_Init' was not declared. Should it be static?
* drivers/isdn/mISDN/layer2.c:2210:1: warning: symbol 'Isdnl2_cleanup' was not declared. Should it be static?
drivers/isdn/mISDN/tei.c:397:1: warning: symbol 'random_ri' was not declared. Should it be static?
* drivers/isdn/mISDN/timerdev.c:277:1: warning: symbol 'mISDN_inittimer' was not declared. Should it be static?
* drivers/isdn/mISDN/timerdev.c:288:6: warning: symbol 'mISDN_timer_cleanup' was not declared. Should it be static?
drivers/isdn/mISDN/dsp_core.c:164:12: warning: symbol 'mISDN_dsp_revision' was not declared. Should it be static?
drivers/isdn/mISDN/dsp_cmx.c:1543:5: warning: symbol 'samplecount' was not declared. Should it be static?
drivers/isdn/mISDN/dsp_cmx.c:1546:5: warning: symbol 'dsp_start_jiffies' was not declared. Should it be static?
drivers/isdn/mISDN/dsp_cmx.c:1547:16: warning: symbol 'dsp_start_tv' was not declared. Should it be static?
drivers/isdn/mISDN/dsp_tones.c:239:3: warning: symbol 'pattern' was not declared. Should it be static?
drivers/isdn/mISDN/dsp_audio.c:33:4: warning: symbol 'dsp_audio_ulaw_to_alaw' was not declared. Should it be static?
Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Hannes Eder [Sat, 13 Dec 2008 05:13:45 +0000 (21:13 -0800)]
mISDN: consistently define 'debug' as '*u_int'
Impact: change data type for variable 'debug' from *int to *u_int,
same for the argument type of mISDN_inittimer
In "core.h" mISDN_inittimer is declared with the argument type "*u_int", make
the definition in "timerdev.c" match this.
This fixes also this warnings:
drivers/isdn/mISDN/layer1.c:391:8: warning: incorrect type in assignment (different signedness)
drivers/isdn/mISDN/layer1.c:391:8: expected int *static [toplevel] debug
drivers/isdn/mISDN/layer1.c:391:8: got unsigned int [usertype] *deb
drivers/isdn/mISDN/layer2.c:2200:8: warning: incorrect type in assignment (different signedness)
drivers/isdn/mISDN/layer2.c:2200:8: expected int *static [toplevel] debug
drivers/isdn/mISDN/layer2.c:2200:8: got unsigned int [usertype] *deb
drivers/isdn/mISDN/socket.c:769:8: warning: incorrect type in assignment (different signedness)
drivers/isdn/mISDN/socket.c:769:8: expected int *static [toplevel] debug
drivers/isdn/mISDN/socket.c:769:8: got unsigned int [usertype] *deb
Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Hannes Eder [Sat, 13 Dec 2008 05:11:28 +0000 (21:11 -0800)]
mISDN: use NULL pointer instead of plain integer
Fix more than 100 (all remaining in mISDN) sparse warnings:
drivers/isdn/hardware/mISDN/hfcmulti.c:***:**: warning: Using plain integer as NULL pointer
drivers/isdn/mISDN/dsp_tones.c:***:**: warning: Using plain integer as NULL pointer
drivers/isdn/mISDN/dsp_pipeline.c:***:**: warning: Using plain integer as NULL pointer
Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Tomas Winkler [Thu, 11 Dec 2008 18:33:41 +0000 (10:33 -0800)]
iwlwifi: add contact email to MODULE_AUTHOR
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Tomas Winkler [Thu, 11 Dec 2008 18:33:40 +0000 (10:33 -0800)]
iwlwifi: remove 4965 from common uCode API structures
This patch removes 4965 from common uCode API structures. Also updates
iwlagn commands with 3945 specific RX command in preparation for 3945 port.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Acked-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Tomas Winkler [Thu, 11 Dec 2008 18:33:39 +0000 (10:33 -0800)]
iwlwifi: remove includes of iwl-helpers.h where not needed
This patch removes includes of iwl-helpers.h where not needed
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Acked-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Tomas Winkler [Thu, 11 Dec 2008 18:33:38 +0000 (10:33 -0800)]
iwlwifi: remove unused clip_groups priv member
Remove clip_groups from priv and related structure.
This code is for 3945 only and was renamed to 4965 in
when code was split.
Also remove unused RATE definitions
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Acked-by: Samuel Ortiz <sameo@linux.intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Mohamed Abbas [Thu, 11 Dec 2008 18:33:37 +0000 (10:33 -0800)]
iwlwifi: fix resume while txpower off
This patch take care of coming out rfkill when the driver is up while
rfkill is on by restarting interface.
Signed-off-by: Mohamed Abbas <mohamed.abbas@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Zhu, Yi [Thu, 11 Dec 2008 18:33:36 +0000 (10:33 -0800)]
iwlwifi: use iwl_poll_direct_bit in EEPROM reading
The patch replaces the current reading EEPROM loop iterations with
iwl_poll_direct_bit(). It also fixes some comment error.
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Thu, 11 Dec 2008 16:22:13 +0000 (18:22 +0200)]
ath9k: Do not remove header padding on RX from short frames
The 802.11 header is only padded to 32-bit boundary when the frame has
a non-zero length payload. In other words, control frames (e.g., ACK)
do not have a padding and we should not try to remove it. This fixes
monitor mode for short control frames. In addition, the hdrlen&3 use
is described in more detail to make it easier to understand how the
padding length is calculated.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rami Rosen [Thu, 11 Dec 2008 12:00:25 +0000 (14:00 +0200)]
mac80211: misc cleanups
This patch removes unneeded member (skbuff) from
ieee80211_ibss_add_sta() method in its declaration (in ieee80211_i.h)
and its callers (in rx.c and mlme.c)
This patch removes unneeded member from struct ieee80211_rx_data
in ieee80211_i.h.
(Originally posted as two patches. -- JWL)
Signed-off-by: Rami Rosen <ramirose@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Wed, 10 Dec 2008 16:48:48 +0000 (17:48 +0100)]
rfkill: strip pointless notifier chain
No users, so no reason to have it.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Anna Neal [Tue, 9 Dec 2008 21:23:45 +0000 (13:23 -0800)]
libertas: Create sysfs entry for changing the mesh probe response limit
This patch adds the ability to change the number of probe response retries sent
by the mesh interface.
In dense networks it is recommended to change this value to zero to reduce
traffic congestion.
Signed-off-by: Anna Neal <anna@cozybit.com> Signed-off-by: Andrey Yurovsky <andrey@cozybit.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Wed, 10 Dec 2008 12:51:47 +0000 (14:51 +0200)]
mac80211: Disable requests for new scans in AP mode
AP mode operations are seriously affected if mac80211 runs through a
multi-second scan while the AP is trying to send Beacon frames on the
operation channel. While this could be implemented in a way that does
not cause too many problems, it is not very simple and will require
synchronization with Beacon frame scheduling in the drivers (scan one
channel at a time between Beacon frames). Furthermore, such scanning
takes quite a bit longer time and existing userspace applications
would be likely to timeout while waiting for the results.
For now, just refuse requests for new scans (SIOCSIWSCAN) when in AP
mode. In practice, this moves the rejection from iwl* drivers into
mac80211 to make it apply to every mac80211-based driver.
This issue shows up in associated stations getting disconnected when
something (e.g., Network Manager) requests a scan while the interface
is in AP mode. When doing this continuously (e.g., NM does it every 120
seconds), the network gets close to useless.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Helmut Schaa [Wed, 10 Dec 2008 12:17:26 +0000 (13:17 +0100)]
ipw2200: fix scanning while associated
This patch fixes sporadic firmware restarts when scanning while associated.
The firmware will quietly cancel a scan (while associated) if the dwell time
for a channel to be scanned is larger than the time it may stay away from the
operating channel (because of DTIM catching). Unfortunately the driver is not
notified about the canceled scan and therefore the scan watchdog timeout will
be hit and the driver causes a firmware restart which results in
disassociation. This mainly happens on passive channels which use a dwell time
of 120 whereas a typical beacon interval is around 100.
The patch changes the dwell time for passive channels to be slightly smaller
than the actual beacon interval to work around the firmware issue. Furthermore
the number of allowed beacon misses is increased from one to three as otherwise
most scans (while associated) won't complete successfully.
However scanning while associated will still fail in corner cases such as a
beacon intervals below 30.
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Larry Finger [Wed, 10 Dec 2008 05:34:27 +0000 (23:34 -0600)]
rtl8187: Use usb anchor facilities to manage urbs
When SLUB debugging is enabled in the kernel, and the boot command includes
the option "slub_debug=P", rtl8187 encounters a GPF due to a read-after-free
of a urb.
Following the example of changes in p54usb to fix the same problem, the code
has been modified to use the usb_anchor_urb() method. With this change, the
USB core handles the freeing of urb's.
This patch fixes the problem reported in Kernel Bugzilla #12185
(http://bugzilla.kernel.org/show_bug.cgi?id=12185).
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Tested-by: Hin-Tak Leung <htl10@users.sourceforge.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bob Copeland [Wed, 10 Dec 2008 04:05:38 +0000 (23:05 -0500)]
ath5k: fix endianness of bitwise ops when installing mic
Fix these bugs found by sparse:
ath5k/pcu.c:1102:21: warning: restricted __le32 degrades to integer
ath5k/pcu.c:1102:13: warning: incorrect type in assignment (different base types)
ath5k/pcu.c:1102:13: expected restricted __le32 <noident>
ath5k/pcu.c:1102:13: got unsigned int
ath5k/pcu.c:1104:20: warning: restricted __le32 degrades to integer
ath5k/pcu.c:1104:13: warning: incorrect type in assignment (different base types)
ath5k/pcu.c:1104:13: expected restricted __le32 <noident>
ath5k/pcu.c:1104:13: got unsigned int
Changes-licensed-under: ISC
Reported-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
David Kilroy [Tue, 9 Dec 2008 21:46:29 +0000 (21:46 +0000)]
orinoco: Fix inappropriate use of IRQ_BAP
This hardware buffer should only be used from an interrupt. The
wireless event generation functions are called from a workqueue, so use
USER_BAP instead.
Signed-off-by: David Kilroy <kilroyd@googlemail.com> Signed-off-by: Pavel Roskin <proski@gnu.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
David Kilroy [Tue, 9 Dec 2008 21:46:28 +0000 (21:46 +0000)]
orinoco: Fix function names used in debug strings
Signed-off-by: David Kilroy <kilroyd@googlemail.com> Signed-off-by: Pavel Roskin <proski@gnu.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Winkler, Tomas [Tue, 9 Dec 2008 19:29:01 +0000 (11:29 -0800)]
iwlwifi: remove qos module parameter
The ability of disabling qos from module params is not required anymore.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Winkler, Tomas [Tue, 9 Dec 2008 19:29:00 +0000 (11:29 -0800)]
iwlwifi: 3945 remove qos module parameter
The ability of disabling qos from module params is not required
anymore.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Winkler, Tomas [Tue, 9 Dec 2008 19:28:58 +0000 (11:28 -0800)]
iwlwifi: change email contact information
This patch replaces personal emails with hopefully
always valid Intel Linux Wireless, which will be routed
to a current maintainer
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
mac80211: integrate sta_notify_ps cmds into sta_notify
This patch replaces the newly introduced sta_notify_ps function,
which can be used to notify the driver about every power state
transition for all associated stations, by integrating its functionality
back into the original sta_notify callback.
Signed-off-by: Christian Lamparter <chunkeey@web.de> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
p54usb: rewriting rx/tx routines to make use of usb_anchor's facilities
Alan Stern found several flaws in p54usb's implementation and annotated:
"usb_kill_urb() and similar routines do not expect an URB's completion
routine to deallocate it. This is almost obvious -- if the URB is deallocated
before the completion routine returns then there's no way for usb_kill_urb
to detect when the URB actually is complete."
This patch addresses all known limitations in the old implementation and fixes
khub's "use-after-freed" hang, when SLUB debug's poisoning option is enabled.
Signed-off-by: Christian Lamparter <chunkeey@web.de> Cc: stable@kernel.org Tested-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
ath9k: BH shouldn't be enabled when hardirqs are disabled.
ath_tx_complete_buf uses a BH version of spinlock and so releasing
the lock enables BH which is incorrect when called from sta_notify
callback as MAC80211 disables hardirqs before the driver callback
is called.
As ath_tx_complete_buf is shared between user and softirq context
using normal spinlock may not be appropriate. Though the proper
fix would be to cleanup the context properly in the driver code,
this would be an interim fix to avoid kernel warning.
Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
There's no driver that actually does fragmentation on the
device, and the callback is buggy (when it returns an error,
mac80211's fragmentation status is changed so reading the
frag threshold from userspace reads the new value despite
the error). Let's just remove it, if we really find some
hardware supporting it we can add it back later.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rami Rosen [Tue, 9 Dec 2008 06:37:28 +0000 (08:37 +0200)]
iwlwifi: fix build error (iwl-rx.c).
This patch adds #ifdef CONFIG_IWLWIFI_DEBUG in iwl_rx_reply_rx()
method in iwlwifi/iwl-rx.c) to avoid build error caused by "iwlwifi:
implement iwl_debug_report_frame for iwlagn".
Signed-off-by: Rami Rosen <ramirose@gmail.com> Acked-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 8 Dec 2008 23:10:30 +0000 (00:10 +0100)]
mac80211: only create default STA interface if supported
Drivers will support this, obviously, but this forces them to
set it up properly.
(This includes the fix posted as "mac80211: fix ifmodes check" and
tested in wireless-testing by Hin-Tak and others. -- JWL)
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Reported-by: Larry Finger <Larry.Finger@lwfinger.net> Tested-by: Hin-Tak Leung <htl10@users.sourceforge.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
ath9k: Incorrect band enum causes invalid antenna configuration.
It's a regression from the patch titled "ath9k: Use mac80211's band
macros and remove enum hal_freq_band". MAC80211 band macros can't be
mapped directly with our hal band enum.
Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Mon, 8 Dec 2008 11:39:04 +0000 (12:39 +0100)]
cfg80211: fix nl80211 frequency handling
Fix two small bugs with HT frequency setting:
* HT is accepted even when the driver is incapable
* HT40 is accepted when the driver cannot do 40 MHz
(both on the selected band)
Also simplify the code a little.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Sujith [Sun, 7 Dec 2008 16:12:10 +0000 (21:42 +0530)]
ath9k: Maintain rate table choice after association
A scan run after association would change sc_curmode which is
used to get the current rate table. This patch fixes it
by removing sc_curmode and setting the rate table in usage in cur_rate_table
on association.
Signed-off-by: Sujith <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Sujith [Sun, 7 Dec 2008 16:11:37 +0000 (21:41 +0530)]
ath9k: Fix bug in rate table management
The proper rate table wouldn't be used if a disassoc
happens and a new attempt is made to associate using
wpa_supplicant. This patch fixes it by storing the rate
table to be used on association.
Signed-off-by: Sujith <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Fri, 5 Dec 2008 18:43:27 +0000 (20:43 +0200)]
ath9k: Disable staggered Beacon frame scheduling
It looks like there are some issues in the current ath9k version as
far as staggered Beacon frame scheduling is concerned. This results in
Beacon frame timestamp being off by 25 milliseconds or so which can
cause issues with multicast power save buffering in AP mode. Some
client stations fail to receive multicast frames when there is this
large an offset between TBTT and actual Beacon transmission time.
Since ath9k does not yet support multiple BSSes anyway, the staggered
Beacon frame scheduling is just increasing the number of interrupts at
this point. The easiest fix for the timestamp offset is to disable
staggered Beacon frames for now. We need to redesign beacon.c anyway
when adding multi-BSS support with mac80211 since the existing code
depends on different mechanism for Beacon frame transmission.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Fri, 5 Dec 2008 18:42:45 +0000 (20:42 +0200)]
ath9k: Free Beacon skbs in AP mode
Fix a memory leak where AP mode did not free transmitted Beacon frame
skbs.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com> Acked-by: Pat Erley <pat-lkml@erley.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Zhu, Yi [Fri, 5 Dec 2008 15:58:41 +0000 (07:58 -0800)]
iwlwifi: use rmb/wmb to protect indirect mmio operation
This patch protects iwlwifi indirect mmio operations with rmb() and
wmb(). It makes sure CPU reordering won't affect our indirect mmio
access.
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Zhu, Yi [Fri, 5 Dec 2008 15:58:40 +0000 (07:58 -0800)]
iwlwifi: iwl_poll_{direct_}bit cleanup
The patch merges implementation of iwl_poll_bit() and
iwl_poll_direct_bit() by letting the latter be a special case of
the former.
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Zhu, Yi [Fri, 5 Dec 2008 15:58:39 +0000 (07:58 -0800)]
iwlwifi: fix "MAC in deep sleep" error
This patch fixes the misue of CSR_GP_CNTRL with CSR_RESET address
in polling the CSR_GP_CNTRL_REG_FLAG_MAC_CLOCK_READY bit in
iwl4965_apm_reset(). This causes "MAC in deep sleep" error sometimes.
The patch also fixes the timeout value and the iwl_poll_bit() return
value check.
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Acked-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Zhu, Yi [Fri, 5 Dec 2008 15:58:38 +0000 (07:58 -0800)]
iwlwifi: fix time interval misuse in iwl_poll_{direct_}bit
The patch fixes the misuse of microsecond with millisecond in the
polling mechanism of the iwlwifi driver. The impact of this problem
is the unacceptable latency for the whole system (especially during
bringing down the wlan interface).
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Acked-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Abbas, Mohamed [Fri, 5 Dec 2008 15:58:37 +0000 (07:58 -0800)]
iwl3945: Fix rate scale for B-mode connection
This patch make sure we use only CCK rate for B only network.
For 3945 driver, it sets REPLY_RATE_SCALE command every time
we connect to a new network. In this command we set for every
rate the number of try and next rate. The problem mac80211 reports
same mode for both B and G mode as IEEE80211_BAND_2GHZ which will cause
using invalid rate other than CCK in B only network. THis patch
on association will examine sta valid rate on association, if no
OFDM rate in valid available rates it considers it as B only mode so
we can set REPLY_RATE_SCALE command with valid B only network and only
choose CCK rate in rate scaling.
Signed-off-by: Mohamed Abbas <mohamed.abbas@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
iwlwifi: implement iwl_debug_report_frame for iwlagn
The old version of this code was copied from 3945 and never updated. This patch
cleans up structs that do not apply and accounts for other changes from
3945->iwlagn (e.g., PHY info can come in a separate cmd response from the
ucode.)
Signed-off-by: Daniel Halperin <daniel.c.halperin@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Reinette Chatre [Thu, 4 Dec 2008 22:49:08 +0000 (14:49 -0800)]
mac80211: remove WARN_ON() from ieee80211_hw_config
ieee80211_hw_config can return an error when the hardware
has rfkill enabled. A WARN_ON() is too harsh for this
failure as it is a valid scenario. Only comment this warning
as we would like to have it back when rfkill is integrated into
mac80211.
Also reintroduce propagation of error if ieee80211_hw_config fails
in ieee80211_config_beacon.