summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* ath9k: enable TX/RX data byte swap for AR9330Gabor Juhos2011-06-221-1/+1
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: configure RF channel frequency for AR9330Gabor Juhos2011-06-221-1/+13
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: fix channel frequency calculation for AR9340Gabor Juhos2011-06-221-1/+1
| | | | | | | | A multiplication is missing from the current formula. Cc: Vasanthakumar Thiagarajan <vasanth@atheros.com> Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: read spur frequency information from eeprom for AR9330Gabor Juhos2011-06-221-2/+2
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: don't enable LDPC for AR9330Gabor Juhos2011-06-221-1/+1
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: use different BB watchdog timeout value for AR9330Gabor Juhos2011-06-221-1/+4
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: add AR9330 specific PLL initializationGabor Juhos2011-06-221-1/+34
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: initialize rx gain table for AR9330Gabor Juhos2011-06-221-2/+22
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: initialize tx gain table for AR9330Gabor Juhos2011-06-221-4/+44
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: initialize mode registers for AR9330Gabor Juhos2011-06-222-1/+112
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: add AR9330 initvalsGabor Juhos2011-06-222-0/+2227
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: add platform device id for AR9330Gabor Juhos2011-06-221-0/+4
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: add MAC revision detection for AR9330Gabor Juhos2011-06-224-0/+12
| | | | | | | | | | | | | The AR9330 1.0 and 1.1 are using the same revision, thus it is not possible to distinguish the two chips. The platform setup code can distinguish the chips based on the SoC revision. Add a callback function to ath9k_platform_data in order to allow getting the revision number from the platform code. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: define device id for AR9330Gabor Juhos2011-06-221-0/+1
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: define mac version for AR9330Gabor Juhos2011-06-222-1/+20
| | | | | Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k_hw: Fix calculation of PAPRD training power at 5GhzMohammed Shafi Shajakhan2011-06-221-1/+17
| | | | | | | | higher the chainmask, lesser the power_delta to be added to the paprd_training_power Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* nl80211: use netlink consistent dump feature for BSS dumpsJohannes Berg2011-06-221-4/+8
| | | | | | | | | | | | | | | | Use the new consistent dump feature from (generic) netlink to advertise when dumps are incomplete. Readers may note that this does not initialize the rdev->bss_generation counter to a non-zero value. This is still OK since the value is modified only under spinlock when the list is modified. Since the dump code holds the spinlock, the value will either be > 0 already, or the list will still be empty in which case a consistent dump will actually be made (and be empty). Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* mwifiex: remove casts of void pointersAmitkumar Karwar2011-06-2213-177/+129Star
| | | | | | | | | | | | | | | In some cases local pointers are used to cast void pointers passed to the function. Those unnecessary local pointers are also removed. This patch was inspired by Joe Perches' patch [PATCH net-next 1/2] wireless: Remove casts of void *; and the comments from Julian Calaby. Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Cc: Joe Perches <joe@perches.com> Cc: Julian Calaby <julian.calaby@gmail.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* zd1211rw: detect stalled beacon interrupt fasterJussi Kivilinna2011-06-221-1/+2
| | | | | | | | | | | | As USB_INT_ID_RETRY_FAILED can override USB_INT_ID_REGS, beacon interrupt (CR_INTERRUPT) might be lost. Problem is that when device trigger CR_INTERRUPT it disables HW interrupt. Now if USB_INT_ID_REGS with CR_INTERRUPT gets lost, beacon interrupt stays disabled until beacon watchdog notices the stall. This happen very often on heavy TX. Improve watchdog to trigger earlier, after three missing beacon interrupts. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* zd1211rw: don't let zd_mac_config_beacon() run too long from beacon ↵Jussi Kivilinna2011-06-221-7/+12
| | | | | | | | | | | | | interrupt handler zd_mac_config_beacon() has only limited time to set up beacon when called from beacon interrupt handler/worker. So do not let it retry acquiring beacon fifo semaphore in interrupt handler. Beacon fifo semaphore should not be locked by firmware anyway at this time, it's only locked when device is using/txing beacon. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* zd1211rw: handle lost read-reg interruptsJussi Kivilinna2011-06-222-21/+109
| | | | | | | | | | | | | | | | | | Device losses read-reg interrupts. By looking at usbmon it appears that USB_INT_ID_RETRY_FAILED can override USB_INT_ID_REGS. This causes read command to timeout, usually under heavy TX. Fix by retrying read registers again if USB_INT_ID_RETRY_FAILED is received while waiting for USB_INT_ID_REGS. However USB_INT_ID_REGS is not always lost but is received after USB_INT_ID_RETRY_FAILED and is usually received by the retried read command. USB_INT_ID_REGS of the retry is then left unhandled and might be received by next read command. Handle this by ignoring previous USB_INT_ID_REGS that doesn't match current read command request. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* zd1211rw: only update HW beacon if new beacon differs from currectJussi Kivilinna2011-06-222-13/+64
| | | | | | | | Update HW beacon only when needed. This appears to make device work in AP-mode (dtim_period=1) somewhat more stable. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* zd1211rw: make 'handle_rx_packet: invalid, small RX packet' message debug-onlyJussi Kivilinna2011-06-221-2/+2
| | | | | | | | This message is should be debug-only as it tells almost nothing useful. It also happens very often and just floods logs. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* zd1211rw: fix invalid signal values from deviceJussi Kivilinna2011-06-222-2/+24
| | | | | | | | | | | | | Driver uses IEEE80211_HW_SIGNAL_UNSPEC and so signal values reported to mac80211 should be in range 0..100. Sometimes device return out of range values. These out of range values can then trigger warning in cfg80211_inform_bss_frame. This patch adds checks to enforce range returned from driver to mac80211 be in 0..100 range. Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* netlink: advertise incomplete dumpsJohannes Berg2011-06-224-0/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Consider the following situation: * a dump that would show 8 entries, four in the first round, and four in the second * between the first and second rounds, 6 entries are removed * now the second round will not show any entry, and even if there is a sequence/generation counter the application will not know To solve this problem, add a new flag NLM_F_DUMP_INTR to the netlink header that indicates the dump wasn't consistent, this flag can also be set on the MSG_DONE message that terminates the dump, and as such above situation can be detected. To achieve this, add a sequence counter to the netlink callback struct. Of course, netlink code still needs to use this new functionality. The correct way to do that is to always set cb->seq when a dumpit callback is invoked and call nl_dump_check_consistent() for each new message. The core code will also call this function for the final MSG_DONE message. To make it usable with generic netlink, a new function genlmsg_nlhdr() is needed to obtain the netlink header from the genetlink user header. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: HT-PHY: calibrate radio after switching channelRafał Miłecki2011-06-221-1/+7
| | | | | | | | | | | | | | | | After uploading radio values calibration goes in. In MMIO dump it is: radio_read(0x002b) -> 0x0008 radio_write(0x002b) <- 0x0008 radio_read(0x002e) -> 0x0004 radio_write(0x002e) <- 0x0000 radio_read(0x002e) -> 0x0000 radio_write(0x002e) <- 0x0004 radio_read(0x002b) -> 0x0008 radio_write(0x002b) <- 0x0009 To find masks and sets, MMIO hacks were used to fool closed driver. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* rt2x00: reset usb devices at probeStanislaw Gruszka2011-06-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When module is reloaded, device may fail to work, with messages: [ 342.211926] phy40 -> rt2x00lib_rxdone_read_signal: Warning - Frame received with unrecognized signal, mode=0x0000, signal=0x0059, type=2. [ 342.314254] phy40 -> rt2x00lib_rxdone_read_signal: Warning - Frame received with unrecognized signal, mode=0x0000, signal=0x004a, type=2. [ 342.416458] phy40 -> rt2x00lib_rxdone: Warning - Wrong frame size 3183 max 2432. [ 342.518605] phy40 -> rt2x00lib_rxdone_read_signal: Warning - Frame received with unrecognized signal, mode=0x0000, signal=0x00c9, type=2. [ 342.620836] phy40 -> rt2x00lib_rxdone_read_signal: Warning - Frame received with unrecognized signal, mode=0x0000, signal=0x00ae, type=1. [ 342.723201] phy40 -> rt2x00lib_rxdone: Warning - Wrong frame size 0 max 2432. [ 342.825399] phy40 -> rt2x00lib_rxdone: Warning - Wrong frame size 0 max 2432. [ 342.927624] phy40 -> rt2x00lib_rxdone: Warning - Wrong frame size 0 max 2432. [ 343.029804] phy40 -> rt2x00lib_rxdone: Warning - Wrong frame size 2491 max 2432. [ 343.132008] phy40 -> rt2x00lib_rxdone: Warning - Wrong frame size 2576 max 2432. [ 343.234326] phy40 -> rt2x00lib_rxdone_read_signal: Warning - Frame received with unrecognized signal, mode=0x0000, signal=0x004c, type=1. [ 343.438723] phy40 -> rt2x00lib_rxdone_read_signal: Warning - Frame received with unrecognized signal, mode=0x0000, signal=0x00e6, type=1. Whereas replugging device make it functional. To solve that problem force reset device during probe. With patch messages are gone. Unfortunately device may sometimes still does not operate correctly after module reload (fail to receive data after associate), but such cases are rarer than without the patch. Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* rt2x00: fix possible memory corruption in case of invalid rxdesc.sizeStanislaw Gruszka2011-06-221-0/+13
| | | | | | | | | | | Sometimes rxdesc descriptor provided by hardware contains invalid (random) data. For example rxdesc.size can be bigger than actual size of the buffer. When this happen rt2x00crypto_rx_insert_iv() corrupt memory doing memmove outside of buffer boundaries. Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: N-PHY: move declarations of chantables functions to correct filesRafał Miłecki2011-06-223-8/+10
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: N-PHY: update switching analog on/offRafał Miłecki2011-06-221-4/+17
| | | | | | | Specs were recently updated. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: HT-PHY: switch radio to requested channelRafał Miłecki2011-06-222-1/+68
| | | | | | | | | Switching channel happens after specific SHM write to B43_SHM_SH_CHAN. This is the way we found it in BCM4331 MMIO dumps. By comparing with N-PHY code we noticed there is routing used for SYN and TX/RX. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: HT-PHY: add place for implementing channel switchingRafał Miłecki2011-06-221-2/+59
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: HT-PHY: define standard structs for channel switchingRafał Miłecki2011-06-225-0/+59
| | | | | Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: HT-PHY: enable radioRafał Miłecki2011-06-221-0/+4
| | | | | | | | The trick was to find 0x810 PHY reg ops close to analog enabling code. To find out proper masks and sets, MMIO hacks were used. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* b43: HT-PHY: implement killing radioRafał Miłecki2011-06-222-2/+15
| | | | | | | | | | | | | Closed drivers kill radio right after reading radio version and MACCTL, so it was easy to find related PHY ops: phy_read(0x0810) -> 0x0000 phy_write(0x0810) <- 0x0000 To find out the mask of above OP, MMIO hack was used to fake read val: phy_read(0x0810) -> 0xffff phy_write(0x0810) <- 0x0000 Signed-off-by: Rafał Miłecki <zajec5@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* Merge branch 'master' of ↵John W. Linville2011-06-2215-458/+1460
|\ | | | | | | master.kernel.org:/pub/scm/linux/kernel/git/padovan/bluetooth-next-2.6
| * Bluetooth: Fix not setting the chan stateVinicius Costa Gomes2011-06-211-1/+1
| | | | | | | | | | | | | | | | When the connection is ready we should set the connection to CONNECTED so userspace can use it. Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * Merge master.kernel.org:/pub/scm/linux/kernel/git/padovan/bluetooth-2.6Gustavo F. Padovan2011-06-212-10/+19
| |\ | | | | | | | | | | | | Conflicts: net/bluetooth/l2cap_core.c
| | * Bluetooth: Fix L2CAP connection establishmentIlia Kolomisnky2011-06-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In hci_conn_security ( which is used during L2CAP connection establishment ) test for HCI_CONN_ENCRYPT_PEND state also sets this state, which is bogus and leads to connection time-out on L2CAP sockets in certain situations (especially when using non-ssp devices ) Signed-off-by: Ilia Kolomisnky <iliak@ti.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| | * Bluetooth: Fix accepting connect requests for defer_setupJohan Hedberg2011-06-141-6/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When authentication completes we shouldn't blindly accept any pending L2CAP connect requests. If the socket has the defer_setup feature enabled it should still wait for user space acceptance of the connect request. The issue only happens for non-SSP connections since with SSP the L2CAP Connect request may not be sent for non-SDP PSMs before authentication has completed successfully. Signed-off-by: Johan Hedberg <johan.hedberg@intel.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| | * Bluetooth: Fix L2CAP security checkLuiz Augusto von Dentz2011-06-131-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With older userspace versions (using hciops) it might not have the key type to check if the key has sufficient security for any security level so it is necessary to check the return of hci_conn_auth to make sure the connection is authenticated Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com> Acked-by: Johan Hedberg <johan.hedberg@intel.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| | * Bluetooth: Do not send SET_EVENT_MASK for 1.1 and earlier devicesVille Tervo2011-06-101-8/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some old hci controllers do not accept any mask so leave the default mask on for these devices. < HCI Command: Set Event Mask (0x03|0x0001) plen 8 Mask: 0xfffffbff00000000 > HCI Event: Command Complete (0x0e) plen 4 Set Event Mask (0x03|0x0001) ncmd 1 status 0x12 Error: Invalid HCI Command Parameters Signed-off-by: Ville Tervo <ville.tervo@nokia.com> Tested-by: Corey Boyle <corey@kansanian.com> Tested-by: Ed Tomlinson <edt@aei.ca> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| | * Bluetooth: Do not ignore errors returned from strict_strtol()David Miller2011-06-101-0/+12
| | | | | | | | | | | | | | | Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| | * Bluetooth: fix shutdown on SCO socketsLuiz Augusto von Dentz2011-06-101-1/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | shutdown should wait for SCO link to be properly disconnected before detroying the socket, otherwise an application using the socket may assume link is properly disconnected before it really happens which can be a problem when e.g synchronizing profile switch. Signed-off-by: Luiz Augusto von Dentz <luiz.dentz-von@nokia.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * | Bluetooth: Remove useless access to the socketVinicius Costa Gomes2011-06-201-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | We already have access to the chan, we don't have to access the socket to get its imtu. Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * | Bluetooth: Fix crash when setting a LE socket to readyVinicius Costa Gomes2011-06-201-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | We should not try to do any other type of configuration for LE links when they become ready. Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * | Bluetooth: Fix locking in blacklist codeGustavo F. Padovan2011-06-171-13/+25
| | | | | | | | | | | | | | | | | | There was no unlock call on the errors path Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * | Bluetooth: Use bit operations on conn_stateGustavo F. Padovan2011-06-162-99/+88Star
| | | | | | | | | | | | | | | | | | | | | Instead of setting bits manually we use set_bit, test_bit, etc. Also remove L2CAP_ prefix from macros. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * | Bluetooth: use bit operation on conf_stateGustavo F. Padovan2011-06-163-53/+48Star
| | | | | | | | | | | | | | | | | | | | | Instead of making the bit operations manually, we now use set_bit, test_bit, etc. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
| * | Bluetooth: Add blacklisting support for mgmt interfaceAntti Julku2011-06-162-0/+80
| | | | | | | | | | | | | | | | | | | | | Management interface commands for blocking and unblocking devices. Signed-off-by: Antti Julku <antti.julku@nokia.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>