]> git.karo-electronics.de Git - linux-beck.git/log
linux-beck.git
14 years agosfc: Refactor link configuration
Ben Hutchings [Sun, 29 Nov 2009 03:42:41 +0000 (03:42 +0000)]
sfc: Refactor link configuration

Refactor PHY, MAC and NIC configuration operations so that the
existing link configuration can be re-pushed with:

efx->phy_op->reconfigure(efx);
efx->mac_op->reconfigure(efx);

and a new configuration with:

efx->nic_op->reconfigure_port(efx);

(plus locking and error-checking).

We have not held the link settings in software (aside from flow
control), and have relied on asking the hardware what they are.  This
is a problem because in some cases the hardware may no longer be in a
state to tell us.  In particular, if an entire multi-port board is
reset through one port, the driver bindings to other ports have no
chance to save settings before recovering.

We only actually need to keep track of the autonegotiation settings,
so add an ethtool advertising mask to struct efx_nic, initialise it
in PHY init and update it as necessary.

Remove now-unneeded uses of efx_phy_op::{get,set}_settings() and
struct ethtool_cmd.

Much of this was done by Steve Hodgson <shodgson@solarflare.com>.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move Falcon NIC operations to efx_nic_type
Ben Hutchings [Sun, 29 Nov 2009 03:42:31 +0000 (03:42 +0000)]
sfc: Move Falcon NIC operations to efx_nic_type

This is preparation for adding differing implementations for new NICs.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Turn pause frame generation on and off at the MAC, not the RX FIFO
Ben Hutchings [Sun, 29 Nov 2009 03:42:18 +0000 (03:42 +0000)]
sfc: Turn pause frame generation on and off at the MAC, not the RX FIFO

Pause frame generation is gated by both RX_XOFF_MAC_EN and an enable
bit in each MAC.  RX_XOFF_MAC_EN bit always reads back as 0 so we need
to set it correctly every time we modify RX_CFG_REG.  Simplify this by
always setting it to 1 and only changing the enable bits in the MACs.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove duplicate hardware structure definitions
Ben Hutchings [Sun, 29 Nov 2009 03:42:10 +0000 (03:42 +0000)]
sfc: Remove duplicate hardware structure definitions

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove redundant writes to INT_ADR_KER
Ben Hutchings [Sun, 29 Nov 2009 03:42:03 +0000 (03:42 +0000)]
sfc: Remove redundant writes to INT_ADR_KER

This register only needs to be written after reset, not each time we
enable interrupts.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agopktgen: NUMA aware
Eric Dumazet [Sun, 29 Nov 2009 08:44:33 +0000 (00:44 -0800)]
pktgen: NUMA aware

pktgen threads are bound to given CPU, we can allocate memory for
these threads in a NUMA aware way.

After a pktgen session on two threads, we can check flows memory was
allocated on right node, instead of a not related one.

# grep pktgen_thread_write /proc/vmallocinfo
0xffffc90007204000-0xffffc90007385000 1576960 pktgen_thread_write+0x3a4/0x6b0 [pktgen] pages=384 vmalloc N0=384
0xffffc90007386000-0xffffc90007507000 1576960 pktgen_thread_write+0x3a4/0x6b0 [pktgen] pages=384 vmalloc N1=384

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
David S. Miller [Sun, 29 Nov 2009 08:57:15 +0000 (00:57 -0800)]
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6

Conflicts:
drivers/ieee802154/fakehard.c
drivers/net/e1000e/ich8lan.c
drivers/net/e1000e/phy.c
drivers/net/netxen/netxen_nic_init.c
drivers/net/wireless/ath/ath9k/main.c

14 years agoixgbe: Display currently attached PHY through ethtool
PJ Waskiewicz [Wed, 25 Nov 2009 00:11:54 +0000 (00:11 +0000)]
ixgbe: Display currently attached PHY through ethtool

This patch extends the ethtool interface to display what PHY
is currently connected to a NIC.  The results can be viewed in
ethtool ethX output.

Signed-off-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>
14 years agoethtool: Add Direct Attach support to connector port reporting
PJ Waskiewicz [Wed, 25 Nov 2009 00:11:30 +0000 (00:11 +0000)]
ethtool: Add Direct Attach support to connector port reporting

This patch allows a base driver to specify Direct Attach as the
type of port through the ethtool interface.

