summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/emulex
Commit message (Collapse)AuthorAgeFilesLines
* Merge tag 'rdma-for-3.5' of ↵Linus Torvalds2012-05-228-15/+413
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband Pull InfiniBand/RDMA changes from Roland Dreier: - Add ocrdma hardware driver for Emulex IB-over-Ethernet adapters - Add generic and mlx4 support for "raw" QPs: allow suitably privileged applications to send and receive arbitrary packets directly to/from the hardware - Add "doorbell drop" handling to the cxgb4 driver - A fairly large batch of qib hardware driver changes - A few fixes for lockdep-detected issues - A few other miscellaneous fixes and cleanups Fix up trivial conflict in drivers/net/ethernet/emulex/benet/be.h. * tag 'rdma-for-3.5' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: (53 commits) RDMA/cxgb4: Include vmalloc.h for vmalloc and vfree IB/mlx4: Fix mlx4_ib_add() error flow IB/core: Fix IB_SA_COMP_MASK macro IB/iser: Fix error flow in iser ep connection establishment IB/mlx4: Increase the number of vectors (EQs) available for ULPs RDMA/cxgb4: Add query_qp support RDMA/cxgb4: Remove kfifo usage RDMA/cxgb4: Use vmalloc() for debugfs QP dump RDMA/cxgb4: DB Drop Recovery for RDMA and LLD queues RDMA/cxgb4: Disable interrupts in c4iw_ev_dispatch() RDMA/cxgb4: Add DB Overflow Avoidance RDMA/cxgb4: Add debugfs RDMA memory stats cxgb4: DB Drop Recovery for RDMA and LLD queues cxgb4: Common platform specific changes for DB Drop Recovery cxgb4: Detect DB FULL events and notify RDMA ULD RDMA/cxgb4: Drop peer_abort when no endpoint found RDMA/cxgb4: Always wake up waiters in c4iw_peer_abort_intr() mlx4_core: Change bitmap allocator to work in round-robin fashion RDMA/nes: Don't call event handler if pointer is NULL RDMA/nes: Fix for the ORD value of the connecting peer ...
| * be2net: Add functionality to support RoCE driverParav Pandit2012-05-087-15/+375
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Increase MSI-X vectors by 5 for RoCE traffic. - Add macro to check roce support on a device. - Add device-specific doorbell and MSI-X vector fields shared with NIC functionality. - Provide RoCE driver registration and deregistration functions. - Add support functions which will be invoked on adapter add/remove and port up/down events. - Traverse through the list of adapters to invoke callback functions. Signed-off-by: Parav Pandit <parav.pandit@emulex.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Roland Dreier <roland@purestorage.com>
| * be2net: Add function to issue mailbox cmd on MQParav Pandit2012-05-081-0/+39
| | | | | | | | | | | | | | | | | | - Add generic function to issue mailbox cmd on MQ as export function. - RoCE driver will use this before it setups its own MQ. Signed-off-by: Parav Pandit <parav.pandit@emulex.com> Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Roland Dreier <roland@purestorage.com>
* | be2net: Fix to allow get/set of debug levels in the firmware.Somnath Kotur2012-05-185-0/+230
| | | | | | | | | | | | | | | | | | | | Patch re-spin. Incorporated review comments by Ben Hutchings. Signed-off-by: Suresh Reddy <suresh.reddy@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Acked-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: avoid disabling sriov while VFs are assignedSathya Perla2012-05-113-89/+134
| | | | | | | | | | | | | | | | | | | | | | | | Calling pci_disable_sriov() while VFs are assigned to VMs causes kernel panic. This patch uses PCI_DEV_FLAGS_ASSIGNED bit state of the VF's pci_dev to avoid this. Also, the unconditional function reset cmd issued on a PF probe can delete the VF configuration for the previously enabled VFs. A scratchpad register is now used to issue a function reset only when needed (i.e., in a crash dump scenario.) Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix EEH error reset before a flash dump completesSomnath Kotur2012-05-031-0/+5
| | | | | | | | | | | | | | | | | | | | An EEH error can cause the FW to trigger a flash debug dump. Resetting the card while flash dump is in progress can cause it not to recover. Wait for it to finish before letting EEH flow to reset the card. Signed-off-by: Sathya Perla <Sathya.Perla@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Record receive queue index in skb to aid RPS.Somnath Kotur2012-05-031-0/+2
| | | | | | | | | | | | Signed-off-by: Sarveshwar Bandi <Sarveshwar.Bandi@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix to apply duplex value as unknown when link is down.Somnath Kotur2012-05-031-1/+1
| | | | | | | | | | | | | | Suggested-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: Sarveshwar Bandi <sarveshwar.bandi@emulex.com> Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix to not set link speed for disabled functions of a UMC cardSomnath Kotur2012-05-031-1/+1
| | | | | | | | | | | | | | | | | | This renders the interface view somewhat inconsistent from the Host OS POV considering the rest of the interfaces are showing their respective speeds based on the bandwidth assigned to them. Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: update the driver versionAjit Khaparde2012-04-271-1/+1
| | | | | | | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: fix speed displayed by ethtool on certain SKUsAjit Khaparde2012-04-271-1/+1
| | | | | | | | | | | | | | logical speed returned by link_status_query needs to be multiplied by 10. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Ignore status of some ioctls during driver loadAjit Khaparde2012-04-271-13/+4Star
| | | | | | | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix FW download for BEPadmanabh Ratnakar2012-04-263-78/+166
| | | | | | | | | | | | | | | | | | Skip flashing a FW component if that component is not present in a particular FW UFI image. Signed-off-by: Somnath Kotur <somnath.kotur@emulex.com> Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix wrong status getting returned for MCC commandsPadmanabh Ratnakar2012-04-263-27/+67
| | | | | | | | | | | | | | | | | | | | | | MCC Response CQEs are processed as part of NAPI poll routine and also synchronously. If MCC completions are consumed by NAPI poll routine, wrong status is returned to synchronously waiting routine. Fix this by getting status of MCC command from command response instead of response CQEs. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix Lancer statisticsPadmanabh Ratnakar2012-04-262-1/+6
| | | | | | | | | | | | | | | | Fix port num sent in command to get stats. Also skip unnecessary parsing of stats for Lancer. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix traffic stall INTx modePadmanabh Ratnakar2012-04-261-1/+3
| | | | | | | | | | | | | | | | | | | | | | EQ is getting armed wrongly in INTx mode as INTx interrupt is taking some time to deassert. This can cause another interrupt while NAPI is scheduled and scheduling a NAPI in interrupt does not take effect. This causes interrupt to be missed and traffic stalls. Fixing this by preventing wrong arming of EQ. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix ethtool self test for LancerPadmanabh Ratnakar2012-04-261-1/+1
| | | | | | | | | | | | | | | | Lancer does not support DDR self test. Fix ethtool self test by skipping this test for Lancer. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix FW download in LancerPadmanabh Ratnakar2012-04-261-5/+3Star
| | | | | | | | | | | | | | | | Increase time given by driver to adapter for completing FW download to 30 seconds. Also return correct status when FW download times out. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix VLAN/multicast packet receptionPadmanabh Ratnakar2012-04-261-14/+30
| | | | | | | | | | | | | | | | | | | | | | | | VLAN and multicast hardware filters are limited and can get exhausted in adapters with many PCI functions. If setting a VLAN or multicast filter fails due to lack of sufficient hardware resources, these packets get dropped. Fix this by switching to VLAN or multicast promiscous mode so that these packets are not dropped. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: fix ethtool get settingsAjit Khaparde2012-04-235-102/+239
|/ | | | | | | | ethtool get settings was not displaying all the settings correctly. use the get_phy_info to get more information about the PHY to fix this. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: fix programming of VLAN tags for VFAjit Khaparde2012-03-194-5/+157
| | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: Fix number of vlan slots in flex modeAjit Khaparde2012-03-191-1/+1
| | | | | | | In flex10 mode the number of vlan slots supported is halved. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: Program secondary UC MAC address into MAC filterAjit Khaparde2012-03-192-6/+53
| | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: enable WOL by default if h/w supports itAjit Khaparde2012-03-195-17/+136
| | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: Remove unused OFFSET_IN_PAGE() macroRoland Dreier2012-03-011-4/+0Star
| | | | | Signed-off-by: Roland Dreier <roland@purestorage.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: update driver versionSathya Perla2012-02-241-1/+1
| | | | | Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: enable RSS for ipv6 pktsSathya Perla2012-02-241-1/+2
| | | | | Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: reset queue address after freeingSathya Perla2012-02-241-2/+4
| | | | | | | | This will prevent double free in some cases where be_clear() is called for cleanup when be_setup() fails half-way. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: fix tx completion cleanupSathya Perla2012-02-241-33/+42
| | | | | | | | As a part of be_close(), instead of waiting for a max of 200ms for each TXQ, wait for a total of 200ms for completions from all TXQs to arrive. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: cancel be_worker during EEH recoverySathya Perla2012-02-242-5/+9
| | | | | | | | EEH recovery involves ring cleanup and re-creation. The worker thread must not run during EEH cleanup/resume. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: event queue re-designSathya Perla2012-02-135-578/+434Star
| | | | | | | | | | | | | | | | | | | | v2: Fixed up the bad typecasting pointed out by David... In the current design 8 TXQs are serviced by 1 EQ, while each RSS queue is serviced by a separate EQ. This is being changed as follows: - Upto 8 EQs will be used (based on the availabilty of msix vectors). Each EQ will handle 1 RSS and 1 TX ring. The default non-RSS RX queue and MCC queue are handled by the last EQ. - On cards which provide support, upto 8 RSS rings will be used, instead of the current limit of 4. The new design allows spreading the TX multi-queue completion processing across multiple CPUs unlike the previous design. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller2012-02-041-5/+1Star
|\
| * ethtool: Null-terminate filename passed to ethtool_ops::flash_deviceBen Hutchings2012-02-011-5/+1Star
| | | | | | | | | | | | | | | | | | | | The parameters for ETHTOOL_FLASHDEV include a filename, which ought to be null-terminated. Currently the only driver that implements ethtool_ops::flash_device attempts to add a null terminator if necessary, but does it wrongly. Do it in the ethtool core instead. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Use new implementation of get mac list commandPadmanabh Ratnakar2012-02-043-40/+92
| | | | | | | | | | | | | | | | | | VFs use get mac list command to get their mac address. The format of this command has changed. Update driver to use the new format. Signed-off-by: Mammatha Edhala <mammatha.edhala@emulex.com> Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: Fix link status query commandPadmanabh Ratnakar2012-02-041-2/+4
| | | | | | | | | | | | | | | | | | Version number in query link status command is getting overwritten in be_wrb_cmd_hdr_prepare() routine. Move the initialization to fix this issue. Also initialize the domain field. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: add descriptions for stat counters reported via ethtoolSathya Perla2012-02-014-18/+74
| | | | | | | | | | | | | | | | | | | | | | Also rename a few counters appropritely and delete 2 counters that are not implemented in HW. vlan_mismatch_drops does not exist in BE3 and is accounted for in address_mismatch_drops. Do the same thing for BE2 and Lancer. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* | be2net: allocate more headroom in incoming skbsEric Dumazet2012-01-262-1/+4
|/ | | | | | | | | | | | | | | | | | | Allocation of 64 bytes in skb headroom is not enough if we have to pull ethernet + ipv6 + tcp headers, and/or extra tunneling header. Its currently not noticed because netdev_alloc_skb_ip_align(64) give us more room, thanks to power-of-two kmalloc() roundups. Make sure we ask for 128 bytes so that side effects of upcoming patches from Ian Campbell dont decrease benet rx performance, because of extra skb head reallocations. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Cc: Ian Campbell <Ian.Campbell@citrix.com> Cc: Vasundhara Volam <vasundhara.volam@emulex.com> Cc: Sathya Perla <sathya.perla@emulex.com> Cc: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: create RSS rings even in multi-channel configsSathya Perla2012-01-221-2/+1Star
| | | | | | | | | | | | Currently RSS rings are not created in a multi-channel config. RSS rings can be created on one (out of four) interfaces per port in a multi-channel config. Doing this insulates the driver from a FW bug wherin multi-channel config is wrongly reported even when not enabled. This also helps performance in a multi-channel config, as one interface per port gets RSS rings. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* netdev: make net_device_ops conststephen hemminger2012-01-091-1/+1
| | | | | | | More drivers where net_device_ops should be const. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: query link status in be_open()Ajit Khaparde2011-12-305-19/+45
| | | | | | | | | | | | be2net gets an async link status notification from the FW when it creates an MCC queue. There are some cases in which this gratuitous notification is not received from FW. To cover this explicitly query the link status in be_open(). Signed-off-by: Vasundhara Volam <vasundhara.volam@emulex.com> Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: fix range check for set_qos for a VFAjit Khaparde2011-12-301-5/+9
| | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: fix be_vlan_add/rem_vidAjit Khaparde2011-12-301-11/+24
| | | | | | | | 1) fix be_vlan_add/rem_vid to return proper status 2) perform appropriate housekeeping if firmware command succeeds. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: Fix INTx processing for LancerPadmanabh Ratnakar2011-12-191-1/+9
| | | | | | | | | | Lancer does not have HW registers to indicate the EQ causing the INTx interrupt. As a result EQE entries of one EQ may be consumed when interrupt is caused by another EQ. Fix this by arming CQs at the end of NAPI poll routine to regenerate the EQEs. Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: Add support for Skyhawk cardsAjit Khaparde2011-12-162-0/+6
| | | | | Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: refactor/cleanup vf configuration codeSathya Perla2011-12-132-77/+80
| | | | | | | | | | | | | | - use adapter->num_vfs (and not the module param) to store the actual number of vfs created. Use the same variable to reflect SRIOV enable/disable state. So, drop the adapter->sriov_enabled field. - use for_all_vfs() macro in VF configuration code - drop the "vf_" prefix for the fields of be_vf_cfg; the prefix is redundant and removing it helps reduce line wrap Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: fix ethtool ringparam reportingSathya Perla2011-12-131-7/+4Star
| | | | | | | | | | | The ethtool "-g" option is supposed to report the max queue length and user modified queue length for RX and TX queues. be2net doesn't support user modification of queue lengths. So, the correct values for these would be the max numbers. be2net incorrectly reports the queue used values for these fields. Signed-off-by: Sathya Perla <sathya.perla@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: workaround to fix a bug in BEAjit Khaparde2011-12-121-8/+38
| | | | | | | disable Tx vlan offloading in certain cases. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: update some counters to display via ethtoolAjit Khaparde2011-12-121-0/+2
| | | | | | | update pmem_fifo_overflow_drop, rx_priority_pause_frames counters. Signed-off-by: Ajit Khaparde <ajit.khaparde@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* net: make vlan ndo_vlan_rx_[add/kill]_vid return error valueJiri Pirko2011-12-091-4/+8
| | | | | | | | | | | | Let caller know the result of adding/removing vlan id to/from vlan filter. In some drivers I make those functions to just return 0. But in those where there is able to see if hw setup went correctly, return value is set appropriately. Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* be2net: netpoll supportIvan Vecera2011-12-091-1/+17
| | | | | | | Add missing netpoll support. Signed-off-by: Ivan Vecera <ivecera@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>