summaryrefslogtreecommitdiff
path: root/drivers/net
AgeCommit message (Collapse)Author
2013-10-18rt2x00: rt2800pci: move SoC specific code into a separate moduleGabor Juhos
The PCI and SoC specific drivers are using separate code now so it is not reasonable to use the same module for both drivers anymore. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use separate hwcrypt_disabled callback for SoC devicesGabor Juhos
The 'rt2800pci_hwcrypt_disabled' function is the only PCI specific callback which is used by the SoC driver. Create a clone of that to get rid of the dependency. Even though the two functions are using the same variable, but the SoC specific code will be moved into a separate module which will have its own 'modparam_nohwcrypt' variable. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: move rt2800mmio_enable_radio function to another moduleGabor Juhos
Move the function into the rt2800mmio module, in order to make it usable from other modules. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: split rt2800pci_enable_radio functionGabor Juhos
The function is called for PCI and SoC devices however the MCU related part of the function has no effect on SoC devices. Move the common part of the function into a separate helper and use that for the SoC devices. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: rename rt2800pci_disable_radio functionGabor Juhos
The function contain code for SoC devices only. Rename the function to 'rt2800soc_disable_radio' and move it to the SoC specific section. Use the renamed function in the SoC specific code only and remove the 'if rt2x00_is_soc(rt2x00dev)' condition from the function body. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use separate set_state callback for SoC devicesGabor Juhos
The 'rt2800pci_set_state' function uses MCU commands to set the device state, however these have no effect on SoC devices. Use a different set_state callback which does not use the MCU fcuntions. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use separate firmware callbacks for SoC devicesGabor Juhos
Use empty firmware callbacks for SoC devices because those don't require firmware. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use separate read_eeprom callback for SoC devicesGabor Juhos
Rename the 'rt2800pci_read_eeprom_soc function' to 'rt2800soc_read_eeprom' and use that directly in the SoC specific 'rt2800_ops' structure. Also move the 'rt2800pci_eeprom_read' function into an 'ifdef PCI' section and remove the 'rt2800pci_read_eeprom_soc' call from that. Additionally, remove the dummy inline eeprom functions. Those are not used anymore. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use separate ops for the SoC driverGabor Juhos
This makes it possible to use different callback functions for PCI and SoC devices which will allow to move the SoC driver into a separate module. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: move initialization functions to the rt2800mmio moduleGabor Juhos
Move the functions into a separate module, in order to make those usable from other modules. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use rt2800mmio prefix for initialization functionsGabor Juhos
The functions are used for devices with memory mapped I/O and contain no PCI specific code at all. Use rt2800mmio prefix instead of rt2800pci in the function names to reflect that. The patch contains no functional changes. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: move queue functions to the rt2800mmio moduleGabor Juhos
Move the functions into a separate module, in order to make those usable from other modules. Also move the queue register offset macros from rt2800pci.h into rt2800mmio.h. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use rt2800mmio prefix for queue functionsGabor Juhos
The functions are used for devices with memory mapped I/O and contain no PCI specific code at all. Use rt2800mmio prefix instead of rt2800pci in the function names to reflect that. The patch contains no functional changes. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: move interrupt functions to the rt2800mmio moduleGabor Juhos
Move the functions into a separate module, in order to make those usable from other modules. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use rt2800mmio prefix for interrupt functionsGabor Juhos
The functions are used for devices with memory mapped I/O and contain no PCI specific code at all. Use rt2800mmio prefix instead of rt2800pci in the function names to reflect that. The patch contains no functional changes. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: move RX control handler functions to the rt2800mmio moduleGabor Juhos
Move the functions into a separate module, in order to make those usable from other modules. Also move the RX descriptor related defines from rt2800pci.h into rt2800mmio.h Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use rt2800mmio prefix for RX control handler functionsGabor Juhos
The functions are used for devices with memory mapped I/O and contain no PCI specific code at all. Use rt2800mmio prefix instead of rt2800pci in the function names to reflect that. The patch contains no functional changes. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: move TX descriptor functions to the rt2800mmio moduleGabor Juhos
Move the functions into a separate module, in order to make those usable from other modules. Also move the TX descriptor related defines from rt2800pci.h into rt2800mmio.h. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800pci: use rt2800mmio prefix for TX descriptor functionsGabor Juhos
The functions are used for devices with memory mapped I/O and contain no PCI specific code at all. Use rt2800mmio prefix instead of rt2800pci in the function names to reflect that. The patch contains no functional changes. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: create a new module for rt2800 MMIO codeGabor Juhos
Create a new module for common code which can be used for rt2800 device with memory mapped I/O. It is an empty module for now, but it will be populated by subsequent patches. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18drivers: net: wireless: Fix wrong check for reassociation request retry counterFelipe Pena
There is a typo where the checking for priv->ReAssociationRequestRetryCnt must be, it was checking for priv->AssociationRequestRetryCnt instead. Signed-off-by: Felipe Pena <felipensp@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: fix brcmf_sdcard_recv_chain() for host without sg supportArend van Spriel
If the SDIO host controller does not support scatter-gather the glom superframe must be transfered from the device and the data for each packet in the queue must be extracted from it. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: fix brcmf_sdio_txpkt_prep() for host without sg supportArend van Spriel
When running on a host controller that does not support scatter-gather transfers the function brcmf_sdio_txpkt_prep() should not add tail padding buffers. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: fix brcmf_sdcard_send_pkt() for host without sg supportArend van Spriel
If the host does not support scatter-gather transmit the packets in the pktq individually using brcmf_sdio_buffrw(). Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: remove stale code from brcmf_sdcard_recv_chain()Arend van Spriel
The function brcmf_sdcard_recv_chain() has been reworked with commit "brcmfmac: add sdio sg list support", but the incr_fix variable is only assigned but not used so removing it now. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: verify result of brcmf_sdio_addrprep() callsArend van Spriel
Not all calls to the function brcmf_sdio_addrprep() check the return value, but it may fail so better verify it. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: rework single packet transfersArend van Spriel
The function brcmf_sdio_sglist_rw() does a different code path when packet queue length is 1. Move this to a separate function reducing overhead in the calling context. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: rename brcmf_sdio_buffrw()Arend van Spriel
The function brcmf_sdio_buffrw() is intended to be used for transfering list of packets using scatter-gather functionality. Rename function to brcmf_sdio_sglist_rw() to clarify this. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: rework scatter-gather code in brcmf_sdio_buffrw()Arend van Spriel
Moving a number of assignments outside of the loop as they are the same for each request. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: determine host controller related variables during probeArend van Spriel
Instead of determining the limits for scatter-gather MMC transfer request upon each transmit it is now determined during the probe of the SDIO function. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: rename variable max_seg_sz to max_seg_cnt for clarityArend van Spriel
The variable max_seg_sz in brcmf_sdio_buffrw() respresents the maximum number of buffers that can be sent in one MMC transfer request. Rename it to max_seg_cnt to avoid confusion. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: add tracepoint for capturing the SDPCM headerArend van Spriel
Having the SDPCM header information in the traces is a valuable piece of information. Reviewed-by: Franky Lin <frankyl@broadcom.com> Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18brcmfmac: store address in trace_brcmf_hexdump()Arend van Spriel
The trace function trace_brcmf_hexdump() stores the length, but having the address of the buffer being dumped helps putting it in context. Reviewed-by: Franky Lin <frankyl@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: add TX99 supportLuis R. Rodriguez
TX99 support enables Specific Absorption Rate (SAR) testing. SAR is the unit of measurement for the amount of radio frequency(RF) absorbed by the body when using a wireless device. The RF exposure limits used are expressed in the terms of SAR, which is a measure of the electric and magnetic field strength and power density for transmitters operating at frequencies from 300 kHz to 100 GHz. Regulatory bodies around the world require that wireless device be evaluated to meet the RF exposure limits set forth in the governmental SAR regulations. In the examples below, for more bit rate options see the iw TX bitrate setting documentation: http://wireless.kernel.org/en/users/Documentation/iw#Modifying_transmit_bitrates Example usage: iw phy phy0 interface add moni0 type monitor ip link set dev moni0 up iw dev moni0 set channel 36 HT40+ iw set bitrates mcs-5 4 echo 10 > /sys/kernel/debug/ieee80211/phy0/ath9k/tx99_power echo 1 > /sys/kernel/debug/ieee80211/phy0/ath9k/tx99 Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: check for NULL rate when using ieee80211_get_rts_cts_rate()Luis R. Rodriguez
ieee80211_get_rts_cts_rate() can return NULL, so don't rely on its members when it does return NULL. Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com> Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath: add support for proper dynamic regulatory hintsLuis R. Rodriguez
This enables support for dynamic user regulatory hints. This is enabled only when CFG80211_CERTIFICATION_ONUS is selected. For US and JP this is explicitly disabled unless the systems are being used for strict controlled testing. Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath: split user and driver reguluatory hint parsingLuis R. Rodriguez
On the regulatory notifier split up the parsing of the hints coming from drivers or user. We'll treat these separately. Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath: move common dynamic regulatory domain setting to a helperLuis R. Rodriguez
This moves the dynamic regulatory domain selection code into a helper. Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800lib: autodetect 5GHz band supportGabor Juhos
If the RF chip supports more than 14 channels that indirectly means that it supports the 5GHz band. Use this fact to enable 5GHz band support instead of setting SUPPORT_BAND_5GHZ separately for each RF chip. Also move the setup code of the 2GHz band to the same place. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800lib: use switch statement for RF specific setupGabor Juhos
It is much more readable than multiple if-else-if statements. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18rt2x00: rt2800lib: use {tx,rx}_chain_num to avoid superfluous EEPROM accessGabor Juhos
The {rx,tx}_chain_num fields of rt2x00dev->default_ant contains the number of RX and TX chains already when the rt2800_probe_hw_mode() function runs. Use those values instead of parsing the EEPROM configuration values again. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k/ath: move dfs pattern detector to athJanusz Dziedzic
Move the DFS pattern detector code to the ath module so the other Atheros drivers can make us of it. This makes no functional changes. Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Reviewed-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: dfs use CFG80211_CERTIFICATION_ONUS flagJanusz Dziedzic
Use CFG80211_CERTIFICATION_ONUS flag in the DFS detector code. This is required as a preparation for moving DFS detector code from ath9k to ath module. Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Reviewed-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: dfs move ath_dfs_pool_statsJanusz Dziedzic
Move ath_dfs_pool_stats to dfs_pattern_detector code to be not specyfic only for ath9k. Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Reviewed-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: dfs kill ath9k specyfic codeJanusz Dziedzic
Kill of using ath9k_hw_common() function in dfs detector code. Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Reviewed-by: Luis R. Rodriguez <mcgrof@do-not-panic.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18libertas: move firmware lifetime handling to firmware.cDan Williams
Previously, each bus type was responsible for freeing the firmware structure, but some did that badly. Move responsibility for freeing firmware into firmware.c so that it's done once and correctly, instead of happening in multiple places in bus-specific code. This fixes a use-after-free bug found by Dr. H. Nikolaus Schaller where the SDIO code forgot to NULL priv->helper_fw after freeing it. Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: add HT40 spectral scan capabilityLorenzo Bianconi
Add spectral scan feature on HT40 channels for ath9k. This patch extends previous capability added by Simon Wunderlich Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Reviewed-by: Simon Wunderlich <simon.wunderlich@s2003.tu-chemnitz.de> Tested-by: Simon Wunderlich <simon.wunderlich@s2003.tu-chemnitz.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18ath9k: add noise floor parameter to ath9k_hw_getchan_noiseLorenzo Bianconi
Add nf parameter to ath9k_hw_getchan_noise() in order to compute NF for EXT chains with the same scale of noise floor calculated on CTL chains. ath9k_hw_getchan_noise() will be used in ath_process_fft() for spectral scan on HT40 channels Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2013-10-18Merge branch 'for-john' of ↵John W. Linville
git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next
2013-10-18Merge branch 'for-linville' of git://github.com/kvalo/athJohn W. Linville