Signed-off-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>
14 years agoixgbe: Fix Receive Address Register (RAR) cleaning and accounting
Shannon Nelson [Tue, 24 Nov 2009 18:52:10 +0000 (18:52 +0000)]
ixgbe: Fix Receive Address Register (RAR) cleaning and accounting

This fixes an issue when clearing out the RAR entries.  If RAR[0]
is the only address in use, don't clear the others.

Signed-off-by: Shannon Nelson <shannon.nelson@intel.com>
Signed-off-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>
14 years agoixgbe: LINKS2 is not a valid register for 82598
Don Skidmore [Tue, 24 Nov 2009 18:51:48 +0000 (18:51 +0000)]
ixgbe: LINKS2 is not a valid register for 82598

82598 shouldn't try and access LINKS2 while configuring
link and flow control.  This is an 82599-only register.

Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com>
Signed-off-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>
14 years agoixgbe: Disable Flow Control for certain devices
PJ Waskiewicz [Tue, 24 Nov 2009 18:51:28 +0000 (18:51 +0000)]
ixgbe: Disable Flow Control for certain devices

Flow Control autoneg should be disabled for certain adapters
that don't support autonegotiation of Flow Control at 10 gigabit.
These interfaces are the 10GBASE-T devices, CX4, and SFP+, all
running at 10 gigabit only.  1 gigabit is fine.

Signed-off-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>
14 years agoixgbe: handle parameters for tx and rx EITR, no div0
Shannon Nelson [Tue, 24 Nov 2009 18:51:06 +0000 (18:51 +0000)]
ixgbe: handle parameters for tx and rx EITR, no div0

The driver was doing a divide by zero when adjusting tx-usecs.
This patch removes the divide by zero code and changes the logic slightly
to ignore tx-usecs in the case of shared TxRx vectors.

Cc: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Shannon Nelson <shannon.nelson@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoX25: Fix oops and refcnt problems from x25_dev_get
andrew hendry [Tue, 24 Nov 2009 15:16:05 +0000 (15:16 +0000)]
X25: Fix oops and refcnt problems from x25_dev_get

Calls to x25_dev_get check for dev = NULL which was not set.
It allowed x25 to set routes and ioctls on down interfaces.
This caused oopses and refcnt problems on device_unregister.

Signed-off-by: Andrew Hendry <andrew.hendry@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoX25: Check for errors in x25_init
andrew hendry [Tue, 24 Nov 2009 15:15:42 +0000 (15:15 +0000)]
X25: Check for errors in x25_init

Adds error checking to x25_init.

Signed-off-by: Andrew Hendry <andrew.hendry@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoX25: Move SYSCTL ifdefs into header
andrew hendry [Tue, 24 Nov 2009 15:15:26 +0000 (15:15 +0000)]
X25: Move SYSCTL ifdefs into header

Moves the CONFIG_SYSCTL ifdefs in x25_init into header.

Signed-off-by: Andrew Hendry <andrew.hendry@gmail.com>
Acked-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoNET: smc91x: convert to dev_pm_ops
Kevin Hilman [Tue, 24 Nov 2009 12:57:47 +0000 (12:57 +0000)]
NET: smc91x: convert to dev_pm_ops

Convert smc91x driver from legacy PM hooks over to using dev_pm_ops.

Tested on OMAP3 platform.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Acked-by: Nicolas Pitre <nico@fluxnic.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoMerge branch 'net-next' of git://git.kernel.org/pub/scm/linux/kernel/git/vxy/lksctp-dev
David S. Miller [Sun, 29 Nov 2009 08:16:22 +0000 (00:16 -0800)]
Merge branch 'net-next' of git://git.kernel.org/pub/scm/linux/kernel/git/vxy/lksctp-dev

14 years agosctp: on T3_RTX retransmit all the in-flight chunks
Andrei Pelinescu-Onciul [Sun, 29 Nov 2009 08:14:02 +0000 (00:14 -0800)]
sctp: on T3_RTX retransmit all the in-flight chunks

When retransmitting due to T3 timeout, retransmit all the
in-flight chunks for the corresponding  transport/path, including
chunks sent less then 1 rto ago.
This is the correct behaviour according to rfc4960 section 6.3.3
E3 and
"Note: Any DATA chunks that were sent to the address for which the
 T3-rtx timer expired but did not fit in one MTU (rule E3 above)
 should be marked for retransmission and sent as soon as cwnd
 allows (normally, when a SACK arrives). ".

