Commit Graph

110407 Commits

Author SHA1 Message Date
Jesse Brandeburg c431f97ef9 ixgbe: fix ring reallocation in ethtool
changing ring sizes in ethtool needs to be robust.  If an allocation fails the
driver must continue operation, with the previous settings.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:57 -04:00
Jesse Brandeburg b95f5fcb8b ixgbe: add device support for XF LR adapters
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:56 -04:00
Jesse Brandeburg 762f4c5710 ixgbe: recycle pages in packet split mode
most of the time we only need 1500 bytes for a packet which means
we don't need a whole 4k page for each packet.  Share the allocation
by using a reference count to the page and giving half to two
receive descriptors.  This can enable us to use packet split mode
all the time due to the performance increase of allocating half
the pages.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:56 -04:00
Jesse Brandeburg ff819cfb5d ixgbe: fix bug with lots of tx queues
when using more than 8 tx queues you can overrun the 8 bit v_idx
field, so change it to 16 bits to represent the maximum number
of queues (one for each bit)

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:55 -04:00
Jesse Brandeburg 30efa5a363 ixgbe: fix initial interrupt throttle settings
ixgbe was incorrectly setting the throttle rate setting for all tx
queues and the driver has been refreshed to better handle a dynamic
interrupt mode as well as multiple queues.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:54 -04:00
Jesse Brandeburg 3d3d6d3cc2 ixgbe: fix ethtool disable csum for ipv6
ethtool was not disabling the correct netif flags when setting
checksum disable.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:54 -04:00
Jeff Kirsher 05857980cf ixgbe: fix pci_resource allocation as in other drivers
Form: Jesse Brandeburg <jesse.brandeburg@intel.com>

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:53 -04:00
Jesse Brandeburg 98c00a1c5d ixgbe: fix ethtool register dump
1) reading some of the registers in our hardware causes them to clear,
so don't read ICR in the ethtool register dump function.
2) several register iterators were not iterating

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:52 -04:00
Jesse Brandeburg 42c783c5b1 ixgbe: limit small mtu to minimum for ipv4 support
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:51 -04:00
Jesse Brandeburg f47cf66e9c ixgbe: fix bug with shared interrupts
fix ixgbe bug reported with shared legacy interrupts

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:51 -04:00
Jesse Brandeburg 41fb924866 ixgbe: link change interrupt was not causing link event
Upon review a buglet was found where link change was not causing
an immediate link change event as it should.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:50 -04:00
Jesse Brandeburg cf8280ee7b ixgbe: Update watchdog thread to accomodate longerlink_up events
This patch updates the link_up code and watchdog thread so that link_up
doesn't cause stack overflows due to long waits in interrupt context.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@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: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:49 -04:00
Jesse Brandeburg ce94bf469e ixgbe: fix multicast address update
after the most recent patches, the driver was not using the
correct iterator for updating the receive address registers (RAR)

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:48 -04:00
Jesse Brandeburg a1f96ee7cc ixgbe: fix dca defines to not have spaces
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:47 -04:00
Jesse Brandeburg af72166f31 ixgbe: fix bug where using wake queue instead of start
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:47 -04:00
Dhananjay Phadke 040dec3b37 netxen: add pci ids
Define old and new pci vendor and device ids.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:46 -04:00
Brice Goglin 9a6b3b5440 myri10ge: Rename DCA-related firmware counters
Rename the cryptic "dca_capable" to "dca_capable_firmware"
and "dca_enabled" to "dca_device_present" in the firmware
counters.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:45 -04:00
Brice Goglin 330554cb9b myri10ge: Stop scaring people when DCA is built but absent
Stop scaring people with what looks like a fatal message when DCA support
is compiled into their kernel, but the DCA device is not present.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:45 -04:00
Magnus Damm 7fb614bcc7 smc911x: remove duplicate debug printout
Remove duplicated debug printout.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:44 -04:00
Florian Fainelli c1d69937ee r6040: fix bad usage of udelay
This patch fixes the bad usage of udelay(5000), which in turns is a
mdelay(5). It causes compilation for ARM where udelay maximum value
is checked.

Reported-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Florian Fainelli <florian.fainelli@telecomint.eu>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:43 -04:00
Ben Hutchings 31b760202a sfc: Fix type of FALCON_SPI_MAX_LEN
FALCON_SPI_MAX_LEN has type size_t while other SPI lengths have type
unsigned int.  This results in warnings from min() on 64-bit
architectures where they are different.  Add a cast to make it match.

From: Steve Hodgson <shodgson@solarflare.com>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:42 -04:00
Ben Hutchings 13e9ab1143 sfc: Use CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS where appropriate
For some buffers we use a starting offset of either NET_IP_ALIGN or 0
depending on whether we believe the architecture supports efficient
access to unaligned words.  There is now a config macro specifying
whether this is the case, so check that rather than checking for
specific architectures.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:42 -04:00
Ben Hutchings 951f46a1a2 sfc: Remove obsolete comment about PCI modes
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:41 -04:00
Ben Hutchings 0a62f1a681 sfc: Disable interrupts after a fatal interrupt occurs until reset
This should avoid an interrupt storm, which has been observed in the
field with one faulty board.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:40 -04:00
Ben Hutchings 1d0680fd62 sfc: Insert read memory barrier after checking MAC statistics flag
This prevents speculative reading of the statistics before the
completion flag.

