aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/iwlegacy
AgeCommit message (Collapse)AuthorFilesLines
2011-06-03iwlegacy: add missing null checkGreg Dietsche1-0/+3
lq_sta has other null checks in this function. assuming they are correct, this additional null check should be added too. Incorporating suggestion from Gustavo Padovan. Signed-off-by: Greg Dietsche <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-06-03iwlegacy: propagate error return valueGreg Dietsche1-1/+1
propogate the return value from iwl4965_get_tx_atten_grp instead of implicitly returning -EINVAL in the error case. Signed-off-by: Greg Dietsche <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-06-03iwlegacy: return -EINVAL instead of -1Greg Dietsche1-1/+1
Cleanup the code to return -EINVAL instead of -1 Signed-off-by: Greg Dietsche <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-06-03iwlegacy: remove unecessary if statementGreg Dietsche1-2/+0
the code always returns ret regardless, so if(ret) check is unecessary. Signed-off-by: Greg Dietsche <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-06-03iwlegacy: remove unreachable codeGreg Dietsche1-1/+0
return; at the end of the function is unecessary. Signed-off-by: Greg Dietsche <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-06-01iwl4965: correctly validate temperature valueStanislaw Gruszka1-1/+1
In some cases we can read wrong temperature value. If after that temperature value will not be updated to good one, we badly configure tx power parameters and device is unable to send a data. Resolves: https://bugzilla.kernel.org/show_bug.cgi?id=35932 Cc: [email protected] # 2.6.39+ Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-05-27Merge ↵John W. Linville1-2/+2
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
2011-05-27iwl4965: fix 5GHz operationStanislaw Gruszka1-2/+2
rx_status.band is used uninitialized, what disallow to work on 5GHz . Cc: [email protected] # 2.6.39+ Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-05-23Merge branch 'for-linus' of ↵Linus Torvalds1-2/+2
git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (39 commits) b43: fix comment typo reqest -> request Haavard Skinnemoen has left Atmel cris: typo in mach-fs Makefile Kconfig: fix copy/paste-ism for dell-wmi-aio driver doc: timers-howto: fix a typo ("unsgined") perf: Only include annotate.h once in tools/perf/util/ui/browsers/annotate.c md, raid5: Fix spelling error in comment ('Ofcourse' --> 'Of course'). treewide: fix a few typos in comments regulator: change debug statement be consistent with the style of the rest Revert "arm: mach-u300/gpio: Fix mem_region resource size miscalculations" audit: acquire creds selectively to reduce atomic op overhead rtlwifi: don't touch with treewide double semicolon removal treewide: cleanup continuations and remove logging message whitespace ath9k_hw: don't touch with treewide double semicolon removal include/linux/leds-regulator.h: fix syntax in example code tty: fix typo in descripton of tty_termios_encode_baud_rate xtensa: remove obsolete BKL kernel option from defconfig m68k: fix comment typo 'occcured' arch:Kconfig.locks Remove unused config option. treewide: remove extra semicolons ...
2011-05-17Merge branch 'master' of ↵David S. Miller2-0/+13
master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 Conflicts: drivers/net/vmxnet3/vmxnet3_ethtool.c net/core/dev.c
2011-05-16Merge branch 'master' of ↵John W. Linville1-1/+1
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem Conflicts: drivers/net/wireless/iwlwifi/iwl-agn-tx.c net/mac80211/sta_info.h
2011-05-16iwlegacy: Silence DEBUG_STRICT_USER_COPY_CHECKS=y warningStephen Boyd1-1/+1
Enabling DEBUG_STRICT_USER_COPY_CHECKS causes the following warning: In file included from arch/x86/include/asm/uaccess.h:573, from include/net/checksum.h:25, from include/linux/skbuff.h:28, from drivers/net/wireless/iwlegacy/iwl-4965-rs.c:28: In function 'copy_from_user', inlined from 'iwl4965_rs_sta_dbgfs_scale_table_write' at drivers/net/wireless/iwlegacy/iwl-4965-rs.c:2616: arch/x86/include/asm/uaccess_64.h:65: warning: call to 'copy_from_user_overflow' declared with attribute warning: copy_from_user() buffer size is not provably correct presumably due to buf_size being signed causing GCC to fail to see that buf_size can't become negative. Cc: Johannes Berg <[email protected]> Signed-off-by: Stephen Boyd <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-05-11Merge branch 'master' of ↵David S. Miller2-0/+13
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2011-05-10iwlegacy: fix IBSS mode crashesStanislaw Gruszka2-0/+13
We should not switch to non-IBSS channels when working in IBSS mode, otherwise there are microcode errors, and after some time system crashes. This bug is only observable when software scan is used in IBSS mode, so should be considered as regression after: commit 0263aa45293838b514b8af674a03faf040991a90 Author: Stanislaw Gruszka <[email protected]> Date: Tue Mar 29 11:24:21 2011 +0200 iwl3945: disable hw scan by default However IBSS mode check, which this patch add again, was removed by commit b2f30e8bdd8ef5f3b5a7ef9146509585a15347d3 Author: Johannes Berg <[email protected]> Date: Thu Jan 21 07:32:20 2010 -0800 iwlwifi: remove IBSS channel sanity check That commit claim that mac80211 will not use non-IBSS channel in IBSS mode, what definitely is not true. Bug probably should be fixed in mac80211, but that will require more work, so better to apply that patch temporally, and provide proper mac80211 fix latter. Resolves: https://bugzilla.kernel.org/show_bug.cgi?id=34452 Reported-and-tested-by: Mikko Rapeli <[email protected]> Cc: [email protected] # 2.6.38.5+ Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-05-05Merge branch 'master' of ↵David S. Miller3-11/+35
master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 Conflicts: drivers/net/tg3.c
2011-05-05Merge branch 'master' of ↵John W. Linville9-75/+82
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem Conflicts: drivers/net/wireless/libertas/if_cs.c drivers/net/wireless/rtlwifi/pci.c net/bluetooth/l2cap_sock.c
2011-05-02Merge branch 'master' of ↵David S. Miller3-11/+35
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2011-04-29iwlegacy: remove sync_cmd_mutexStanislaw Gruszka4-5/+2
We now use priv->mutex to serialize sync command, remove old priv->sync_cmd_mutex and add assertion that priv->mutex must be locked. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: more priv->mutex serializationStanislaw Gruszka3-23/+34
Check status bits with mutex taken, because when we wait for mutex unlock, status can change. Patch should also make remaining sync commands be send with priv->mutex taken. That will prevent execute these commands when we are currently reset firmware, what could possibly cause troubles. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: fix enqueue hcmd race conditionsStanislaw Gruszka2-28/+25
We mark command as huge by using meta->flags from other (non huge) command, but flags can be possibly overridden, when non huge command is enqueued, what can lead to: WARNING: at lib/dma-debug.c:696 dma_debug_device_change+0x1a3/0x1f0() DMA-API: device driver has pending DMA allocations while released from device [count=1] To fix introduce additional CMD_MAPPED to mark command as mapped and serialize iwl_enqueue_hcmd() with iwl_tx_cmd_complete() using hcmd_lock. Serialization will also fix possible race conditions, because q->read_ptr, q->write_ptr are modified/used in parallel. Do not change callback, I did (and fixed) that mistake in iwlagn. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: comment typo fix diable -> disableStanislaw Gruszka2-2/+2
Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: remove scan_tx_antennasStanislaw Gruszka2-4/+0
Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: remove unneeded __packedStanislaw Gruszka1-1/+1
struct iwl_queue is not part of firmware interface, so __packed is not needed. Remove it since is may affect performance. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: remove unneeded disable_hw_scan checkStanislaw Gruszka1-3/+2
We never set STATUS_SCANNING in softwre scanning mode, disable_hw_scan check is unneeded. Correct debug message while at it. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: simplify init geosStanislaw Gruszka1-4/+1
Don't need to use conditional as ch->band is already assigned to IEEE80211_BAND_5GHZ or IEEE80211_BAND_2GHZ Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: enable only rfkill interrupt when device is downStanislaw Gruszka2-4/+14
Add two below iwlwifi commits to iwlegacy: commit 554d1d027b19265c4aa3f718b3126d2b86e09a08 Author: Stanislaw Gruszka <[email protected]> Date: Thu Dec 23 12:38:21 2010 +0100 iwlagn: enable only rfkill interrupt when device is down commit 3dd823e6b86407aed1a025041d8f1df77e43a9c8 Author: Don Fry <[email protected]> Date: Sun Feb 6 09:29:45 2011 -0800 iwlagn: Re-enable RF_KILL interrupt when down Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwlegacy: remove duplicate initialization in iwl4956_down()Stanislaw Gruszka1-1/+1
Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-29iwl4965: fix "Received BA when not expected"Stanislaw Gruszka1-6/+12
Need to use broadcast sta_id for management frames, otherwise we broke BA session in the firmware and get messages like that: "Received BA when not expected" or (on older kernels): "BA scd_flow 0 does not match txq_id 10" This fix regression introduced in 2.6.35 during station management code rewrite by: commit 2a87c26bbe9587baeb9e56d3ce0b4971bd777643 Author: Johannes Berg <[email protected]> Date: Fri Apr 30 11:30:45 2010 -0700 iwlwifi: use iwl_find_station less Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-28iwl4965: fix "TX Power requested while scanning"Stanislaw Gruszka1-4/+4
Fix the following: WARNING: at drivers/net/wireless/iwlegacy/iwl-4965.c:1128 \ iwl4965_send_tx_power+0x61/0x102 [iwl4965]() Hardware name: [...] TX Power requested while scanning! Pid: 5723, comm: kworker/u:28 Not tainted 2.6.39-0.rc4.4.fc14.x86_64 #1 Call Trace: [<ffffffff8104e27b>] warn_slowpath_common+0x85/0x9d [<ffffffffa02782e0>] ? iwl4965_show_temperature+0x49/0x49 [iwl4965] [<ffffffff8104e336>] warn_slowpath_fmt+0x46/0x48 [<ffffffffa027712f>] iwl4965_send_tx_power+0x61/0x102 [iwl4965] [<ffffffff81477e05>] ? mutex_lock+0x36/0x50 [<ffffffffa0278337>] iwl4965_bg_txpower_work+0x57/0x73 [iwl4965] [<ffffffff810647f3>] process_one_work+0x18d/0x286 [<ffffffff81065a5e>] worker_thread+0xfd/0x181 [<ffffffff81065961>] ? manage_workers.clone.16+0x172/0x172 [<ffffffff81069036>] kthread+0x82/0x8a [<ffffffff81480524>] kernel_thread_helper+0x4/0x10 [<ffffffff81068fb4>] ? kthread_worker_fn+0x14b/0x14b [<ffffffff81480520>] ? gs_change+0x13/0x13 Reported-and-tested-by: Paul Bolle <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-28iwlegacy: led stay solid on when no trafficWey-Yi Guy1-1/+19
commit 5ed540aecc2aae92d5c97b9a9306a5bf88ad5574 change the led behavior for iwlwifi driver; the side effect cause led blink all the time. Modify the led blink table to fix this problem Signed-off-by: Wey-Yi Guy <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-26Merge branch 'master' of ↵John W. Linville8-35/+23
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2011-04-26Merge branch 'master' of ↵David S. Miller1-3/+7
master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 Resolved logic conflicts causing a build failure due to drivers/net/r8169.c changes using a patch from Stephen Rothwell. Signed-off-by: David S. Miller <[email protected]>
2011-04-26treewide: cleanup continuations and remove logging message whitespaceJoe Perches1-2/+2
Using C line continuation inside format strings is error prone. Clean up the unintended whitespace introduced by misuse of \. Neaten correctly used line continations as well for consistency. drivers/scsi/arcmsr/arcmsr_hba.c has these errors as well, but arcmsr needs a lot more work and the driver should likely be moved to staging instead. Signed-off-by: Joe Perches <[email protected]> Acked-by: Randy Dunlap <[email protected]> Signed-off-by: Jiri Kosina <[email protected]>
2011-04-25Merge branch 'master' of ↵John W. Linville2-2/+1
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem Conflicts: drivers/net/wireless/iwlwifi/iwl-core.c drivers/net/wireless/rt2x00/rt2x00queue.c drivers/net/wireless/rt2x00/rt2x00queue.h
2011-04-22Merge branch 'master' of ↵David S. Miller1-3/+7
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2011-04-20iwl4965: fix skb usage after freeStanislaw Gruszka1-3/+7
Since commit a120e912eb51e347f36c71b60a1d13af74d30e83 Author: Stanislaw Gruszka <[email protected]> Date: Fri Feb 19 15:47:33 2010 -0800 iwlwifi: sanity check before counting number of tfds can be free we use skb->data after calling ieee80211_tx_status_irqsafe(), which could free skb instantly. On current kernels I do not observe practical problems related with bug, but on 2.6.35.y it cause random system hangs when stressing wireless link, making bisection of other problems impossible. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-19iwlegacy: use pci_dev->revisionSergei Shtylyov1-1/+1
Commit be663ab67077fac8e23eb8e231a8c1c94cb32e54 (iwlwifi: split the drivers for agn and legacy devices 3945/4965) added code to read the 4965's revision ID from the PCI configuration register while it's already stored by PCI subsystem in the 'revision' field of 'struct pci_dev'... Signed-off-by: Sergei Shtylyov <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-14Merge branch 'master' of ↵David S. Miller6-28/+11
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2011-04-13iwlegacy: fix tx_power initializationStanislaw Gruszka6-28/+11
priv->tx_power_next is not initialized to max supported power, but instead default value is used, what cause errors like [ 58.597834] iwl3945 0000:03:00.0: Requested user TXPOWER 15 above upper limit 14. [ 58.597839] iwl3945 0000:03:00.0: Error setting Tx power (-22). if maximum tx power read from the eeprom is smaller than default. In consequence card is unable to initialize properly. Fix the problem and cleanup tx power initialization. Reported-and-tested-by: Robin Dong <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-12iwl4965: drop a lone pr_err()Paul Bolle1-1/+0
iwl4965_rate_control_register() prints a message at KERN_ERR level. It looks like it's just a debugging message, so pr_err() seems to be overdone. But none of the similar functions in drivers/net/wireless print a message, so let's just drop it. Signed-off-by: Paul Bolle <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-04-11Merge branch 'master' of ↵David S. Miller1-4/+5
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2011-04-11iwlegacy: make iwl3945 and iwl4965 select IWLWIFI_LEGACYJohn W. Linville1-4/+5
Otherwise, IWLWIFI_LEGACY has to be selected independently before the drivers are made available. Reported-by: Dave Airlie <[email protected]> Signed-off-by: John W. Linville <[email protected]> Cc: Stanislaw Gruszka <[email protected]> Cc: Wey-Yi Guy <[email protected]>
2011-04-07Merge branch 'for-linus2' of git://git.profusion.mobi/users/lucas/linux-2.6Linus Torvalds4-4/+4
* 'for-linus2' of git://git.profusion.mobi/users/lucas/linux-2.6: Fix common misspellings
2011-03-31Fix common misspellingsLucas De Marchi4-4/+4
Fixes generated by 'codespell' and manually reviewed. Signed-off-by: Lucas De Marchi <[email protected]>
2011-03-29iwlegacy: fix bugs in change_interfaceJohannes Berg1-0/+10
If change_interface gets invoked during a firmware restart, it may crash; prevent that from happening by checking if ctx->vif is assigned. Additionally, in my initial commit I forgot to set the vif->p2p variable correctly, so fix that too. Cc: [email protected] [2.6.38+] Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-03-29iwl3945: disable hw scan by defaultStanislaw Gruszka1-1/+2
After new NetworkManager 0.8.996 changes, hardware scanning is causing microcode errors as reported here: https://bugzilla.redhat.com/show_bug.cgi?id=683571 and sometimes kernel crashes: https://bugzilla.redhat.com/show_bug.cgi?id=688252 Also with hw scan there are very bad performance on some systems as reported here: https://bugzilla.redhat.com/show_bug.cgi?id=671366 Since Intel no longer supports 3945, there is no chance to get proper firmware fixes, we need workaround problems by disable hardware scanning by default. Signed-off-by: Stanislaw Gruszka <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-03-29iwl3945: do not deprecate software scanStanislaw Gruszka1-4/+2
Software scanning can be used for workaround some performance problems, so do not deprecate it. Signed-off-by: Stanislaw Gruszka <[email protected]> Acked-by: Wey-Yi Guy <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-03-04Merge branch 'master' of ↵John W. Linville56-0/+42420
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
2011-02-28iwlegacy: fix dma mappings and skbs leakStanislaw Gruszka3-27/+62
Fix possible dma mappings and skbs introduced by commit 470058e0ad82fcfaaffd57307d8bf8c094e8e9d7 "iwlwifi: avoid Tx queue memory allocation in interface down". Signed-off-by: Stanislaw Gruszka <[email protected]> Acked-by: Wey-Yi Guy <[email protected]> Signed-off-by: John W. Linville <[email protected]>
2011-02-28iwlwifi: remove duplicate initializationDan Carpenter1-1/+1
rate_mask is initialized again later so this can be removed. Btw, if rate_control_send_low(sta, priv_sta, txrc) returns false, that means that "sta" is non-NULL. That's why the second initialization of rate_mask is a little simpler than the first. Signed-off-by: Dan Carpenter <[email protected]> Acked-by: Wey-Yi Guy <[email protected]> Signed-off-by: John W. Linville <[email protected]>