This fixes problems when more then one path is present and the T3
retransmission of the first chunk that timeouts stops the T3 timer
for the initial active path, leaving all the other in-flight
chunks waiting forever or until a new chunk is transmitted on the
same path and timeouts (and this will happen only if the cwnd
allows sending new chunks, but since cwnd was dropped to MTU by
the timeout => it will wait until the first heartbeat).

Example: 10 packets in flight, sent at 0.1 s intervals on the
primary path. The primary path is down and the first packet
timeouts. The first packet is retransmitted on another path, the
T3 timer for the primary path is stopped and cwnd is set to MTU.
All the other 9 in-flight packets will not be retransmitted
(unless more new packets are sent on the primary path which depend
on cwnd allowing it, and even in this case the 9 packets will be
retransmitted only after a new packet timeouts which even in the
best case would be more then RTO).

This commit reverts d0ce92910bc04e107b2f3f2048f07e94f570035d and
also removes the now unused transport->last_rto, introduced in
 b6157d8e03e1e780660a328f7183bcbfa4a93a19.

p.s  The problem is not only when multiple paths are there.  It
can happen in a single homed environment.  If the application
stops sending data, it possible to have a hung association.

Signed-off-by: Andrei Pelinescu-Onciul <andrei@iptel.org>
Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Clean up RX event handling
Ben Hutchings [Sat, 28 Nov 2009 05:36:29 +0000 (05:36 +0000)]
sfc: Clean up RX event handling

Add 'likely' hint to test of rx_checksum_enabled.
Don't count IP fragments; the IP stack can do that.
Do count non-matching multicast packets.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move descriptor cache base addresses to struct efx_nic_type
Ben Hutchings [Sat, 28 Nov 2009 05:36:12 +0000 (05:36 +0000)]
sfc: Move descriptor cache base addresses to struct efx_nic_type

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Decouple NIC revision number from Falcon PCI revision number
Ben Hutchings [Sat, 28 Nov 2009 05:36:04 +0000 (05:36 +0000)]
sfc: Decouple NIC revision number from Falcon PCI revision number

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove some redundant whitespace
Ben Hutchings [Sat, 28 Nov 2009 05:35:36 +0000 (05:35 +0000)]
sfc: Remove some redundant whitespace

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove another unused workaround macro
Ben Hutchings [Sat, 28 Nov 2009 05:35:30 +0000 (05:35 +0000)]
sfc: Remove another unused workaround macro

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove EFX_WORKAROUND_9141 macro
Matthew Slattery [Sat, 28 Nov 2009 05:35:24 +0000 (05:35 +0000)]
sfc: Remove EFX_WORKAROUND_9141 macro

The "bug9141 workaround" of setting TX_FLUSH_MIN_LEN_EN should really
be considered as a normal bit of configuration rather than a
workaround.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Limit some hardware workarounds to Falcon
Ben Hutchings [Sat, 28 Nov 2009 05:35:09 +0000 (05:35 +0000)]
sfc: Limit some hardware workarounds to Falcon

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Always start Falcon using the XMAC
Steve Hodgson [Sat, 28 Nov 2009 05:35:00 +0000 (05:35 +0000)]
sfc: Always start Falcon using the XMAC

The strap bits are only important on Falcon A and all production
boards using it have fixed-speed 10G PHYs.

Replace dummy MAC operations with default MAC operations.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Replace MDIO spinlock with mutex
Steve Hodgson [Sat, 28 Nov 2009 05:34:44 +0000 (05:34 +0000)]
sfc: Replace MDIO spinlock with mutex

We never use MDIO in atomic context, so we don't need to spin.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: QT202x: Reset before reading PHY id
Steve Hodgson [Sat, 28 Nov 2009 05:34:29 +0000 (05:34 +0000)]
sfc: QT202x: Reset before reading PHY id

Reading standard registers on the QT2025C before its firmware has
booted may cause the boot process to fail.  Therefore, follow the
recommended reset sequence before reading its id registers.  Either
order works for the QT2022C2, so don't differentiate.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Simplify PHY polling
Steve Hodgson [Sat, 28 Nov 2009 05:34:05 +0000 (05:34 +0000)]
sfc: Simplify PHY polling

Falcon can generate events for LASI interrupts from the PHY, but in
practice we have never implemented this in reference designs.  Instead
we have polled, inserted the appropriate events, and then handled the
events later.  This is a waste of time and code.