From: Neil Turton <nturton@solarflare.com>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:40 -04:00
Ben Hutchings a620e134e9 sfc: Stop generating bogus events in tenxpress_check_hw()
mdio_clause45_links_ok() correctly checks efx_phy_mode_disabled(), so
tenxpress_link_ok() doesn't need to.

From: Steve Hodgson <shodgson@solarflare.com>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:39 -04:00
Steve Hodgson 94be0c5424 sfc: Don't include net_driver.h from falcon_io.h
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:38 -04:00
Ben Hutchings 6bc5d3a933 sfc: Make queue flushes more reliable
Increase the potential retry count for RX flushes from 5 to 100.

Stop polling the RX_DESC_PTR_TBL to infer that a flush might have
happened. Instead absolutely rely on the flush events, unless bug 7803
applies (Falcon rev A only).

To keep things quick, request flushes for every TX and RX queue up
front, and match up the events to requests.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:37 -04:00
Steve Hodgson 92ade881b2 sfc: Don't use EFX_OWORD_FIELD on an event (64-bit, quad-word)
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:37 -04:00
Ben Hutchings c8fcc49c54 sfc: Serialise tenxpress_special_reset() with statistics fetches
On some boards 10Xpress feeds a 156 MHz clock to the Falcon XMAC.  MAC
statistics DMA can fail while this clock is stopped during a PHY reset.

From: Steve Hodgson <shodgson@solarflare.com>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:36 -04:00
Ben Hutchings ef08af03ef sfc: Remove workaround for old firmware bug
There was a bug in XAUI synchronisation in early 10Xpress firmware
versions.  This is fixed in released firmware and we do not need to
work around it.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:35 -04:00
Ben Hutchings e1074a0d96 sfc: Fix memory BAR release call on error path
Match pci_request_region() with pci_release_region(), not
release_mem_region().

From: Steve Hodgson <shodgson@solarflare.com>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:35 -04:00
Ben Hutchings 88c5942513 sfc: Add check for memory allocation failure in falcon_probe_nic()
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:54:34 -04:00
Mats Erik Andersson da8de3929d 8139too: [cosmetic] fix incorrect register for flash-rom
I would like to submit a correction to the driver

     drivers/net/8139too.c,

which in no way changes the compiled driver, but does change
the value of a previously incorrect value for the configuration
register address of Flash PROM on the network processor rtl8139C.
This corrected value is in accordance with the datasheet
for rtl8139C, and in addition this new value is indeed used
in other functional drivers that use this adapter for
programming a Flash memory chip in situ. But as said,
the two new constants are never referenced in the driver
maintained by you: they are only informational and correct!

Mats Erik Andersson, meand@users.sourceforge.net

Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:05 -04:00
Breno Leitao cd0fce0322 s2io: Fix enabling VLAN tag stripping at driver initialization
VLAN doesn't work except if you'd opened the interface in promiscuous
mode before.  This happens because VLAN tag stripping is not correctly
marked as enabled at device startup

Also, the vlan_strip_flag field was moved to the private network
structure.

Signed-off-by: Breno Leitao <leitao@linux.vnet.ibm.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:04 -04:00
Yoichi Yuasa 52845c3fd8 cs89x0: fix warning release_irq label
release_irq label is only used when ALLOW_DMA is defined.

drivers/net/cs89x0.c: In function 'net_open':
drivers/net/cs89x0.c:1401: warning: label 'release_irq' defined but not used

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:04 -04:00
Adrian Bunk e57b641dfa [netdrvr/usb] hso_create_bulk_serial_device(): fix a double free
hso_serial_common_free() mustn't be called if
hso_serial_common_create() fails.

Reported-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:03 -04:00
Krzysztof Halasa 5406951163 wan/hdlc_x25.c: fix a NULL dereference
WAN: fixes a NULL dereference in hdlc_x25.

Reported-by: Adrian Bunk <bunk@kernel.org>.
Signed-off-by: Krzysztof Halasa <khc@pm.waw.pl>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:02 -04:00
Vlad Yasevich 2d1ea19da0 bonding: Do not tx-balance some IPv6 packets on ALB/TLB bonds
IPv6 all-node-multicasts and DAD probes should not be tx-balanced
on ALB/TLB bonds.  The all-node-multicast is an equivalent to IPv4
broadcasts.  DAD probes have to be sent only on the primary so that
we don't get false-positive detections.

Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:01 -04:00
Matthew Wilcox f382a0a8e9 [netdrvr] atl1e: Don't take the mdio_lock in atl1e_probe
Lockdep warns about the mdio_lock taken with interrupts enabled then later
taken from interrupt context.  Initially, I considered changing these
to spin_lock_irq/spin_unlock_irq, but then I looked at atl1e_phy_init()
and saw that it calls msleep().  Sleeping while holding a spinlock is
not allowed either.

