aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2009-11-29ethtool: Add Direct Attach support to connector port reportingPJ Waskiewicz1-0/+2
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>
2009-11-29ixgbe: Fix Receive Address Register (RAR) cleaning and accountingShannon Nelson1-4/+4
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>
2009-11-29ixgbe: LINKS2 is not a valid register for 82598Don Skidmore1-4/+11
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>
2009-11-29ixgbe: Disable Flow Control for certain devicesPJ Waskiewicz1-0/+14
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>
2009-11-29ixgbe: handle parameters for tx and rx EITR, no div0Shannon Nelson1-6/+7
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>
2009-11-29X25: Fix oops and refcnt problems from x25_dev_getandrew hendry1-1/+3
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>
2009-11-29X25: Check for errors in x25_initandrew hendry1-3/+16
Adds error checking to x25_init. Signed-off-by: Andrew Hendry <andrew.hendry@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-29X25: Move SYSCTL ifdefs into headerandrew hendry2-4/+6
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>
2009-11-29NET: smc91x: convert to dev_pm_opsKevin Hilman1-6/+12
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>
2009-11-29Merge branch 'net-next' of git://git.kernel.org/pub/scm/linux/kernel/git/vxy/lksctp-devDavid S. Miller17-500/+224
2009-11-29sctp: on T3_RTX retransmit all the in-flight chunksAndrei Pelinescu-Onciul4-15/+2
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>
2009-11-29sfc: Clean up RX event handlingBen Hutchings3-8/+8
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>
2009-11-28sfc: Move descriptor cache base addresses to struct efx_nic_typeBen Hutchings2-4/+12
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-28sfc: Decouple NIC revision number from Falcon PCI revision numberBen Hutchings8-52/+48
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-28sfc: Remove some redundant whitespaceBen Hutchings1-2/+0
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-28sfc: Remove another unused workaround macroBen Hutchings1-2/+0
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-28sfc: Remove EFX_WORKAROUND_9141 macroMatthew Slattery2-3/+1
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>
2009-11-28sfc: Limit some hardware workarounds to FalconBen Hutchings2-3/+4
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-28sfc: Always start Falcon using the XMACSteve Hodgson3-8/+16
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>
2009-11-28sfc: Replace MDIO spinlock with mutexSteve Hodgson3-9/+9
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>
2009-11-28sfc: QT202x: Reset before reading PHY idSteve Hodgson1-14/+8
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>
2009-11-28sfc: Simplify PHY pollingSteve Hodgson7-124/+103
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>
2009-11-26vlan: support "loose binding" to the underlying network devicePatrick McHardy4-5/+14
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>
2009-11-26sfc: Do not set net_device::trans_start in self-testBen Hutchings1-1/+0
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Move inline comment into kernel-docBen Hutchings1-3/+1
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Change MAC promiscuity and multicast hash at the same timeBen Hutchings4-23/+29
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>
2009-11-26sfc: Simplify XMAC link pollingBen Hutchings8-54/+41
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>
2009-11-26sfc: Move Falcon board/PHY/MAC monitoring code to falcon.cBen Hutchings3-10/+17
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Split MAC stats DMA initiation and completionBen Hutchings9-88/+139
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>
2009-11-26sfc: Hold MAC lock for longer in efx_init_port()Ben Hutchings1-5/+9
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>
2009-11-26sfc: Only switch Falcon MAC clocks as necessarySteve Hodgson1-17/+25
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Remove unused function efx_flush_queues()Ben Hutchings2-14/+0
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Fix bugs in RX queue flushingBen Hutchings2-41/+73
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>
2009-11-26sfc: Clean up struct falcon_board and struct falcon_board_dataBen Hutchings7-80/+85
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>
2009-11-26sfc: Remove unused constantBen Hutchings1-3/+0
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Comment correctionsBen Hutchings3-6/+3
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Strengthen EFX_ASSERT_RESET_SERIALISEDBen Hutchings1-1/+2
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26sfc: Treat all MAC registers as 128-bitBen Hutchings2-14/+14
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>
2009-11-26sfc: Fix descriptor cache sizesBen Hutchings1-4/+4
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>
2009-11-26macvlan: export macvlan mode through netlinkArnd Bergmann2-6/+65
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>
2009-11-26macvlan: implement bridge, VEPA and private modeArnd Bergmann1-8/+72
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>
2009-11-26macvlan: cleanup rx statisticsArnd Bergmann1-29/+41
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>
2009-11-26veth: move loopback logic to common locationArnd Bergmann3-14/+45
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>
2009-11-26via-velocity: Bump versionSimon Kagstrom1-1/+1
Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26via-velocity: Set tx checksum from ethtool instead of module parameterSimon Kagstrom2-15/+4
Defaults to on (as before). Signed-off-by: Simon Kagstrom <simon.kagstrom@netinsight.net> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-11-26via-velocity: Re-enable transmit scatter-gather supportSimon Kagstrom1-30/+53
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>
2009-11-26via-velocity: Change DMA_LENGTH_DEF (from the VIA driver)Simon Kagstrom1-1/+1
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>
2009-11-26via-velocity: Implement NAPI supportSimon Kagstrom2-35/+49
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>
2009-11-26via-velocity: Add ethtool interrupt coalescing supportSimon Kagstrom2-2/+165
(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>
2009-11-26via-velocity: Correct 64-byte alignment for rx buffersSimon Kagstrom1-1/+2
(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>