Instead, make PHY poll functions update the link state synchronously
and report whether it changed.  We can still make use of the LASI
registers as a shortcut on the SFT9001.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovlan: support "loose binding" to the underlying network device
Patrick McHardy [Wed, 25 Nov 2009 07:54:54 +0000 (07:54 +0000)]
vlan: support "loose binding" to the underlying network device

Currently the UP/DOWN state of VLANs is synchronized to the state of the
underlying device, meaning all VLANs are set down once the underlying
device is set down. This causes all routes to the VLAN devices to vanish.

Add a flag to specify a "loose binding" mode, in which only the operstate
is transfered, but the VLAN device state is independant.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Do not set net_device::trans_start in self-test
Ben Hutchings [Wed, 25 Nov 2009 16:12:31 +0000 (16:12 +0000)]
sfc: Do not set net_device::trans_start in self-test

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move inline comment into kernel-doc
Ben Hutchings [Wed, 25 Nov 2009 16:12:24 +0000 (16:12 +0000)]
sfc: Move inline comment into kernel-doc

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Change MAC promiscuity and multicast hash at the same time
Ben Hutchings [Wed, 25 Nov 2009 16:12:16 +0000 (16:12 +0000)]
sfc: Change MAC promiscuity and multicast hash at the same time

From: Steve Hodgson <shodgson@solarflare.com>

Currently we can set multicast hash immediately (in atomic context)
but must delay setting MAC promiscuity.  There is not that much
point in deferring one but not the other, and setting the multicast
hash on Siena will involve a firmware request.  So process them
both in efx_mac_work().

Also, set the broadcast bit in the multicast hash in
efx_set_multicast_list(), since this is required for both Falcon and
Siena.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Simplify XMAC link polling
Ben Hutchings [Wed, 25 Nov 2009 16:12:01 +0000 (16:12 +0000)]
sfc: Simplify XMAC link polling

From: Steve Hodgson <shodgson@solarflare.com>

Only the XMAC on Falcon needs help from the driver to poll and reset
the MAC-PHY link (XAUI); GMII is a simple parallel bus and on later
NICs firmware takes care of the XAUI link.  Also, an XMAC interrupt
currently schedules a work item which simply clears a flag
(efx_nic::mac_up) to be checked by the regular monitor (or the next
link reconfiguration, if that is sooner).

Rename the flag to xmac_poll_required, changing its sense.  Remove the
needless indirection and just set the flag immediately.  Call
falcon_xmac_poll() directly where required.

Add a new generic operation mac_op::check_fault to check the link
outside of regular monitoring, as required during self-tests.

(Note that this leaves us with an unused work item, but we will
immediately have another use for it.)

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move Falcon board/PHY/MAC monitoring code to falcon.c
Ben Hutchings [Wed, 25 Nov 2009 16:11:45 +0000 (16:11 +0000)]
sfc: Move Falcon board/PHY/MAC monitoring code to falcon.c

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Split MAC stats DMA initiation and completion
Ben Hutchings [Wed, 25 Nov 2009 16:11:35 +0000 (16:11 +0000)]
sfc: Split MAC stats DMA initiation and completion

From: Steve Hodgson <shodgson@solarflare.com>

Currently we initiate MAC stats DMA and busy-wait for completion when
stats are requested.  We can improve on this with a periodic timer to
initiate and poll for stats, and opportunistically poll when stats are
requested.

Since efx_nic::stats_disable_count and efx_stats_{disable,enable}()
are Falcon-specific, rename them and move them accordingly.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Hold MAC lock for longer in efx_init_port()
Ben Hutchings [Wed, 25 Nov 2009 16:11:19 +0000 (16:11 +0000)]
sfc: Hold MAC lock for longer in efx_init_port()

Although efx_init_port() is only called at probe time and so cannot
race with port reconfiguration, most of the functions it calls can
expect to be called with the MAC lock held.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Only switch Falcon MAC clocks as necessary
Steve Hodgson [Wed, 25 Nov 2009 16:11:03 +0000 (16:11 +0000)]
sfc: Only switch Falcon MAC clocks as necessary

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove unused function efx_flush_queues()
Ben Hutchings [Wed, 25 Nov 2009 16:10:05 +0000 (16:10 +0000)]
sfc: Remove unused function efx_flush_queues()

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Fix bugs in RX queue flushing
Ben Hutchings [Wed, 25 Nov 2009 16:09:55 +0000 (16:09 +0000)]
sfc: Fix bugs in RX queue flushing

