summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* libertas: clean up RSSI commandDan Williams2010-07-278-77/+51
| | | | | | | | | Convert to a full direct command; previous code rolled a direct command by hand but left the original indirect command code intact but disabled. Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* libertas: clean up MONITOR_MODE commandDan Williams2010-07-274-72/+33
| | | | | | | | | Convert to a full direct command; previous code rolled a direct command by handle but left the original indirect command code lying around. Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* rt2500usb: disallow to set WEP key with non zero indexStanislaw Gruszka2010-07-271-0/+8
| | | | | | | | | | | | | | | | | | | | | On our hardware (050d:7050 Belkin Components F5D7050 Wireless G Adapter), setting any WEP key with non zero index, cause rx frames corruption. Note: perhaps (I did not check) this can be fixed differently - by using hw_key_idx the same as true MAC key index. But according to the comment in rt2x00mac_set_key(): "the hardware requires keys to be assigned in correct order (When key 1 is provided but key 0 is not, then the key is not found by the hardware during RX)" this will be quite problematic. Since WEP should not be used, disabling hardware crypto offload for it will not hurt much. Beside static one key WEP will still be offloaded. Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* rt2500usb: truly disable encryption when initializeStanislaw Gruszka2010-07-271-0/+1
| | | | | | | | | | | Without cipher part nullify of TXRX_CSR0 register we can receive corrupted frames (removed IV or IVC), after reloading rt2500usb module with nohwcrypt=1 option, if previous some keys were configured into the hardware. Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* rt2500usb: write keys to proper registersStanislaw Gruszka2010-07-271-1/+1
| | | | | | | | | | Fix rt2500usb hardware encryption broken by commit 96b61bafe22b2f2abcc833d651739edb977f1b1e "rt2x00: Clean up USB vendor request buffer functions" Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: remove unused base_index from rate table.Senthil Balasubramanian2010-07-272-161/+160
| | | | | | | base index is not used anymore and so remove it. Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: Fix incorrect user ratekbs of MCS15 ShortGISenthil Balasubramanian2010-07-271-1/+1
| | | | | | | | | | | | | | The user ratekbs of MCS15 ShortGI is incorrect and can not be lesser than MCS15 rate. This incorrect rate may affect switching to higher rates as the rate control algorithm always finds MCS15 is better than MCS15 ShortGI and results in lower throughput. Fix this by feeding the correct user ratekbs for MCS15 ShortGI rate. This issue affects 3 stream case very badly as the 3 stream rates are not used at all once we scale down to MCS15 from 3 stream rates. Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: Add three stream rate control support for AR938X.Senthil Balasubramanian2010-07-272-225/+366
| | | | | | | | This patch adds 3 stream rate control support for AR938X family chipsets which supports 3 streams. Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* ath9k: Introduce bit masks for valid and valid_single_stream.Senthil Balasubramanian2010-07-272-145/+153
| | | | | | | | replace valid and valid_single_stream in rate table with bit masks and reorganize the code so adding 3x3 rate control would be easier. Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* mac80211: Fix key freeing to handle unlinked keysJouni Malinen2010-07-274-12/+12
| | | | | | | | | | | | | | | | | | | Key locking simplification removed key->sdata != NULL verification from ieee80211_key_free(). While that is fine for most use cases, there is one path where this function can be called with an unlinked key (i.e., key->sdata == NULL && key->local == NULL). This results in a NULL pointer dereference with the current implementation. This is known to happen at least with FT protocol when wpa_supplicant tries to configure the key before association. Avoid the issue by passing in the local pointer to ieee80211_key_free(). In addition, do not clear the key from hw_accel or debugfs if it has not yet been added. At least the hw_accel one could trigger another NULL pointer dereference. Signed-off-by: Jouni Malinen <j@w1.fi> Reviewed-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
* p54: Added get_survey callback in order to get channel noiseJohn W. Linville2010-07-271-0/+17
| | | | Signed-off-by: John W. Linville <linville@tuxdriver.com>
* Merge branch 'master' of ↵John W. Linville2010-07-274739-139657/+325184
|\ | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/holtmann/bluetooth-next-2.6 Conflicts: drivers/net/wireless/iwlwifi/iwl-commands.h
| * Bluetooth: Support for Atheros AR300x serial chipSuraj Sumangala2010-07-215-1/+261
| | | | | | | | | | | | | | | | | | | | Implements Atheros AR300x serial HCI protocol. This protocol extends H4 serial protocol to implement enhanced power management features supported by Atheros AR300x serial Bluetooth chipsets. Signed-off-by: Suraj Sumangala <suraj@atheros.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Use __packed annotation for driversGustavo F. Padovan2010-07-214-5/+5
| | | | | | | | | | | | | | Use the __packed annotation instead of the __attribute__((packed)). Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Use __packed annotationGustavo F. Padovan2010-07-214-113/+113
| | | | | | | | | | | | | | | | | | To make net/ and include/net/ code consistent use __packed instead of __attribute__ ((packed)). Bluetooth subsystem was one of the last net subsys still using __attribute__ ((packed)). Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Enable L2CAP Extended features by defaultGustavo F. Padovan2010-07-211-9/+9
| | | | | | | | | | | | | | | | Change the enable_ertm param to disable_ertm and default value to 0. That means that L2CAP Extended features are enabled by default now. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix typo in hci_event.cGustavo F. Padovan2010-07-211-2/+2
| | | | | | | | | | | | | | memmory -> memory Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Move bit-field variable in USB driver to data->flagsGustavo F. Padovan2010-07-211-6/+4
| | | | | | | | | | | | | | | | did_iso_resume keeps only a bit-field value, so moving that to a proper flags place. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Add Google's copyright to L2CAPGustavo F. Padovan2010-07-212-0/+2
| | | | | | | | | | Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Implemented HCI frame reassembly for RX from streamSuraj Sumangala2010-07-212-0/+36
| | | | | | | | | | | | | | | | Implemented frame reassembly implementation for reassembling fragments received from stream. Signed-off-by: Suraj Sumangala <suraj@atheros.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Modified hci_recv_fragment() to use hci_reassembly helperSuraj Sumangala2010-07-211-74/+11
| | | | | | | | | | | | | | | | Modified packet based reassembly function hci_recv_fragment() to use hci_reassembly() Signed-off-by: Suraj Sumangala <suraj@atheros.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Implement hci_reassembly helper to reassemble RX packetsSuraj Sumangala2010-07-212-0/+110
| | | | | | | | | | | | | | Implements feature to reassemble received HCI frames from any input stream Signed-off-by: Suraj Sumangala <suraj@atheros.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Add one more buffer for HCI stream reassemblySuraj Sumangala2010-07-212-5/+5
| | | | | | | | | | | | | | Additional reassembly buffer to keep track of stream reasembly Signed-off-by: Suraj Sumangala <suraj@atheros.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Added support for controller shipped with iMac i5Cyril Lacoux2010-07-211-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device class is ff(vend.) instead of e0(wlcon). Output from command `usb-devices`: T: Bus=01 Lev=03 Prnt=03 Port=00 Cnt=01 Dev#= 6 Spd=12 MxCh= 0 D: Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs= 1 P: Vendor=05ac ProdID=8215 Rev=01.82 S: Manufacturer=Apple Inc. S: Product=Bluetooth USB Host Controller S: SerialNumber=7C6D62936607 C: #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr=0mA I: If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb I: If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb I: If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none) I: If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=00 Driver=(none) Signed-off-by: Cyril Lacoux <clacoux@ifeelgood.org> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Update L2CAP version informationGustavo F. Padovan2010-07-211-1/+1
| | | | | | | | | | | | | | | | We did some changes on the L2CAP configuration process and its behaviour is bit different now. That justifies a updated on the L2CAP version. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Add Copyright notice to L2CAPGustavo F. Padovan2010-07-212-0/+2
| | | | | | | | | | | | | | | | Copyright for the time I worked on L2CAP during the Google Summer of Code program. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Remove unnecessary casts of private_data in driversJoe Perches2010-07-211-1/+1
| | | | | | | | | | Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Add HCIUARTSETFLAGS and HCIUARTGETFLAGS ioctlsJohan Hedberg2010-07-213-1/+20
| | | | | | | | | | | | | | | | | | | | | | This patch introduces two new ioctls: HCIUARTSETFLAGS and HCIUARTGETFLAGS. The only flag available for now is HCI_UART_RAW_DEVICE which allows to initialize a UART device into RAW mode from userspace. This is particularly useful for experimenting with Bluetooth controllers that don't yet have proper support in BlueZ. Signed-off-by: Johan Hedberg <johan.hedberg@nokia.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Keep code under column 80Gustavo F. Padovan2010-07-211-21/+25
| | | | | | | | | | | | | | Purely a cosmetic change, it doesn't change the code flow. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix bug in kzalloc allocation sizeGustavo F. Padovan2010-07-211-1/+1
| | | | | | | | | | | | | | Probably a typo error. We were using the wrong struct to get size. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Add missing HCIUARTGETDEVICE ioctl to compat_ioctl.cJohan Hedberg2010-07-211-2/+3
| | | | | | | | | | Signed-off-by: Johan Hedberg <johan.hedberg@nokia.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Send ConfigReq after send a ConnectionRspGustavo F. Padovan2010-07-211-3/+41
| | | | | | | | | | | | | | | | | | The extended L2CAP features requires that one should initiate a ConfigReq after send the ConnectionRsp. This patch changes the behaviour of the configuration process of our stack. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix error return on L2CAP-HCI interface.João Paulo Rechi Vita2010-07-211-3/+3
| | | | | | | | | | | | | | | | L2CAP only deals with ACL links. EINVAL should be returned otherwise. Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix error value for wrong FCS.João Paulo Rechi Vita2010-07-211-1/+1
| | | | | | | | | | | | Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix error return for l2cap_connect_rsp().João Paulo Rechi Vita2010-07-211-2/+2
| | | | | | | | | | | | Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix error return value on sendmsg.João Paulo Rechi Vita2010-07-211-1/+1
| | | | | | | | | | | | | | | | When the socket is in a bad state EBADFD is more appropriate then EINVAL. Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix error return value on sendmsg.João Paulo Rechi Vita2010-07-211-1/+1
| | | | | | | | | | | | | | | | | | When we try to send a message bigger than the outgoing MTU value EMSGSIZE (message too long) should be returned. Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Make l2cap_streaming_send() void.João Paulo Rechi Vita2010-07-211-3/+2
| | | | | | | | | | | | | | | | | | It doesn't make sense to have a return value since we always set it to 0. Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Fix l2cap_sock_connect error return.João Paulo Rechi Vita2010-07-211-0/+1
| | | | | | | | | | | | | | | | Return a proper error value if socket is already connected. Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Improve ERTM local busy handlingGustavo F. Padovan2010-07-211-36/+47
| | | | | | | | | | | | | | | | | | Now we also check if can push skb userspace just after receive a new skb instead of only wait the l2cap_busy_work wake up from time to time to check the local busy condition. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Add backlog queue to ERTM codeGustavo F. Padovan2010-07-211-53/+79
| | | | | | | | | | | | | | | | | | backlog queue is the canonical mechanism to avoid race conditions due interrupts in bottom half context. After the socket lock is released the net core take care of push all skb in its backlog queue. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Remove the send_lock spinlock from ERTMGustavo F. Padovan2010-07-212-28/+1
| | | | | | | | | | | | | | | | | | Using a lock to deal with the ERTM race condition - interruption with new data from the hci layer - is wrong. We should use the native skb backlog queue. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Don't accept ConfigReq if we aren't in the BT_CONFIG stateGustavo F. Padovan2010-07-211-1/+7
| | | | | | | | | | | | | | | | If such event happens we shall reply with a Command Reject, because we are not expecting any configure request. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Disconnect early if mode is not supportedGustavo F. Padovan2010-07-212-16/+45
| | | | | | | | | | | | | | | | When mode is mandatory we shall not send connect request and report this to the userspace as well. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Remove check for supported modeGustavo F. Padovan2010-07-211-7/+2
| | | | | | | | | | | | | | | | Since now we have checks for the supported mode before on l2cap_info_rsp we can remove the check for it here. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Refuse ConfigRsp with different modeGustavo F. Padovan2010-07-211-1/+5
| | | | | | | | | | | | | | | | If our mode is Basic Mode we have to refuse any ConfigRsp that proposes a different mode. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Actively send request for Basic ModeGustavo F. Padovan2010-07-211-6/+11
| | | | | | | | | | | | | | | | The Profile Tuning Suite requires that we send a RFC containing the Basic Mode configuration when requesting Basic Mode. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Prefer Basic Mode on receipt of ConfigReqGustavo F. Padovan2010-07-211-3/+0
| | | | | | | | | | | | | | | | If we choose to use Basic Mode then we have to refuse the received mode and propose Basic Mode again. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Disconnect the channel if we don't want the proposed modeGustavo F. Padovan2010-07-211-1/+2
| | | | | | | | | | | | | | | | If the device is a STATE 2 then it should disconnect the channel if the remote device propose a mode different from its mandatory mode. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
| * Bluetooth: Change the way we set ERTM mode as mandatoryGustavo F. Padovan2010-07-211-4/+18
| | | | | | | | | | | | | | | | | | | | | | If the socket type is SOCK_STREAM we set Enhanced Retransmisson Mode or Streaming Mode as mandatory. That means that we will close the channel if the other side doesn't support or request the the mandatory mode. Basic mode can't be set as mandatory. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi> Reviewed-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
OpenPOWER on IntegriCloud