Eric Dumazet [Thu, 5 Nov 2009 10:06:40 +0000 (11:06 +0100)]
mac80211: Speedup ieee80211_remove_interfaces()
Speedup ieee80211_remove_interfaces() by factorizing synchronize_rcu() calls
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Reviewed-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ben Hutchings [Mon, 23 Nov 2009 16:07:30 +0000 (16:07 +0000)]
sfc: Combine high-level header files
All files that include ethtool.h, rx.h or tx.h are also including
efx.h, and there is no good reason to separate out the few
declarations they contain. Therefore fold them into efx.h.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Mon, 23 Nov 2009 16:04:23 +0000 (16:04 +0000)]
sfc: Rename efx_board::init_leds to init_phy and use for SFN4111T
efx_board::init_leds was introduced as a second stage of
initialisation because of the inter-dependency between the board and
PHY. We want to move board initialisation into NIC probing, which is
too early to use MDIO, so SFN4111T initialisation also needs to be
split.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings [Mon, 23 Nov 2009 16:03:45 +0000 (16:03 +0000)]
sfc: Use a single blink implementation
Only some PHYs have firmware support for a LED blink mode, so we
currently blink the others in a timer function. Since all PHYs have
simple on and off modes, we don't gain anything by using multiple
blink implementations. Also, since we have a process context there
is no need to use a timer.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Michael Buesch [Mon, 23 Nov 2009 19:58:06 +0000 (20:58 +0100)]
ssb: Fix range check in sprom write
The range check in the sprom image parser hex2sprom() is broken.
One sprom word is 4 hex characters.
This fixes the check and also adds much better sanity checks to the code.
We better make sure the image is OK by doing some sanity checks to avoid
bricking the device by accident.
Signed-off-by: Michael Buesch <mb@bu3sch.de> Cc: stable@kernel.org Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Sun, 22 Nov 2009 18:16:47 +0000 (20:16 +0200)]
rndis_wlan: disable stall workaround
Stall workaround doesn't work with bcm4320a devices like with bcm4320b.
This workaround actually causes more stalls/device freeze on bcm4320a.
Therefore disable stall workaround by default.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jussi Kivilinna [Sun, 22 Nov 2009 18:16:42 +0000 (20:16 +0200)]
rndis_wlan: fix buffer overflow in rndis_query_oid
rndis_query_oid overwrites *len which stores buffer size to return full size
of received command and then uses *len with memcpy to fill buffer with
command.
Ofcourse memcpy should be done before replacing buffer size.
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Warning(net/mac80211/sta_info.h:322): No description found for parameter 'drv_unblock_wk'
Warning(net/mac80211/sta_info.h:322): No description found for parameter 'drv_unblock_wk'
Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com> Cc: Johannes Berg <johannes@sipsolutions.net> Cc: John W. Linville <linville@tuxdriver.com> Cc: Randy Dunlap <randy.dunlap@oracle.com> Cc: David Miller <davem@davemloft.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 20 Nov 2009 20:05:09 +0000 (12:05 -0800)]
iwlwifi: remove reset led_tpt from iwl_leds_init()
Current blinking rate is calculated based on the difference between
current tx/rx byte counts and priv->led_tpt.
priv->led_tpt should not get reset in iwl_leds_init(), this function can be
called by bring interface "up" or "down", or when uCode sysassert occurred.
resetting the led_tpt parameter will introduce incorrect led blinking behavior.
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, 20 Nov 2009 20:05:08 +0000 (12:05 -0800)]
iwlwifi: change message for cmd queue full error
Change error message for command queue full
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Acked-by: Ben Cahill <ben.m.cahill@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 20 Nov 2009 20:05:07 +0000 (12:05 -0800)]
iwlwifi: print limited number of event log when uCode error
To help iwlagn uCode debugging, event log will dump to syslog when driver
detect uCode error occurred, but this only happen when compile with
CONFIG_IWLWIFI_DEBUG and debug flag is enabled; which is not always
the case. Also, there is another problem, if the flag is set, the entire
event log buffer will be dump to syslog, it can flood the syslog and
make it very difficult to debug the problem.
Change the default to only dump last 20 entries of event log to syslog
unless the following condition meets:
1. both compile with CONFIG_IWLWIFI_DEBUG and debug flag
is enabled, and then dump the entire event buffer to syslog.
2. dump event log request from debugfs
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Acked-by: Ben Cahill <ben.m.cahill@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jay Sternberg [Fri, 20 Nov 2009 20:05:06 +0000 (12:05 -0800)]
iwlwifi: Tell the ucode immediately when association state changes
When we get a state change of associated or not, we need to tell the
ucode via the RX_ON command using the filter flags. This will prevent
the ucode from sending any packets when not associated, specifically not
sending NULL QOS packets after a deauthentication which causes the AP to
repeatedly send deauth's in some situations.
Signed-off-by: Jay Sternberg <jay.e.sternberg@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 20 Nov 2009 20:05:05 +0000 (12:05 -0800)]
iwlwifi: dump error log when uCode error occurred
uCode error log contain information as to what the error was and where
it occurred necessary to debug any uCode issues.
Always log the information without special debug flag, this can help to
capture the important information when error happened.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com> Acked-by: Ben Cahill <ben.m.cahill@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 20 Nov 2009 20:05:04 +0000 (12:05 -0800)]
iwlwifi: by default, dump entire sram data portion
For "sram" debugfs file, if user did not specify the offset and length,
dump the entire data portion of sram by default.
Data portion is 0x800000 - 0x80ffff, but the actual data size is known
to the driver from the ucode file.
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, 20 Nov 2009 20:05:03 +0000 (12:05 -0800)]
iwlwifi: update supported PCI_ID list for 5xx0 series
Update the PCI_ID list for 5xx0 series.
Remove all the PCI_IDs which never made into production or not longer in
production.
Also make sure the supported bands(a/b/g/n) match specified PCI_IDs
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>
Johannes Berg [Fri, 20 Nov 2009 20:05:02 +0000 (12:05 -0800)]
iwlwifi: separate IO tracing
Since IO tracing is usually not needed and
generates a lot of data, separate it into
its own trace system so that we can always
enable iwlwifi:* and not have to worry about
getting too much data. If IO tracing is then
really needed we can enable iwlwifi_io:* in
addition and get that data.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Wey-Yi Guy [Fri, 20 Nov 2009 20:05:01 +0000 (12:05 -0800)]
iwlwifi: fix reserved2 field in iwl4965_addsta
reserved2 field in "struct iwl4965_addsta_cmd" is __le16.
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, 20 Nov 2009 20:05:00 +0000 (12:05 -0800)]
iwlwifi: dynamically allocate buffer for sram debugfs file
Dynamically allocate memory for dumping SRAM based on the length of memory
to be displayed.
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, 20 Nov 2009 20:04:59 +0000 (12:04 -0800)]
iwlwifi: increase tx_queue debugfs buffer size
For tx_queue, need to increase the buffer size allocated for it,
so all the queues information can be displayed
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, 20 Nov 2009 20:04:58 +0000 (12:04 -0800)]
iwlwifi: set read/write permission for debugfs files
Set the correct Read/Write file permission for iwlwifi debugfs files
based on the functionality of the files
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, 20 Nov 2009 20:04:56 +0000 (12:04 -0800)]
iwlwifi: reset led_tpt when clear tx/rx traffic byte counts
LED blink rate is based on the traffic load, when tx/rx traffic counts
got reset, we also need to reset the led_tpt to prevent incorrect
blink rate being calculated.
Merge both clear_tx_statistics() and clear_rx_statistics() into
single clear_traffic_statistics() function, when reset the traffic byte
counts, both tx and rx need to be reset at the same time, to make
sure calculated the correct led blink rate.
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, 20 Nov 2009 20:04:55 +0000 (12:04 -0800)]
iwlwifi: set sm_ps_mode as part of cfg parameters
Setting "Spatial multiplexing Power Save" as part of
per device configuration parameter.
Report to uCode based on priv->conf setting, so driver can
have more control of how different devices should operate
in power save mode.
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>
Ben Cahill [Fri, 20 Nov 2009 20:04:53 +0000 (12:04 -0800)]
iwlagn: Use iwl_write8() for CSR_INT_COALESCING register
CSR_INT_COALESCING previously had only one, but now has two single-byte fields.
With only one single-byte field (lowest order byte) it was okay to write via
iwl_write32(), but now with two, an iwl_write32() to the lower order field
clobbers the other field (odd-address CSR_INT_PERIODIC_REG, offset 0x5), and an
iwl_write32() to CSR_INT_PERIODIC_REG could clobber the lowest byte of the
next-higher register (CSR_INT, offset 0x8).
Fortunately, no bad side effects have been produced by the iwl_write32()
usage, due to order of execution (low order byte was always written before
higher order byte), and the fact that writing "0" to the low byte of the
next higher register has no effect (only action is when writing "1"s).
Nonetheless, this cleans up the accesses so no bad side effects might occur
in the future, if execution order changes, or more bit fields get added to
CSR_INT_COALESCING.
Add some comments regarding periodic interrupt usage.
Signed-off-by: Ben Cahill <ben.m.cahill@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Ben Cahill [Fri, 20 Nov 2009 20:04:52 +0000 (12:04 -0800)]
iwlwifi: Add iwl_write8()
To support byte writes to CSR_INT_COALESCING and CSR_INT_PERIODIC registers,
add iwl_write8(), including debug/trace support.
Signed-off-by: Ben Cahill <ben.m.cahill@intel.com> Signed-off-by: Reinette Chatre <reinette.chatre@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Lukáš Turek [Thu, 19 Nov 2009 22:02:02 +0000 (23:02 +0100)]
ath5k: Fix I/Q calibration
The sign of correction coefficients was lost in the calculations, which
caused high packetloss in 802.11a mode after the results were applied.
Fixed by removing unneccesary and broken AND with a bit mask.
Signed-off-by: Lukas Turek <8an@praha12.net> Acked-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Michael Buesch [Thu, 19 Nov 2009 21:24:29 +0000 (22:24 +0100)]
b43: Rewrite DMA Tx status handling sanity checks
This rewrites the error handling policies in the TX status handler.
It tries to be error-tolerant as in "try hard to not crash the machine".
It won't recover from errors (that are bugs in the firmware or driver),
because that's impossible. However, it will return a more or less useful
error message and bail out. It also tries hard to use rate-limited messages
to not flood the syslog in case of a failure.
Signed-off-by: Michael Buesch <mb@bu3sch.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
ath9k: This patch fix RX unpadding for any received frame.
It has been tested with a 802.11 frame generator and by checking the FCS field
of each received frame with the value reported by the Atheros hardware. This
patch is useful if you are trying to analyze non standard 802.11 frame going
over the air.
Signed-off-by: Benoit PAPILLAULT <benoit.papillault@free.fr> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Larry Finger [Thu, 19 Nov 2009 20:40:46 +0000 (14:40 -0600)]
ssb: Unconditionally log results of core scans
At present, the results of an SSB core scan are only logged when
CONFIG_SSB_DEBUG is "y". As this may not be set in a distro kernel,
it is difficult interpret many problems posted in bug reports or in
help forums.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Matthew Garrett [Wed, 11 Nov 2009 19:36:31 +0000 (14:36 -0500)]
ipw2200: Set core hw rfkill status when hardware changes state
ipw2200 is able to detect when it's been hard-killed, but doesn't update
the core rfkill state or update userspace. Ensure that the state is updated,
allowing the rfkill core to notify userspace.
Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Matthew Garrett [Wed, 11 Nov 2009 19:36:30 +0000 (14:36 -0500)]
ipw2100: Register the wiphy device
libipw unconditionally calls wiphy_unregister, but it's up to the driver
to register it in the first place. ipw2100 fails to do so. Add the necessary
glue code, and also ensure that rfkill statuses get set up appropriately.
(Augmented for proper wiphy_unregister placement. -- JWL)
Signed-off-by: Matthew Garrett <mjg@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
John W. Linville [Tue, 25 Aug 2009 18:12:25 +0000 (14:12 -0400)]
libipw: initiate cfg80211 API conversion (v2)
Initiate the conversion of libipw to the new cfg80211 configuration API.
For now, leave CONFIG_IPW2200_PROMISCUOUS stuff alone. Eventually
migrate it to cfg80211 when the add/del/change_virtual_intf methods
are implemented.
(v2: Fix unconditional wiphy_unregister in libipw which was causing
problems for ipw2100, somewhat based on prior attempted fix
by Zhu Yi <yi.zhu@intel.com>. Previously both original version of
this patch and Zhu Yi's fix attempt were reverted due to
discovery of regressions. -- JWL)
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Alexander Duyck [Mon, 23 Nov 2009 06:32:57 +0000 (06:32 +0000)]
ixgbe: Only set/clear VFE in ixgbe_set_rx_mode
There appears to be a stray setting of the VFE bit when registering vlans.
This should not be done as vlan filtering should be enabled any time the
interface is not in promiscous mode
Signed-off-by: Mallikarjuna R Chilakala <mallikarjuna.chilakala@intel.com> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
ixgbe: Use rx buffer length from rx ring for configuring rscctl
While configuring rscctl use rx buffer length from rx ring structure
instead of passing rx_buf_len to ixgbe_configure_rscctl
Signed-off-by: Mallikarjuna R Chilakala <mallikarjuna.chilakala@intel.com> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Divide 82599 HWRSC counters into aggregated and flushed to count number of
packets getting coalesced per TCP connection.
Signed-off-by: Mallikarjuna R Chilakala <mallikarjuna.chilakala@intel.com> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Sathya Perla [Sun, 22 Nov 2009 22:02:45 +0000 (22:02 +0000)]
be2net: remove BUG_ON() when be2net runs out of mccq wrbs
The driver can run out of mccq wrbs when completions don't arrive
due to an unresponsive card. This must not hit a BUG_ON(); instead
log a msg and return an error.
Signed-off-by: Sathya Perla <sathyap@serverengines.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Sathya Perla [Sun, 22 Nov 2009 22:01:10 +0000 (22:01 +0000)]
be2net: support configuration of 64 multicast addresses instead of 32
To send upto 64 addresses in the multicast-set cmd, the non-embeeded cmd format
that provides for a bigger buffer is used instead of an embedded format.
Signed-off-by: Sathya Perla <sathyap@serverengines.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Joe Perches [Mon, 23 Nov 2009 18:41:23 +0000 (10:41 -0800)]
net/ipv4: Move && and || to end of previous line
On Sun, 2009-11-22 at 16:31 -0800, David Miller wrote:
> It should be of the form:
> if (x &&
> y)
>
> or:
> if (x && y)
>
> Fix patches, rather than complaints, for existing cases where things
> do not follow this pattern are certainly welcome.
Also collapsed some multiple tabs to single space.
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:28:56 +0000 (23:28 +0000)]
e1000e: update Tx Unit hang detection message
The Tx unit hang detection code in e1000e detects other hangs caused by
hardware components (e.g. Rx, DMA units), but it is not possible to detect
exactly which component is hung so it has always assumed a Tx unit hang.
When dumping a message to the system log because of a hang, this patch adds
more data to help narrow the cause of the issue and makes the message
non-Tx-specific. Because this new code reads PHY registers which can
sleep, move it off to a workqueue. This and all previously existing work
tasks in the driver are now cancelled when the driver is removed.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:28:37 +0000 (23:28 +0000)]
e1000e: cosmetic - group local variables of the same type
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:28:17 +0000 (23:28 +0000)]
e1000e: remove redundant might_sleep()
Now that mutex_lock() calls might_sleep() the driver doesn't have to here.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:27:59 +0000 (23:27 +0000)]
e1000e: do not error out on identification LED init failure
A failure to initialize the identification LED is not a fatal condition and
should allow the init path to continue.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:27:40 +0000 (23:27 +0000)]
e1000e: set pm_qos DMA latency requirement per interface when needed
It was pointed out a pm_qos DMA latency requirement set when the driver is
loaded when parts that support early receive of jumbo frames are probed
could have that requirement overidden if another part supported by the
driver (one that does not support early receive of jumbo frames) is probed
later. Change the DMA latency requirement to be per-interface if needed
instead of per driver.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:27:21 +0000 (23:27 +0000)]
e1000e: cleanup functions that clear hardware statistics
The e1000_clear_hw_cntrs_*() functions read the registers to clear them.
There is no reason to save the register contents so the temp variable can
be removed.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:27:03 +0000 (23:27 +0000)]
e1000e: cleanup - shift indentation left by exiting early in e1000_tso
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:26:44 +0000 (23:26 +0000)]
e1000e: set bools to true/false instead of 1/0
Set booleans to 'true' or 'false' to make it clear it is a boolean. Also
change instances of TRUE/FALSE in comments to lowercase true/false.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:26:24 +0000 (23:26 +0000)]
e1000e: provide comment for 82571 workaround
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:26:05 +0000 (23:26 +0000)]
e1000e: remove comments regarding a non-existent api module
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:25:45 +0000 (23:25 +0000)]
e1000e: update copyright information
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:25:26 +0000 (23:25 +0000)]
e1000e: cleanup ops function pointers
The phy and nvm operations structures have function pointers that contain
"phy" and "nvm" in the pointer names which are redundant since the
structures are already obviously in phy and nvm structures.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:25:07 +0000 (23:25 +0000)]
e1000e: consolidate two dbug macros into one simpler one
This patch depends on a previous one that cleans up redundant #includes.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:24:48 +0000 (23:24 +0000)]
e1000e: cleanup redundant #include's
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:24:30 +0000 (23:24 +0000)]
e1000e: Incorrect MII Link beat reporting.
The driver was only updating MII stats when an LSC up was detected and
the interface had not already been reported up to netdev. This meant
MII stats returned in response to an SIOCGMIIREG ioctl would always
show a link up if it had ever been up. This was misleading the networking
daemon guessnet, which uses this ioctl, into making improper network port
selections.
This fix adds a call to e1000_phy_read_status() to actively read the
mii stats before responding to the SIOCGMIIREG ioctl.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:24:11 +0000 (23:24 +0000)]
e1000e: disable K1 on PCH LOM when in PHY loopback mode
When performing the ethtool PHY loopback test on PCH-based LOMs (82577 and
82578), disable K1 (a MAC-PHY interconnect low power mode) otherwise
packets might get corrupted.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:23:53 +0000 (23:23 +0000)]
e1000e: improper return code signage
The e1000_get_cable_length_82577() should return a negative value upon
error.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:23:34 +0000 (23:23 +0000)]
e1000e: link reporting problems
Copper links with WoL or management enabled (any condition which prevents
the phy from being powered down when the interface is taken down) were
always reporting link-up when the interface had been taken down. This
is because when the interface is taken down (ifconfig ethx down),
interrupts are disabled. With no interrupts, there is no LSC interrupt,
which is normally required to set "get_link_status", which instructs the
driver to query the device for link state. The fix is to force
get_link_status to true if the interface is not up.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:23:16 +0000 (23:23 +0000)]
e1000e: don't clean Rx ring while resetting
When using legacy interrupts, do not clean the Rx ring while resetting
otherwise traffic will not pass.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:22:57 +0000 (23:22 +0000)]
e1000e: function pointers for ethtool set/get offloads
Provide missing function pointers for ethtool set/get offloads.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:22:39 +0000 (23:22 +0000)]
e1000e: clearing interrupt timers causes descriptors to get flushed
Clearing the interrupt timers following an IMS clear has the unwanted
side-effect of flushing all descriptors immediately following a partial
write when interrupts are disabled.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:22:20 +0000 (23:22 +0000)]
e1000e: add missing tests for 82583 in ethtool functions
Add tests for 82583 in a couple ethtool functions that were missed from the
initial hardware enablement submission.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Bruce Allan [Fri, 20 Nov 2009 23:22:01 +0000 (23:22 +0000)]
e1000e: check WoL mode is among set of supported modes
When setting WoL feature, check the supplied modes are all supported rather
than checking for no support. This way, if any new modes are added the
driver does not default to not complaining about it if we don't really
support it.
Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Alexander Duyck [Thu, 19 Nov 2009 12:42:21 +0000 (12:42 +0000)]
igb: Add full support for 82580 devices
This patch makes use of the 82580 PHY and MAC support added and adds a set
of supported device IDs for said hardware.
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Alexander Duyck [Thu, 19 Nov 2009 12:42:01 +0000 (12:42 +0000)]
igb: add support for 82580 MAC
This patch adds support for the 82580 MAC.
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Alexander Duyck [Thu, 19 Nov 2009 12:41:42 +0000 (12:41 +0000)]
igb: add support for the 82580 phy
This patch adds support for the phy included in the 82580 silicon family.
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Johannes Berg [Thu, 19 Nov 2009 11:45:42 +0000 (12:45 +0100)]
mac80211: avoid spurious deauth frames/messages
With WEXT, it happens frequently that the SME
requests an authentication but then deauthenticates
right away because some new parameters came along.
Every time this happens we print a deauth message
and send a deauth frame, but both of that is rather
confusing. Avoid it by aborting the authentication
process silently, and telling cfg80211 about that.
The patch looks larger than it really is:
__cfg80211_auth_remove() is split out from
cfg80211_send_auth_timeout(), there's no new code
except __cfg80211_auth_canceled() (a one-liner) and
the mac80211 bits (7 new lines of code).
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Thu, 19 Nov 2009 00:08:30 +0000 (01:08 +0100)]
mac80211: request TX status where needed
Right now all frames mac80211 hands to the driver
have the IEEE80211_TX_CTL_REQ_TX_STATUS flag set to
request TX status. This isn't really necessary, only
the injected frames need TX status (the latter for
hostapd) so move setting this flag.
The rate control algorithms also need TX status, but
they don't require it.
Also, rt2x00 uses that bit for its own purposes and
seems to require it being set for all frames, but
that can be fixed in rt2x00.
This doesn't really change anything for any drivers
but in the future drivers using hw-rate control may
opt to not report TX status for frames that don't
have the IEEE80211_TX_CTL_REQ_TX_STATUS flag set.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> [rt2x00 bits] Signed-off-by: John W. Linville <linville@tuxdriver.com>
A number of people have tried to add a wireless interface
(in managed mode) to a bridge and then complained that it
doesn't work. It cannot work, however, because in 802.11
networks all packets need to be acknowledged and as such
need to be sent to the right address. Promiscuous doesn't
help here. The wireless address format used for these
links has only space for three addresses, the
* transmitter, which must be equal to the sender (origin)
* receiver (on the wireless medium), which is the AP in
the case of managed mode
* the recipient (destination), which is on the APs local
network segment
In an IBSS, it is similar, but the receiver and recipient
must match and the third address is used as the BSSID.
To avoid such mistakes in the future, disallow adding a
wireless interface to a bridge.
Felix has recently added a four-address mode to the AP
and client side that can be used (after negotiating that
it is possible, which must happen out-of-band by setting
up both sides) for bridging, so allow that case.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>