Commit graph

78790 commits

Author SHA1 Message Date
Larry Finger
95de2841aa b43: Convert to use of the new SPROM structure
The b43 driver is modified to use the new SPROM structure.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:42 -08:00
Larry Finger
458414b2e3 b44: Convert to use of the new SPROM structure
The b44 driver is changed to use the new SPROM data structure.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:42 -08:00
Larry Finger
c272ef4403 ssb: Convert to use of the new SPROM structure
In disagreement with the SPROM specs, revision 3 devices appear to have
moved the MAC address.

Change ssb to handle the revision 4 SPROM, which is a different size.
This change in size is handled by adding a new variable to the ssb_sprom
struct and using it whenever possible. For those routines that do not
have access to this structure, a 'u16 size' argument is added.

The new PCI_ID for the BCM4328 is also added.

Testing of the Revision 4 SPROM, which is used on the BCM4328, was done
by Michael Gerdau <mgerdau@tiscali.de>.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:41 -08:00
Larry Finger
ac82fab44f ssb: Add new SPROM structure while keeping the old
The SPROM's for various devices utilizing the Sonics Silicon Backplane come
with various revisions. The Revision 2 SPROM inherited the data layout of 1, and
Revision 3 inherited the layout of 2. The first instance of Revision 4 has
now been found in a BCM4328 wireless LAN card. This device does not inherit any
layout from previous versions. Although it was possible to create a data
structure that kept all the old layouts, we decided to start fresh, keep only
those SPROM variables that are used by the drivers that utilize ssb, and to
do the conversion in such a manner that neither compilation or execution will
be affected if a bisection lands in the middle of these changes, while keeping
the patches as small as possible.

In this patch, the sprom structures are changed while maintaining the old ones.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:40 -08:00
Ivo van Doorn
3957ccb56e rt2x00: Move duplicate code into rt2x00pci_txdone()
rt2400pci, rt2500pci and rt61 require different
txdone handling, but the code that pushes the frame
upstream and cleans up the entry is identical to
all of them.
This will create the function rt2x00pci_txdone()
to remove the duplicate code.

Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:40 -08:00
Zhu Yi
797a54c68e iwl4965: fix rxon flags set to wrong value for A mode in .erp_ie_changed
The patch fixes a bug that enables RXON_FLG_TGG_PROTECT_MSK erroneously
for A mode in the erp_ie_changed mac80211 callback.

Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:39 -08:00
Frank Lichtenheld
7223e8d900 b43: silence a bogus gcc warning
use uninitialized_var() to avoid the following bogus warning:
  CC [M]  drivers/net/wireless/b43/debugfs.o
drivers/net/wireless/b43/debugfs.c: In function ‘b43_debugfs_read’:
drivers/net/wireless/b43/debugfs.c:355: warning: ‘ret’ may be used uninitialized in this function

Signed-off-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: Frank Lichtenheld <frank@lichtenheld.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:38 -08:00
Stefano Brivio
59f1b15465 b43legacy: fix kconfig dependecies for rfkill and leds
Fix dependencies for built-in b43legacy.

The patch to b43 by Michael Buesch <mb@bu3sch.de> has been ported to
b43legacy.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:37 -08:00
Reinette Chatre
1d43d312a2 MAINTAINERS: Add Reinette Chatre to iwlwifi & ipw2100/ipw2200
Also fix Zhu Yi's name.

Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
CC: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:36 -08:00
Zhu Yi
4900d6daad remove unused iwl4965_init_hw_rates function
The patch removes the unused function to fix a recursive bug caused
by namespace change.

Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:35 -08:00
Christoph Hellwig
bb8c093bde iwlwifi: cleanup namespace
Prefix all symbols with iwl3945_ or iwl4965_ and thus allow building
the driver into the kernel. Also remove all the useless default
statements in Kconfig while we're at it.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2008-01-28 15:04:35 -08:00
Mohamed Abbas
403ab56b1c iwl4965: fix cannot find a suitable rate issue
This patch fixes the iwl4965 problem for "Can not find a suitable rate
issues." by making rs_switch_to_mimo and rs_switch_to_siso functions
return -1 when CONFIG_IWL4965_HT is not selected. They used to return 0,
which means we can switch to HT rate causing the rate scale problem and
the error message.

The patch also fix another bug reported by Ben Cahill that it uses wrong
value for max_success_limit.

Signed-off-by: Mohamed Abbas <mabbas@linux.intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:33 -08:00
Zhu Yi
3567c11d72 iwlwifi: replace 0x8086 with PCI_VENDOR_ID_INTEL
Replace 0x8086 with PCI_VENDOR_ID_INTEL for PCI_DEVICE declaration.

Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:32 -08:00
Stefano Brivio
1f21ad2a4f b43/b43legacy: fix my copyright notices
Fix my copyright notices in b43 and b43legacy.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Cc: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:31 -08:00
Stefano Brivio
61bca6eb85 b43: rewrite A PHY initialization
Rewrite and sync A PHY initialization with specs, thus allowing for further
work to be done on 802.11a support. Note that A PHY initialization involves
G PHYs as well.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Acked-by: Michael Buesch <mb@bu3sch.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:31 -08:00
Stefano Brivio
db9683fb19 b43legacy: rewrite and fix rfkill initialization
The rfkill subsystem doesn't like code like that
rfkill_allocate();
rfkill_register();
rfkill_unregister();
rfkill_register(); /* <- This will crash */