Avoid overrunning the hardware limit of 4 concurrent RX queue flushes.
Expand the queue flush state to support this.  Make similar changes to
TX flushing to keep the code symmetric.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Clean up struct falcon_board and struct falcon_board_data
Ben Hutchings [Wed, 25 Nov 2009 16:09:41 +0000 (16:09 +0000)]
sfc: Clean up struct falcon_board and struct falcon_board_data

Put all static information in struct falcon_board_type and replace it
with a pointer in struct falcon_board.  Simplify probing aocordingly.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove unused constant
Ben Hutchings [Wed, 25 Nov 2009 16:09:13 +0000 (16:09 +0000)]
sfc: Remove unused constant

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Comment corrections
Ben Hutchings [Wed, 25 Nov 2009 16:09:04 +0000 (16:09 +0000)]
sfc: Comment corrections

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Strengthen EFX_ASSERT_RESET_SERIALISED
Ben Hutchings [Wed, 25 Nov 2009 16:08:52 +0000 (16:08 +0000)]
sfc: Strengthen EFX_ASSERT_RESET_SERIALISED

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Treat all MAC registers as 128-bit
Ben Hutchings [Wed, 25 Nov 2009 16:08:41 +0000 (16:08 +0000)]
sfc: Treat all MAC registers as 128-bit

Although all the defined fields in these registers are within 32 bits,
they are architecturally defined as 128-bit like most other Falcon
registers.  In particular, we must use efx_reado() to ensure proper
locking when reading MD_STAT_REG.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Fix descriptor cache sizes
Ben Hutchings [Wed, 25 Nov 2009 16:08:30 +0000 (16:08 +0000)]
sfc: Fix descriptor cache sizes

These were accidentally undersized by a factor of 2, which limited
performance.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agomacvlan: export macvlan mode through netlink
Arnd Bergmann [Thu, 26 Nov 2009 06:07:11 +0000 (06:07 +0000)]
macvlan: export macvlan mode through netlink

In order to support all three modes of macvlan at
runtime, extend the existing netlink protocol
to allow choosing the mode per macvlan slave
interface.

This depends on a matching patch to iproute2
in order to become accessible in user land.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agomacvlan: implement bridge, VEPA and private mode
Arnd Bergmann [Thu, 26 Nov 2009 06:07:10 +0000 (06:07 +0000)]
macvlan: implement bridge, VEPA and private mode

This allows each macvlan slave device to be in one
of three modes, depending on the use case:

MACVLAN_PRIVATE:
  The device never communicates with any other device
  on the same upper_dev. This even includes frames
  coming back from a reflective relay, where supported
  by the adjacent bridge.

MACVLAN_VEPA:
  The new Virtual Ethernet Port Aggregator (VEPA) mode,
  we assume that the adjacent bridge returns all frames
  where both source and destination are local to the
  macvlan port, i.e. the bridge is set up as a reflective
  relay.
  Broadcast frames coming in from the upper_dev get
  flooded to all macvlan interfaces in VEPA mode.
  We never deliver any frames locally.

MACVLAN_BRIDGE:
  We provide the behavior of a simple bridge between
  different macvlan interfaces on the same port. Frames
  from one interface to another one get delivered directly
  and are not sent out externally. Broadcast frames get
  flooded to all other bridge ports and to the external
  interface, but when they come back from a reflective
  relay, we don't deliver them again.
  Since we know all the MAC addresses, the macvlan bridge
  mode does not require learning or STP like the bridge
  module does.

Based on an earlier patch "macvlan: Reflect macvlan packets
meant for other macvlan devices" by Eric Biederman.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Patrick McHardy <kaber@trash.net>
Cc: Eric Biederman <ebiederm@xmission.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agomacvlan: cleanup rx statistics
Arnd Bergmann [Thu, 26 Nov 2009 06:07:09 +0000 (06:07 +0000)]
macvlan: cleanup rx statistics

We have very similar code for rx statistics in
two places in the macvlan driver, with a third
one being added in the next patch.

Consolidate them into one function to improve
overall readability of the driver.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoveth: move loopback logic to common location
Arnd Bergmann [Thu, 26 Nov 2009 06:07:08 +0000 (06:07 +0000)]
veth: move loopback logic to common location

The veth driver contains code to forward an skb
from the start_xmit function of one network
device into the receive path of another device.

