If not using delay then no need to update next_tx after
each packet sent. This allows pktgen to send faster especially
on systems with slower clock sources.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Do some reorganization of transmit logic path:
* move transmit queue full idle to separate routine
* add a cpu_relax()
* eliminate some of the uneeded goto's
* if queue is still stopped, go back to main thread loop.
* don't give up transmitting if quantum is exhausted (be greedy)
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ron Mercer [Thu, 27 Aug 2009 11:02:11 +0000 (11:02 +0000)]
qlge: Move TX completions from workqueue to NAPI.
TX completions were running in a workqueue queued by the ISR. This
patch moves the processing of TX completions to an existing RSS NAPI
context.
Now each irq vector runs NAPI for one RSS ring and one or more TX
completion rings.
Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ron Mercer [Thu, 27 Aug 2009 11:02:10 +0000 (11:02 +0000)]
qlge: Allow running MSIx with fewer vectors.
Currently we downshift to MSI/Legacy if we don't get enough vectors for
cpu_count RSS rings plus cpu_count TX completion rings. This patch
allows running MSIX with the vector count that the platform provides.
Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ron Mercer [Thu, 27 Aug 2009 11:02:09 +0000 (11:02 +0000)]
qlge: Get rid of 'default' rx_ring type.
Currently we have three types of RX rings.
1) Default ring - services rx_ring for broadcast/multicast, handles
firmware events, and errors.
2) TX completion ring - handles only outbound completions.
3) RSS ring - handles only inbound completions.
This patch gets rid of the default ring type and moves it's functionality
into the first RSS ring. This makes better use of MSIX vectors since
they are a limited resource on some platforms.
Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Petri Gynther [Fri, 28 Aug 2009 12:05:15 +0000 (12:05 +0000)]
bonding: Have bond_check_dev_link examine netif_running
bonding: Have bond_check_dev_link examine netif_running
Some network devices do not call netif_carrier_off when they
are set administratively down. Have the bonding link check function
also inspect the netif_running state. Ignore netif_running if the
bond_check_dev_link function is called with "reporting" set, as in that
case it's inspecting the capabilities of the non-netif_carrier device
driver.
Signed-off-by: Petri Gynther <pgynther@google.com> Signed-off-by: Jay Vosburgh <fubar@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
max_bonds is of type int and cannot be greater than INT_MAX.
Signed-off-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr> Signed-off-by: Jay Vosburgh <fubar@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bonding can use compare_ether_addr() in bond_release.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: Jay Vosburgh <fubar@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Kiran Divekar [Fri, 28 Aug 2009 12:17:59 +0000 (17:47 +0530)]
libertas: add NULL check on return value of get_zeroed_page
Most of the places in debugfs.c are missing a NULL check on the return value of
get_zeroed_page API call. Added required NULL check at appropriate places.
Signed-off-by: Kiran Divekar <kirandivekar@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Fri, 28 Aug 2009 10:28:14 +0000 (13:28 +0300)]
rndis_wlan: rename wireless stats worker to device poller
Stats worker no longer poll stats from device anymore. It's still
needed to poll device control channel for connect/disconnect events,
so rename stats worker as device poller.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Fri, 28 Aug 2009 09:59:26 +0000 (12:59 +0300)]
rndis_wlan: enable infrastructure before setting random essid
Random essid must be set to turn on radio when not connected. If device is
in ad-hoc mode, this results 'media connect' indications with the random
essid which should be ignored.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Fri, 28 Aug 2009 09:59:05 +0000 (12:59 +0300)]
rndis_wlan: increase scan timer delay
Increase scan delay from 1 sec to 6 sec. Spec says that scan by
OID_802_11_BSSID_LIST_SCAN completes in 6 seconds.
Before rfkill patch too short delay was not problem as device was
always active (radio on) and performing background scanning.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Fri, 28 Aug 2009 09:59:00 +0000 (12:59 +0300)]
rndis_wlan: resize bssid list if too small
Buffer used for bssid list might be too small. Change rndis_query_oid()
to return required buffer length to caller and make rndis_check_bssid_list()
resize buffer when needed.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Fri, 28 Aug 2009 09:58:49 +0000 (12:58 +0300)]
rndis_wlan: ignore OID_802_11_ADD_KEY triggered media connect indications
Setting WPA keys with OID_802_11_ADD_KEY sometimes trigger
instant media connect indication. These indications are extranous and
should be ignored, as otherwise driver would send reassociation event to
userspace which in this case is not needed.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gábor Stefanik [Thu, 27 Aug 2009 20:49:49 +0000 (22:49 +0200)]
b43: Implement antenna diversity support for LP-PHY
The A/G-PHY changes are fallout fixes from the enum change,
which in turn allows the LP-PHY code to be much simpler.
The antenna_to_phyctl change is a fix for a potential
existing bug that this patch may otherwise trigger.
Signed-off-by: Gábor Stefanik <netrolller.3d@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gábor Stefanik [Thu, 27 Aug 2009 15:24:23 +0000 (17:24 +0200)]
b43: Enable LP-PHY support by default and remove Kconfig warning
The most common LP-PHY device, BCM4312, is now fully functional.
So, no need to say "probably won't work for you" anymore.
It's also not "for debuggers and developers only", as it is
perfectly usable for end-users now (at least for BCM4312).
Signed-off-by: Gábor Stefanik <netrolller.3d@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
without having to specify the driver data as well.
Signed-off-by: Pavel Roskin <proski@gnu.org> Acked-by: Bob Copeland <me@bobcopeland.com> Acked-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Pavel Roskin [Thu, 27 Aug 2009 02:30:00 +0000 (22:30 -0400)]
ath5k: fix uninitialized value use in ath5k_eeprom_read_turbo_modes()
The `val' variable in ath5k_eeprom_read_turbo_modes() is used
uninitialized. gcc 4.4.1 with -fno-inline-functions-called-once reports
it:
eeprom.c: In function 'ath5k_eeprom_read_turbo_modes':
eeprom.c:441: warning: 'val' may be used uninitialized in this function
Comparing the code to the Atheros HAL, it's clear that the split between
ath5k_eeprom_read_modes() and ath5k_eeprom_read_turbo_modes() was
incorrect.
The Atheros HAL reads both turbo and non-turbo data from EEPROM in one
function. Some turbo mode parameters are derived from the same EEPROM
values as non-turbo parameters, just from different bits.
Merge ath5k_eeprom_read_turbo_modes() into ath5k_eeprom_read_modes() to
fix the warning. The actual values and offsets have been cross-checked
against Atheros HAL.
Signed-off-by: Pavel Roskin <proski@gnu.org> Acked-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bob Copeland [Thu, 27 Aug 2009 19:17:15 +0000 (15:17 -0400)]
ath5k: clarify srev comparison for CCMP check
As Pavel Roskin noted, the check for mac version as copied from
legacy_hal made no sense. This replaces it with the equivalent
and makes up a suitable #define for the mac version legacy_hal
checked.
Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Wed, 26 Aug 2009 20:15:13 +0000 (22:15 +0200)]
iwlwifi: fix ICT irq table endianness
The ICT IRQ table is a set of __le32 values, not u32 values,
so when reading it we need to take into account that it has
to be converted to CPU endianness. This was causing a lot of
trouble on my powerpc box where various things would simply
not work for no apparent reason with 5xxx cards, but worked
with 4965 -- which doesn't use the ICT table.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ivo van Doorn [Wed, 26 Aug 2009 19:04:08 +0000 (21:04 +0200)]
rt2x00: Cleanup rt2x00mac_bss_info_changed()
Since patch "rt2x00: bss_info_changed() callback is allowed to sleep" the
variable delayed wasn't used anymore. This means it can be removed
along with the call to schedule_work which depended on that variable.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gábor Stefanik [Wed, 26 Aug 2009 18:51:25 +0000 (20:51 +0200)]
b43: Fix and update LP-PHY code
-Fix a few nasty typos (b43_phy_* operations instead of b43_radio_*)
in the channel tune routines.
-Fix some typos & spec errors found by MMIO tracing.
-Optimize b43_phy_write & b43_phy_mask/set/maskset to use
only the minimal number of MMIO accesses. (Write is possible
using a single 32-bit MMIO write, while set/mask/maskset can
be done in 3 16-bit MMIOs).
-Set the default channel back to 1, as the bug forcing us to use
channel 7 is now fixed.
With this, the device comes up, scans, associates, transmits,
receives, monitors and injects on all channels - in other words,
it's fully functional. Sensitivity and TX power are still sub-optimal,
due to the lack of calibration (that's next on my list).
Signed-off-by: Gábor Stefanik <netrolller.3d@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gábor Stefanik [Wed, 26 Aug 2009 18:51:24 +0000 (20:51 +0200)]
b43: LP-PHY: Fix and simplify Qdiv roundup
The Qdiv roundup routine is essentially a fixed-point
division algorithm, using only integer math.
However, the version in the specs had a major error
that has been recently fixed (a missing quotient++).
Replace Qdiv roundup with a rewritten, simplified version.
Signed-off-by: Gábor Stefanik <netrolller.3d@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This change implements rfkill support for RTL8187B and RTL8187L devices,
using new cfg80211 rfkill API.
Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Tested-by: Hin-Tak Leung <htl10@users.sourceforge.net> Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br> Signed-off-by: John W. Linville <linville@tuxdriver.com>
The problem here is that rtl8187_stop, while helding priv->conf_mutex,
runs cancel_delayed_work_sync on an workqueue that runs rtl8187_work,
which also takes priv->conf_mutex lock. Move cancel_delayed_work_sync
out of rtl8187_stop priv->conf_mutex locking region.
Reported-by: Larry Finger <Larry.Finger@lwfinger.net> Tested-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br> Signed-off-by: John W. Linville <linville@tuxdriver.com>
ath9k: Split ath9k_hw_btcoex_enable() into two logical pieces
This function currently does initialization + enable the
btcoex support. Split it into two logical functions which
does the above operations separately. Btcoex initialization
is done during attach time and enabling this feature is done
in start(). Also, add code to disable btcoex support in stop().
Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Wed, 26 Aug 2009 12:53:02 +0000 (15:53 +0300)]
rndis_wlan: set cipher suites for cfg80211
rndis_wlan does not set cipher suites list for cfg80211 which causes
wext-compat-range to report rndis_wlan not supporting WPA. Patch adds
cipher suites list and fixes NetworkManager not being able to connect to
WPA encrypted APs.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jouni Malinen [Tue, 25 Aug 2009 14:44:28 +0000 (17:44 +0300)]
mac80211: Check pending scan request after having processed mgd work
When the queued management work items are processed in
ieee80211_sta_work() an item could be removed. This could change the
anybusy from true to false, so we better check whether we can start a
new scan only after having processed the pending work first.
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>
Johannes Berg [Tue, 25 Aug 2009 14:33:47 +0000 (16:33 +0200)]
mac80211: fix scan cancel on ifdown
When an interface is taken down while a scan is
pending -- i.e. a scan request was accepted but
not yet acted upon due to other work being in
progress -- we currently do not properly cancel
that scan and end up getting stuck. Fix this by
doing better checks when an interface is taken
down.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Gábor Stefanik [Tue, 25 Aug 2009 14:17:48 +0000 (16:17 +0200)]
b43: LP-PHY: Fix a few typos in the RC calibration code
The RC calibration code has some typos - fix them.
Also, make the default channel 7, as channel 1 is still
broken (only channels 7 and 8, and occasionally 9 work).
Signed-off-by: Gábor Stefanik <netrolller.3d@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
CC [M] drivers/net/wireless/prism54/islpci_eth.o
drivers/net/wireless/prism54/islpci_eth.c: In function ‘islpci_eth_cleanup_transmit’:
drivers/net/wireless/prism54/islpci_eth.c:53: warning: cast from pointer to integer of different size
drivers/net/wireless/prism54/islpci_eth.c: In function ‘islpci_eth_receive’:
drivers/net/wireless/prism54/islpci_eth.c:453: warning: cast from pointer to integer of different size
Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Marcos Chaparro [Tue, 25 Aug 2009 03:00:31 +0000 (23:00 -0400)]
ath5k: add led pin configuration for compaq c700 laptop
With this patch, a compaq c700 can turn on the wifi led.
The array of compatible devices now includes the hardware
present in this computer, as well as the led pin and
polarity.
Signed-off-by: Marcos Chaparro <nitrousnrg@gmail.com> Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bob Copeland [Tue, 25 Aug 2009 03:00:30 +0000 (23:00 -0400)]
ath5k: clean up filter flags setting
The maze of if() statements in configure_filter is confusing.
Reorganizing it as a switch statement makes it more apparent what
is going on and reveals several suspicious settings. This has no
functional changes, though it does remove some redundant flags
that are set earlier.
Also now that we can sleep, protect sc->filter_flags with the
sc lock.
Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Arnd Hannemann [Mon, 24 Aug 2009 18:51:46 +0000 (20:51 +0200)]
mac80211: Fix output of minstrels rc_stats
An integer overflow in the minstrel debug code prevented the
throughput to be displayed correctly. This patch fixes that,
by permutating operations like proposed by Pavel Roskin.
Signed-off-by: Arnd Hannemann <hannemann@nets.rwth-aachen.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Joerg Albert [Fri, 21 Aug 2009 21:25:07 +0000 (23:25 +0200)]
ar9170: cleanup of bss_info_changed and beacon config
Add beacon control by BSS_CHANGED_BEACON_ENABLED and
bss_conf->enable_beacon from mac80211.
Signed-off-by: Joerg Albert <jal2@gmx.de> Signed-off-by: Christian Lamparter <chunkeey@web.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Reinette Chatre [Fri, 21 Aug 2009 21:03:51 +0000 (14:03 -0700)]
MAINTAINERS: Update ipw2x00 and iwlwifi entries
Update MAINTAINERS file to reflect current maintenance status of ipw2x00
drivers. We remove James's name as he is not involved with this project
anymore. We also update the Status to "Odd Fixes". This has been true for a
while now, we have to make it official. There is also a new email address
with which all relevant people can be reached. The same email address
should be used for iwlwifi.
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Cc: James Ketrenos <jketreno@linux.intel.com> Acked-by: James Ketrenos <jketreno@linux.intel.com> Acked-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Reinette Chatre [Fri, 21 Aug 2009 20:34:26 +0000 (13:34 -0700)]
ipw2x00: update contact information
Intel Linux wireless folks can be reached via this address.
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Acked-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:25 +0000 (13:34 -0700)]
iwlwifi: fix unloading driver while scanning
If NetworkManager is busy scanning when user
tries to unload the module, the driver can not be unloaded
because HW still scanning.
Make sure driver sends abort scan host command to uCode if it
is in the middle of scanning during driver unload.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Abhijeet Kolekar [Fri, 21 Aug 2009 20:34:24 +0000 (13:34 -0700)]
iwlwifi: fix remove key error
Fix following error by sending synchronous command and waiting for the command
to complete.
mac80211-phy0: failed to remove key (0, ff:ff:ff:ff:ff:ff) from hardware (-16).
-16 is EBUSY error. The asynchronous command tests for STATUS_EXIT_PENDING
while interface is getting down and it returns -EBUSY error if set.
Changing the host command from asynchronous call to synchronous call
enables command to be run while interface is going down.
Signed-off-by: Abhijeet Kolekar <abhijeet.kolekar@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:23 +0000 (13:34 -0700)]
iwlwifi: read enhanced tx power info from EEPROM image
For 6000 series and up, additional enhanced regulatory tx power
limitation information is added to EEPROM image.
In order to setup the tx power limitation per channel correctly. Read
the enhanced tx power information from EEPROM image and update
accordingly.
The information is provided per SISO (a,b,c) chain based, it also has
information for both MIMO2 and MIMO3. For tx power regulatory
limitation, take the highest number from all the chains and update.
Also update tx_power_user_lmt to the highest power supported by any
channels and chains
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:22 +0000 (13:34 -0700)]
iwlwifi: remove duplicated define
Remove duplicated define "STA_FLG_PWR_SAVE_MSK"
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
iwlwifi: set HT flags in ieee80211_rx_status for received packets
Add code to set the HT flags (HT, 40 MHz, Short guard interval) in
the ieee80211_rx_status field passed to mac80211. This ensures that mac80211
processes these HT packets correctly.
Signed-off-by: Daniel C Halperin <daniel.c.halperin@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
iwlwifi: clear rate control flags on non-HT packet
Clear the flags (most importantly, the IEEE80211_TX_RC_MCS flag)
when sending a non-HT packet so that the rate index can be properly treated.
This fixes the reporting of legacy rates in wireless-extensions for packets
sent after an HT packet.
Signed-off-by: Daniel C Halperin <daniel.c.halperin@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:19 +0000 (13:34 -0700)]
iwlwifi: show current tx power
debugFs file show current tx power for all the transmit chains
Adding "tx_power" file in /sys/kernal/debug/ieee80211/phy0/iwlagn/debug
to display current tx power for all the active chains in 1/2 dB step.
Show tx power information "Not available" if uCode can not provide the
information or interface is down.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:18 +0000 (13:34 -0700)]
iwlwifi: change IWL6000_UCODE_API_MAX to v4
uCode version changed to v4 for 6000 series
The additional parameter added to v4 is providing current tx power for
each chain in tx statistics portion of "statistics notification"
command.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:17 +0000 (13:34 -0700)]
iwlwifi: error checking for setting tx_power in sysfs
Perform error checking and report failure when setting tx power from
sysfs.
If fail to set the tx power, do not update the local copy, so user will
not see the incorrect tx power in sysfs
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:16 +0000 (13:34 -0700)]
iwlwifi: name changes from "tx_power_channel_lmt" to "tx_power_device_lmt"
Changing the name from "tx_power_channel_lmt" to "tx_power_device_lmt";
to give idea that scope of limit is for overall device, not any
individual channels
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:15 +0000 (13:34 -0700)]
iwlwifi: do not allow set tx power over channel power limit
When setting tx power in sysfs, check against max channel tx power
limit instead of IWL_TX_POWER_TARGET_POWER_MAX.
Different devices have different max tx power limit; using
IWL_TX_POWER_TARGET_POWER_MAX can excess the limitaion and give wrong
information.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 21 Aug 2009 20:34:14 +0000 (13:34 -0700)]
iwlwifi: set default tx power user limit to minimal
Set the tx_power_user_lmt to the lowest power level
this value will get overwritten by channel's max power avg
from eeprom
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>