This sequence happens with
modprobe b43
ifconfig wlanX up
ifconfig wlanX down
ifconfig wlanX up

Fix this by always re-allocating the rfkill stuff before register.

The patch to b43 by Michael Buesch <mb@bu3sch.de> has been ported to
b43legacy.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:30 -08:00
Stefano Brivio
33a3dc9328 b43legacy: use a consistent naming scheme for the ops
Use a consistent naming scheme for the ops.

The patch to b43 by Michael Buesch <mb@bu3sch.de> has been ported to
b43legacy.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:29 -08:00
Stefano Brivio
0a6e1bee57 b43legacy: use the retry limits provided by mac80211
Use the retry limits provided by mac80211.

The patch to b43 by Michael Buesch <mb@bu3sch.de> has been ported to
b43legacy.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-01-28 15:04:28 -08:00
Thomas Bogendoerfer
43831b1581 SGISEEQ: use cached memory access to make driver work on IP28
SGI IP28 machines would need special treatment (enable adding addtional
wait states) when accessing memory uncached. To avoid this pain I changed
the driver to use only cached access to memory.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:28 -08:00
Olof Johansson
b0cd2f9016 pasemi_mac: Don't enable RX/TX without a link (if possible)
pasemi_mac: Don't enable RX/TX without a link (if possible)

Don't enable RX/TX of packets until we have a link, since there's a chance
we'll just get RX frame errors, etc.

The case where we don't have a PHY we can't do much about: Just enable
it and deal with errors as they come in.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:27 -08:00
Olof Johansson
8304b633c5 pasemi_mac: Print warning when not attaching to a PHY
pasemi_mac: Print warning when not attaching to a PHY

Print a warning on the console when not connecting to a phy for an interface.
It turns out to be a pretty common problem when someone gets the MDIO info
wrong in their device tree, resulting in the macs running at a fixed 1Gbit FD.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:26 -08:00
Olof Johansson
5d8949448b pasemi_mac: Remove SKB copy/recycle logic
pasemi_mac: Remove SKB copy/recycle logic

It doesn't really buy us much, since copying is about as expensive
as the allocation in the first place. Just remove it for now.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:26 -08:00
Olof Johansson
7e9916e9dd pasemi_mac: SKB unmap optimization
pasemi_mac: SKB unmap optimization

Avoid touching skb_shinfo() in the unmap path, since it turns out to
normally cause cache misses and delays. instead, save number of fragments
in the TX_RING_INFO structures since that's all that's needed anyway.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:25 -08:00
Olof Johansson
28ae79f531 pasemi_mac: Software-based LRO support
pasemi_mac: Software-based LRO support

Implement LRO for pasemi_mac. Pretty straightforward.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:24 -08:00
Olof Johansson
906674abab pasemi_mac: Improve RX interrupt mitigation
pasemi_mac: Improve RX interrupt mitigation

Currently the receive side interrupts will go off on the reception of
a packet, NAPI will poll the ring and keep polling as long as there's
a decent amount of packets to receive.

This is less than optimal, especially for LRO where it's better if we
have a more substantial amount of packets to process at once, to get
the real LRO benefits.

So, set the count threshold to a higher value and use the timeout feature
that will give us an interrupt even if not enough packets have come in
to set off the count threshold.

FIXME: It'd be real nice to have ethtool support for users to tune this
at runtime.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:24 -08:00
Olof Johansson
61cec3bddc pasemi_mac: Fix TX cleaning
pasemi_mac: Fix TX cleaning

This is a bit awkward. We don't have a timer-delayed interrupt on TX
complete, but we have a count threshold. So set that reasonably high
(32 packets), and schedule the NAPI poll when it goes off. Also bump a
regular timer that will take care of rotting packets for the last 1..31
ones in case we don't trigger a TX interrupt (and there's no RX activity
that would otherwise trigger the poll).

The longer-term fix is to separate TX from RX NAPI and do two separate
poll loops.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:23 -08:00
Olof Johansson
5c15332bed pasemi_mac: performance tweaks
pasemi_mac: performance tweaks

* Seems like we do better with a smaller RX ring, probably because chances of
  still having the SKB cached are better
* Const-ify variables to get better code generation and fewer reloads
* Move prefetching around a little, and try to prefetch the whole SKB
* Set NETIF_F_HIGHDMA
* Misc other minor tweaks

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:22 -08:00
Olof Johansson
34c20624ce pasemi_mac: Convert to new dma library
pasemi_mac: Convert to new dma library

