aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/cxgb3 (follow)
AgeCommit message (Collapse)AuthorFilesLines
2009-06-11cxgb3: remove __GFP_NOFAIL usageDivy Le Ray4-7/+103
Pre-allocate a skb at init time to be used for control messages to the HW if skb allocation fails. Tolerate failures to send messages initializing some memories at the cost of parity error detection for these memories. Retry sending connection id release messages if both alloc_skb(GFP_ATOMIC) and alloc_skb(GFP_KERNEL) fail. Do not bring the interface up if messages binding queue set to port fail to be sent. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-06-03cxgb3: minor aq100x phy fixesDivy Le Ray1-12/+12
Use generic MDIO generic values. Based on Ben Hutchings'review comments. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-06-03cxgb3: Update FW to 7.4.0Divy Le Ray1-2/+2
Update FW to 7.4. Bump up driver revision. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-06-03Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6David S. Miller4-11/+17
Conflicts: drivers/net/forcedeth.c
2009-05-29cxgb3: add support for the Aquantia 10G-BT phyDivy Le Ray4-2/+359
Add support for the Aquantia AQ1002 10G-BaseT phy. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-29cxgb3: Add Aeluros 2020 phy supportDivy Le Ray4-65/+769
Add support for the AEL2020 phy. Add PCI IDs of the boards using this phy. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-29cxgb3: move away from LLTXDivy Le Ray2-11/+7
cxgb3 no longer advertizes LLTX. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-29cxgb3: link fault fixesDivy Le Ray2-3/+10
Do not call t3_link_fault() under spinlock, as it calls msleep(). Besides, only the access to pi->link_fault needs to be serialized. Also initialize local variables before checking the link status, link state fields might otherwise end up containing garbage. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-29cxgb3: fix dma mapping regressionDivy Le Ray2-8/+7
Commit 5e68b772e6efd189d6aca76f6872fb75d51ace60 cxgb3: map entire Rx page, feed map+offset to Rx ring. introduced a regression on platforms defining DECLARE_PCI_UNMAP_ADDR() and related macros as no-ops. Rx descriptors are fed with the a page buffer bus address + page chunk offset. The page buffer bus address is set and retrieved through pci_unamp_addr_set(), pci_unmap_addr(). These functions being meaningless on x86 (if CONFIG_DMA_API_DEBUG is not set). The HW ends up with a bogus bus address. This patch saves the page buffer bus address for all plaftorms. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-29net: dont update dev->trans_start in 10GB driversEric Dumazet1-1/+0
Followup of commits 9d21493b4beb8f918ba248032fefa393074a5e2b and 08baf561083bc27a953aa087dd8a664bb2b88e8e (net: tx scalability works : trans_start) (net: txq_trans_update() helper) Now that core network takes care of trans_start updates, dont do it in drivers themselves, if possible. Multi queue drivers can avoid one cache miss (on dev->trans_start) in their start_xmit() handler. Exceptions are NETIF_F_LLTX drivers (vxge & tehuti) Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-20cxgb3: set phy's mdio dev before the phy init sequenceDivy Le Ray1-1/+1
mdio's dev field needs to be set before mdio ops occur. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-20cxgb3: Use generic XENPAK LASI register definitionsBen Hutchings3-16/+9
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Acked-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-05-03Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6David S. Miller1-1/+1
2009-05-01cxgb3: fixing gcc 4.4 compiler warning: suggest parentheses around operand of ‘!’Sergey Senozhatsky1-1/+1
Trivial: fixing gcc 4.4 compiler warning: drivers/net/cxgb3/t3_hw.c: In function ‘t3_prep_adapter’: drivers/net/cxgb3/t3_hw.c:3782: warning: suggest parentheses around operand of ‘!’ or change ‘|’ to ‘||’ or ‘!’ to ‘~’ Signed-off-by: Sergey Senozhatsky <sergey.senozhatsky@mail.by> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-29cxgb3: Use generic MDIO definitions and mdio_mii_ioctl()Ben Hutchings5-224/+194
Compile-tested only. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-21Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6David S. Miller2-34/+21
Conflicts: net/core/dev.c
2009-04-20cxgb3: Fix EEH final recovery attemptDivy Le Ray1-0/+7
EEH attempts to recover up 6 times. The last attempt leaves all the ports and adapter down.hen The driver is then unloaded, bringing the adapter down again unconditionally. The unload will hang. Check if the adapter is already down before trying to bring it down again. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-20cxgb3: Fix potential msi-x vector leakDivy Le Ray1-1/+6
Release vectors when a MSI-X allocation fails. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-20cxgb3: fix workqueue flush issuesDivy Le Ray1-3/+5
The fatal error task can be scheduled while processing an offload packet in NAPI context when the connection handle is bogus. this can race with the ports being brought down and the cxgb3 workqueue being flushed. Stop napi processing before flushing the work queue. The ULP drivers (iSCSI, iWARP) might also schedule a task on keventd_wk while releasing a connection handle (cxgb3_offload.c::cxgb3_queue_tid_release()). The driver however does not flush any work on keventd_wq while being unloaded. This patch also fixes this. Also call cancel_delayed_work_sync in place of the the deprecated cancel_rearming_delayed_workqueue. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-20cxgb3: fix link fault handlingDivy Le Ray2-30/+3
Use the existing periodic task to handle link faults. The link fault interrupt handler is also called in work queue context, which is wrong and might cause potential deadlocks. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-16gro: New frags interface to avoid copying shinfoHerbert Xu2-22/+33
It turns out that copying a 16-byte area at ~800k times a second can be really expensive :) This patch redesigns the frags GRO interface to avoid copying that area twice. The two disciples of the frags interface have been converted. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-04-07dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32)Yang Hongyang1-1/+1
Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) Signed-off-by: Yang Hongyang<yanghy@cn.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-04-07dma-mapping: replace all DMA_64BIT_MASK macro with DMA_BIT_MASK(64)Yang Hongyang1-2/+2
Replace all DMA_64BIT_MASK macro with DMA_BIT_MASK(64) Signed-off-by: Yang Hongyang<yanghy@cn.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-03-27cxgb3: map entire Rx page, feed map+offset to Rx ring.Divy Le Ray2-35/+106
DMA mapping can be expensive in the presence of iommus. Reduce the Rx iommu activity by mapping an entire page, and provide the H/W the mapped address + offset of the current page chunk. Reserve bits at the end of the page to track mapping references, so the page can be unmapped. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-27cxgb3: differentiate portx and Tx channelsDivy Le Ray3-19/+24
Separate ports from H/W Tx channels. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-27cxgb3: use resource_size_t for mmio declarationsDivy Le Ray1-1/+4
Use resource_size_t to declare mmio start and len variables. Print PEX error register after EEH resumed. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-27cxgb3: sge setup fixesDivy Le Ray2-8/+39
Enable timestamps, update delayed ack threshold for iSCSI/iWARP traffic Remove the len flag in Tx requests. It might corrupt offload trace packets. Update SGE context setup to avoid potential H/W misprogrammation. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-27cxgb3: start qset timers when setup succeededDivy Le Ray3-4/+24
Start queue set reclaim timers after the queue sets have been allocated successfully. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: update driver versionDivy Le Ray1-1/+1
update driver version to 1.1.1-ko Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: update FWDivy Le Ray1-1/+1
Update FW to 7.1 Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: detect mac link faults.Divy Le Ray6-9/+285
The driver currently ignores the local or remote link faults raised at the mac layer. This patch fixes it. Our mac however only advertizes link events, so wait for the phy to stabilize the link, then enable mac link events interrupts. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: Update Rev3 mac workaroundDivy Le Ray1-39/+33
Update the heurstics workaround unlocking a hung mac: - reduce Tx mac toggling by enabling Tx drain before resetting the mac - Take Tx (lack of) activity in account only - Update the monitoring counter range to 64 bits Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: disable high freq non-data interruptsDivy Le Ray4-5/+86
Under RX pressure, The HW might generate a high load of interrupts to signal mac fifo or free lists overflow. Disable the interrupts, and poll the relevant status bits to maintain stats. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: separate TX and RX reclaim handlersDivy Le Ray2-40/+89
Separate TX and RX reclaim handlers Don't disable interrupts in RX reclaim handler. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: prefetch buffer access in GRO modeDivy Le Ray1-0/+3
Elmininate a cache miss when accessing the CPL header within the first aggregated buffer. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: fix skb truesize in jumbo modeDivy Le Ray1-1/+2
Update skb truesize correctly for the 2nd buffer from a Jumbo frame Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: release page ref on mapping errorDivy Le Ray1-12/+14
Release page chunk reference in case we fail to map it. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-03-13cxgb3: ring rx door bell less frequentlyDivy Le Ray2-8/+25
Ring free lists door bell less frequently, specifically every quarter of the active FL size. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-02-24Merge branch 'master' of /home/davem/src/GIT/linux-2.6/David S. Miller2-0/+8
2009-02-18cxgb3: Add support for PCI ID 0x35.Divy Le Ray2-0/+8
Add support for adapters with a PCI id equal to 0x35. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-02-17drivers/net/cxgb3: fix sparse warnings: fix signednessHannes Eder1-1/+2
Fix this sparse warning: drivers/net/cxgb3/ael1002.c:1010:60: warning: incorrect type in argument 4 (different signedness) Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-02-17drivers/net/cxgb3: fix sparse warning: symbol shadows an earlier oneHannes Eder1-2/+1
Impact: Move variable declaration as close to usage as possible. Fix this sparse warning: drivers/net/cxgb3/cxgb3_main.c:1586:21: warning: symbol 'cap' shadows an earlier one Signed-off-by: Hannes Eder <hannes@hanneseder.net> Acked-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-02-04Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6David S. Miller1-2/+1
2009-02-04cxgb3: Fix lro switchDivy Le Ray1-2/+1
The LRO switch is always set to 1 in the rx processing loop. It breaks the accelerated iSCSI receive traffic. Fix its computation. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-01-27net: Add skb_record_rx_queue() calls to multiqueue capable drivers.David S. Miller1-0/+1
Signed-off-by: David S. Miller <davem@davemloft.net>
2009-01-26cxgb3: Notify fatal errorsDivy Le Ray3-4/+28
Set up a notification mechanism to inform upper layer modules (iWARP, iSCSI) of a chip reset due to an EEH event or a fatal error. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-01-21cxgb3: Replace LRO with GROHerbert Xu3-152/+22
This patch makes cxgb3 invoke the GRO hooks instead of LRO. As GRO has a compatible external interface to LRO this is a very straightforward replacement. I've kept the ioctl controls for per-queue LRO switches. However, we should not encourage anyone to use these. Because of that, I've also kept the skb construction code in cxgb3. Hopefully we can phase out those per-queue switches and then kill this too. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Acked-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-01-21cxgb3: ease msi-x settings conditionsDivy Le Ray2-8/+16
The driver currently drops to line interrupt mode if it did not get all the msi-x vectors it requested. Allow msi-x settings when a minimal amount of vectors is provided. Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-01-19cxgb3: Fix LRO misalignmentDivy Le Ray1-0/+1
The lro manager's frag_align_pad setting was missing, leading to misaligned access to the skb passed up to the stack. Tested-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: Divy Le Ray <divy@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2009-01-11cxgb3: Keep LRO off if disabled when interface is downRoland Dreier3-10/+21
I have a system with a Chelsio adapter (driven by cxgb3) whose ports are part of a Linux bridge. Recently I updated the kernel and discovered that things stopped working because cxgb3 was doing LRO on packets that were passed into the bridge code for forwarding. (Incidentally, this problem manifested itself in a strange way that made debugging a bit interesting -- for some reason, the skb_warn_if_lro() check in bridge didn't trigger and these LROed packets were forwarded out a forcedeth interface, and caused the forcedeth transmit path to get stuck) This is because cxgb3 has no way of keeping state for the LRO flag until the interface is brought up, so if the bridging code disables LRO while the interface is down, then cxgb3_up() will just reenable LRO, and on my Debian system at least, the init scripts add interfaces to a bridge before bringing the interfaces up. Fix this by keeping track of each interface's LRO state in cxgb3 so that when bridge disables LRO, it stays disabled in cxgb3_up() when the interface is brought up. I did this by changing the rx_csum_offload flag into a pair of bit flags; the effect of this on the rx_eth() fast path is miniscule enough that it should be fine (eg on x86, a cmpb instruction becomes a testb instruction). Signed-off-by: Roland Dreier <rolandd@cisco.com> Signed-off-by: David S. Miller <davem@davemloft.net>