Moving that code into a common location lets us
reuse the code for direct forwarding of data
between macvlan ports, and possibly in other
drivers.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Bump version
Simon Kagstrom [Wed, 25 Nov 2009 22:10:59 +0000 (22:10 +0000)]
via-velocity: Bump version

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Set tx checksum from ethtool instead of module parameter
Simon Kagstrom [Wed, 25 Nov 2009 22:10:52 +0000 (22:10 +0000)]
via-velocity: Set tx checksum from ethtool instead of module parameter

Defaults to on (as before).

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Re-enable transmit scatter-gather support
Simon Kagstrom [Wed, 25 Nov 2009 22:10:43 +0000 (22:10 +0000)]
via-velocity: Re-enable transmit scatter-gather support

The velocity hardware can handle up to 7 memory segments. This can be
turned on and off via ethtool. The support was removed in commit

  83c98a8cd04dd0f848574370594886ba3bf56750

but is re-enabled and cleaned up here. It's off by default.

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Change DMA_LENGTH_DEF (from the VIA driver)
Simon Kagstrom [Wed, 25 Nov 2009 22:10:34 +0000 (22:10 +0000)]
via-velocity: Change DMA_LENGTH_DEF (from the VIA driver)

The VIA driver has changed the default for the DMA_LENGTH_DEF parameter.
Together with adaptive interrupt supression and NAPI support, this
improves performance quite a bit

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Implement NAPI support
Simon Kagstrom [Wed, 25 Nov 2009 22:10:26 +0000 (22:10 +0000)]
via-velocity: Implement NAPI support

This patch adds NAPI support for VIA velocity. The new velocity_poll
function also pairs tx/rx handling twice which improves perforamance on
some workloads (e.g., netperf UDP_STREAM) significantly (that part is
from the VIA driver).

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Add ethtool interrupt coalescing support
Simon Kagstrom [Wed, 25 Nov 2009 22:10:12 +0000 (22:10 +0000)]
via-velocity: Add ethtool interrupt coalescing support

(Partially from the upstream VIA driver). Tweaking the number of
frames-per-interrupt and timer-until-interrupt can reduce the amount of
CPU work quite a lot.

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agovia-velocity: Correct 64-byte alignment for rx buffers
Simon Kagstrom [Wed, 25 Nov 2009 22:09:53 +0000 (22:09 +0000)]
via-velocity: Correct 64-byte alignment for rx buffers

(From the VIA driver). The current code does not guarantee 64-byte
alignment since it simply does

        int add = skb->data & 63;

        skb->data += add;

(via skb_reserve). So for example, if the skb->data address would be
0x10, this would result in 32-byte alignment (0x10 + 0x10).

Correct by adding

        64 - (skb->data & 63)

instead.

Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agor8169: move PHY regs tables to .rodata
Alexey Dobriyan [Wed, 25 Nov 2009 23:54:21 +0000 (15:54 -0800)]
r8169: move PHY regs tables to .rodata

As side effect, consume less stack.

-rtl8169_get_mac_version [vmlinux]: 432
-rtl8169_init_one [vmlinux]: 376
+rtl8169_init_one [vmlinux]: 136

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoxfrm: Add SHA384 and SHA512 HMAC authentication algorithms to XFRM
Martin Willi [Wed, 25 Nov 2009 00:58:39 +0000 (00:58 +0000)]
xfrm: Add SHA384 and SHA512 HMAC authentication algorithms to XFRM

These algorithms use a truncation of 192/256 bits, as specified
in RFC4868.

Signed-off-by: Martin Willi <martin@strongswan.org>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoxfrm: Use the user specified truncation length in ESP and AH
Martin Willi [Wed, 25 Nov 2009 00:29:53 +0000 (00:29 +0000)]
xfrm: Use the user specified truncation length in ESP and AH

Instead of using the hardcoded truncation for authentication
algorithms, use the truncation length specified on xfrm_state.

Signed-off-by: Martin Willi <martin@strongswan.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoxfrm: Store aalg in xfrm_state with a user specified truncation length
Martin Willi [Wed, 25 Nov 2009 00:29:52 +0000 (00:29 +0000)]
xfrm: Store aalg in xfrm_state with a user specified truncation length

Adding a xfrm_state requires an authentication algorithm specified
either as xfrm_algo or as xfrm_algo_auth with a specific truncation
length. For compatibility, both attributes are dumped to userspace,
and we also accept both attributes, but prefer the new syntax.