Convert the pasemi_mac driver to the new platform global DMA manaagement
library. This also does a couple of other minor cleanups w.r.t. channel
management.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:21 -08:00
Olof Johansson
8ee9d85779 pasemi: DMA engine management library
pasemi: DMA engine management library

Introduce a DMA management library to manage the various DMA resources
on the PA Semi SoCs. Since several drivers need to allocate these shared
resources, provide some abstractions as well as allocation/free functions
for channels, etc.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:21 -08:00
Olof Johansson
40afa53158 pasemi_mac: Move register definitions to include/asm-powerpc
pasemi_mac: Move register definitions to include/asm-powerpc

Move the common register formats and descriptor layouts from
drivers/net/pasemi_mac.h to include/asm-poewrpc/pasemi_dma.h

Previously only the ethernet driver was using them, but other drivers
are coming up that will also use them, so it makes sense to share the
constants.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:20 -08:00
Olof Johansson
72b05b9940 pasemi_mac: RX/TX ring management cleanup
pasemi_mac: RX/TX ring management cleanup

Prepare a bit for supporting multiple TX queues by cleaning up some
of the ring management and shuffle things around a bit.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:19 -08:00
Stephen Hemminger
5f06eba4dc sky2: rx allocation threshold change
When using larger MTU's sky2 driver changes from allocating one
data area, to using multiple pages. The threshold for this was based on
a heuristic where the cost of a single allocation is bigger than one
page.  Since the allocator has changed, this heuristic is now incorrect;
instead just make the threshold be when the total size of the allocation
is greater than one page.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:19 -08:00
Stephen Hemminger
f03b865491 sky2: align IP header on Rx if possible
The sky2 driver was not aligning the IP header on receive buffers.
This workaround is only needed on hardware with broken FIFO, newer chips
without FIFO can just DMA to unaligned address.

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:18 -08:00
Francois Romieu
5ac5d61632 r6040: cleanups
- whitespaces vs tabs
- use 80 cols
- use if_mii
- use netdev_priv
- remove useless cast to void *
- PCI device id does not need to be globally available

Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2008-01-28 15:04:16 -08:00
Francois Romieu
e6a9ea1052 r6040: erroneous dev->priv
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2008-01-28 15:04:16 -08:00
Francois Romieu
6c3231035d r6040: remove virt_to_bus
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2008-01-28 15:04:15 -08:00
Francois Romieu
5125a78668 r6040: compile error
drivers/net/r6040.c: In function 'rx_buf_alloc':
drivers/net/r6040.c:262: warning: passing argument 2 of 'pci_map_single' makes pointer from integer without a cast

Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
2008-01-28 15:04:14 -08:00
Komuro
bd5a934620 axnet_cs: use spin_lock_irqsave instead of spin_lock + disable_irq
Signed-off-by: Komuro <komurojun-mbn@nifty.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:14 -08:00
Jeff Garzik
2eab17ab88 drivers/net/cxgb3: trim trailing whitespace
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-01-28 15:04:13 -08:00
Divy Le Ray
afefce66a5 cxgb3 - Fix I/O synchronization
Synchronize memory access before ringing
the Tx door bell.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:12 -08:00
Divy Le Ray
a2604be548 cxgb3 - HW set up updates
Disable PEX errors. The HW generates false positives.
Update RSS hash function to a symmetric algorithm.
Update T3C HW support

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:11 -08:00
Divy Le Ray
3e5192eec8 cxgb3 - sysfs methods clean up
Remove unused argument in sysfs methods

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:10 -08:00
Divy Le Ray
23561c9447 cxgb3 - fix interaction with pktgen
Do not use skb->cb to stash unmap info,
save the info to the descriptor state.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:09 -08:00
Divy Le Ray
273fa9042c cxgb3 - FW upgrade
Bump up FW version to 5.0.
Do not downgrade FW within the same major version range.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:09 -08:00
Divy Le Ray
91a6b50cf6 cxgb3 - Add EEH support
Add PCI recovery support

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:08 -08:00
Divy Le Ray
67d92ab765 cxgb3 - Fix resources release.
Remove sysfs entries before unregistering the net devices.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:07 -08:00
Divy Le Ray
678771d6f5 cxgb3 - Use wild card for PCI subdevice ID match
Subdevice ID is not necessarily set to 1.
Use wild card for PCI device matching

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:07 -08:00
Divy Le Ray
42256f57d8 cxgb3 - fix MSI-X failure path
Return error code when msi-x settings fail.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28 15:04:06 -08:00
Jeff Garzik
cba0516ddb [netdrvr] checkpatch cleanups
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-01-28 15:04:05 -08:00
Jeff Garzik
93a3b607e6 wireless: checkpatch cleanups
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-01-28 15:04:04 -08:00