In the probe path, we haven't registered the interrupt handler, so
it can't poke at this card yet.  It's before we call register_netdev(),
so I don't think any other threads can reach this card either.  If I'm
right, we don't need a spinlock at all.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:01 -04:00
Hannes Hering 70666c7195 ehea: Fix DLPAR memory handling
The ehea busmap must be allocated only once in the first of many calls of the
ehea_create_busmap_callback.

Signed-off-by: Hannes Hering <hering2@de.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:49:00 -04:00
David Fries 539b06fc73 [netdrvr] ne: Fix suspend and resume for ISA PnP cards.
A call to pnp_stop_dev and pnp_start_dev now shuts down and
initializes plug and play devices for suspend and resume.

Signed-off-by: David Fries <david@fries.net>
Cc: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: Paul Gortmaker <p_gortmaker@yahoo.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:59 -04:00
Martin Gebert 533763d348 [netdrvr] au1000_eth: Spinlock initialisation fix
Seems like the spinlock for the AU1x00 ethernet device is initialised too
late, as it is already used in enable_mac(), which is called via
mii_probe() before the init takes place.

The attached patch is working here for a Linux Au1100 2.6.22.6 kernel,
and as far as I checked should also be applicable to the current head
(just line numbers differ).

Signed-off-by: Martin Gebert <Martin.Gebert@alpha-bit.de>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:58 -04:00
Chris Snook 894d6276ed MAINTAINERS: add Atheros maintainer for atlx
Jie Yang at Atheros is getting more directly involved with upstream work on the
atl* drivers.  This patch changes the ATL1 entry to ATLX (atl2 support posted
to netdev today) and adds him as a maintainer.

Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:58 -04:00
Andrew Morton 6526128c18 drivers/net/mlx4/alloc.c needs mm.h
sparc32 allmodconfig with linux-next:

drivers/net/mlx4/alloc.c: In function 'mlx4_buf_alloc':
drivers/net/mlx4/alloc.c:164: error: 'PAGE_KERNEL' undeclared (first use in this function)
drivers/net/mlx4/alloc.c:164: error: (Each undeclared identifier is reported only once
drivers/net/mlx4/alloc.c:164: error: for each function it appears in.)

this is due to some header shuffle in linux-next.  I didn't look to see what
it was.  I'd sugges that this patch be merged ahead of a linux-next merge to
avoid bisection breaks.

We strictly only need asm/pgtable.h, but going direct to asm includes always
seems grubby.

Cc: Jeff Garzik <jeff@garzik.org>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:57 -04:00
Takashi Iwai c2d1eb085d drivers/net/skfp/pmf.c: Use offsetof() macro
Self-baked macros cause bunch of compile warnings like below:

  CC [M]  drivers/net/skfp/pmf.o
  CC      net/ipv4/fib_semantics.o
drivers/net/skfp/pmf.c:86: warning: cast from pointer to integer of different size
drivers/net/skfp/pmf.c:87: warning: cast from pointer to integer of different size
...

Use the standard offsetof() macro instead.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Acked-by: Alan Cox <alan@redhat.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:56 -04:00
Magnus Damm d1c5ea33c0 smc91x: SMC_IO_SHIFT platform data support for default case
Commit 159198862a added SMC_IO_SHIFT
platform data support. After that ARM board support was added.

The default case is still missing though, so on SuperH SMC_IO_SHIFT
is constantly zero regardless of what you pass as platform data.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
Test-by: Luca Santini <luca.santini@spesonline.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:55 -04:00
Magnus Damm d6bc372ea1 smc91x: fix nowait printout
Commit c4f0e76747 added nowait platform
data support. The printout code was however not updated, so the value
of SMC_NOWAIT is still used. This patch makes sure that nowait is printed
accordingly to platform data.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:55 -04:00
Francois Romieu 523a609496 r8169: fix RxMissed register access
- the register is defined for the 8169 chipset only and there is
  no 8169 beyond RTL_GIGA_MAC_VER_06.
- only the lower 3 bytes of the register are valid

Fixes:
1. http://bugzilla.kernel.org/show_bug.cgi?id=10180
2. http://bugzilla.kernel.org/show_bug.cgi?id=11062 (bits of)

Tested by Hermann Gausterer and Adam Huffman.

Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Cc: Edward Hsu <edward_hsu@realtek.com.tw>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:54 -04:00
Sebastien Dugue e93dcb11dd ehea: fix phyp debugging typo
Fix typo in ehea_h_query_ehea() which prevents building when DEBUG is on.

Signed-off-by: Sebastien Dugue <sebastien.dugue@bull.net>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-09-24 18:48:53 -04:00