If no truncation length is specified, or the authentication algorithm
is specified using xfrm_algo, the truncation length from the algorithm
description in the kernel is used.

Signed-off-by: Martin Willi <martin@strongswan.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoxfrm: Define new XFRM netlink auth attribute with specified truncation bits
Martin Willi [Wed, 25 Nov 2009 00:29:51 +0000 (00:29 +0000)]
xfrm: Define new XFRM netlink auth attribute with specified truncation bits

The new XFRMA_ALG_AUTH_TRUNC attribute taking a xfrm_algo_auth as
argument allows the installation of authentication algorithms with
a truncation length specified in userspace, i.e. SHA256 with 128 bit
instead of 96 bit truncation.

Signed-off-by: Martin Willi <martin@strongswan.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agonet: convert /proc/net/rt_acct to seq_file
Alexey Dobriyan [Wed, 25 Nov 2009 23:40:35 +0000 (15:40 -0800)]
net: convert /proc/net/rt_acct to seq_file

Rewrite statistics accumulation to be in terms of structure fields,
not raw u32 additions. Keep them in same order, though.

This is the last user of create_proc_read_entry() in net/,
please NAK all new ones as well as all new ->write_proc, ->read_proc and
create_proc_entry() users. Cc me if there are problems. :-)

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agonet: use net_eq to compare nets
Octavian Purdila [Wed, 25 Nov 2009 23:14:13 +0000 (15:14 -0800)]
net: use net_eq to compare nets

Generated with the following semantic patch

@@
struct net *n1;
struct net *n2;
@@
- n1 == n2
+ net_eq(n1, n2)

@@
struct net *n1;
struct net *n2;
@@
- n1 != n2
+ !net_eq(n1, n2)

applied over {include,net,drivers/net}.

Signed-off-by: Octavian Purdila <opurdila@ixiacom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wirel...
David S. Miller [Tue, 24 Nov 2009 23:01:29 +0000 (15:01 -0800)]
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6

14 years agonet/ipv6: Move && and || to end of previous line
Joe Perches [Tue, 24 Nov 2009 22:52:52 +0000 (14:52 -0800)]
net/ipv6: Move && and || to end of previous line

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agopktgen: Fix netdevice unregister
Eric Dumazet [Tue, 24 Nov 2009 22:50:53 +0000 (14:50 -0800)]
pktgen: Fix netdevice unregister

When multi queue compatable names are used by pktgen (eg eth0@0),
we currently cannot unload a NIC driver if one of its device
is currently in use.

Allow pktgen_find_dev() to find pktgen devices by their suffix (netdev name)

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Log interrupt and reset type names, not numbers
Ben Hutchings [Mon, 23 Nov 2009 16:08:17 +0000 (16:08 +0000)]
sfc: Log interrupt and reset type names, not numbers

Define name tables for these enumerations in a similar way as for
loopback.  Move the loopback name table together with them.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Combine high-level header files
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>
14 years agosfc: Remove redundant efx_xmit() function
Ben Hutchings [Mon, 23 Nov 2009 16:07:05 +0000 (16:07 +0000)]
sfc: Remove redundant efx_xmit() function

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove unnecessary casts to struct sk_buff *
Ben Hutchings [Mon, 23 Nov 2009 16:06:47 +0000 (16:06 +0000)]
sfc: Remove unnecessary casts to struct sk_buff *

At some point these casts were used to remove const qualification, but
they are now unneeded.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Gather link state fields in struct efx_nic into new struct efx_link_state
Ben Hutchings [Mon, 23 Nov 2009 16:06:30 +0000 (16:06 +0000)]
sfc: Gather link state fields in struct efx_nic into new struct efx_link_state

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move all I2C stuff into struct falcon_board
Ben Hutchings [Mon, 23 Nov 2009 16:06:02 +0000 (16:06 +0000)]
sfc: Move all I2C stuff into struct falcon_board

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move struct falcon_board into struct falcon_nic_data
Ben Hutchings [Mon, 23 Nov 2009 16:05:45 +0000 (16:05 +0000)]
sfc: Move struct falcon_board into struct falcon_nic_data

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move definition of struct falcon_nic_data into falcon.h
Ben Hutchings [Mon, 23 Nov 2009 16:05:28 +0000 (16:05 +0000)]
sfc: Move definition of struct falcon_nic_data into falcon.h

This is preparation for moving Falcon-specific state required by other
Falcon-specific code.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Make board information explicitly Falcon-specific
Ben Hutchings [Mon, 23 Nov 2009 16:05:12 +0000 (16:05 +0000)]
sfc: Make board information explicitly Falcon-specific

Rename struct efx_board to struct falcon_board.

Introduce and use inline function to look up board info from struct
efx_nic, in preparation for moving it.

Move board init and fini calls into NIC probe and remove functions.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Rename efx_board::init_leds to init_phy and use for SFN4111T
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>
14 years agosfc: Use a single blink implementation
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>
14 years agosfc: SFT9001: Reset LED configuration correctly after blinking
Ben Hutchings [Mon, 23 Nov 2009 16:02:49 +0000 (16:02 +0000)]
sfc: SFT9001: Reset LED configuration correctly after blinking

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Record RX queue number on GRO path
Ben Hutchings [Mon, 23 Nov 2009 16:02:40 +0000 (16:02 +0000)]
sfc: Record RX queue number on GRO path

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Move assertions and buffer cleanup earlier in efx_rx_packet_lro()
Ben Hutchings [Mon, 23 Nov 2009 16:02:25 +0000 (16:02 +0000)]
sfc: Move assertions and buffer cleanup earlier in efx_rx_packet_lro()

This removes the need to use a label and goto, and makes the two
branches mirror each other more closely.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove ridiculously paranoid assertions
Ben Hutchings [Mon, 23 Nov 2009 16:01:55 +0000 (16:01 +0000)]
sfc: Remove ridiculously paranoid assertions

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove redundant gotos from __efx_rx_packet()
Ben Hutchings [Mon, 23 Nov 2009 16:01:44 +0000 (16:01 +0000)]
sfc: Remove redundant gotos from __efx_rx_packet()

This function no longer has any common cleanup code.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agosfc: Remove pointless abstraction of memory BAR number (2)
Ben Hutchings [Mon, 23 Nov 2009 16:01:33 +0000 (16:01 +0000)]
sfc: Remove pointless abstraction of memory BAR number (2)

Finish the job by removing the structure member.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agomacvlan: fix gso_max_size setting
Patrick McHardy [Mon, 23 Nov 2009 22:18:53 +0000 (14:18 -0800)]
macvlan: fix gso_max_size setting

gso_max_size must be set based on the value of the underlying device to
support devices not using the full 64k.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
14 years agoath9k: set ps_default as false
John W. Linville [Mon, 23 Nov 2009 21:15:19 +0000 (16:15 -0500)]
ath9k: set ps_default as false

Copied from original one-line patch here:

http://bugzilla.kernel.org/show_bug.cgi?id=14267#c26

(This is for 2.6.33 and beyond, where the bool was changed to a flag by
"cfg80211: convert bools into flags". -- JWL)

Signed-off-by: John W. Linville <linville@tuxdriver.com>
14 years agossb: Fix range check in sprom write
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>
14 years agossb: Fix SPROM writing
Michael Buesch [Mon, 23 Nov 2009 19:12:13 +0000 (20:12 +0100)]
ssb: Fix SPROM writing

The SPROM writing routines were broken since we rewrote the suspend
handling on wireless devices, because SPROM writing depended on suspend.

This patch changes it and freezes devices with the driver remove(), probe()
callbacks instead. This also simplifies the whole logics a lot.

Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
14 years agorndis_wlan: disable stall workaround
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>
14 years agorndis_wlan: fix buffer overflow in rndis_query_oid
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>
14 years agomac80211: Fix missing kernel-doc notation
Jaswinder Singh Rajput [Sun, 22 Nov 2009 08:17:58 +0000 (13:47 +0530)]
mac80211: Fix missing kernel-doc notation

Fix the following htmldocs warnings:

  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>
14 years agoiwlwifi: remove reset led_tpt from iwl_leds_init()
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>
14 years agoiwlwifi: change message for cmd queue full error
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>
14 years agoiwlwifi: print limited number of event log when uCode error
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>
14 years agoiwlwifi: Tell the ucode immediately when association state changes
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>
14 years agoiwlwifi: dump error log when uCode error occurred
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>
14 years agoiwlwifi: by default, dump entire sram data portion
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>
14 years agoiwlwifi: update supported PCI_ID list for 5xx0 series
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>
14 years agoiwlwifi: separate IO tracing
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>