1. 01 4月, 2015 1 次提交
  2. 26 1月, 2015 1 次提交
  3. 29 10月, 2014 1 次提交
  4. 23 9月, 2014 1 次提交
    • J
      mlx4: Fix mlx4 reg/unreg mac to work properly with 0-mac addresses · f4fd40b2
      Jack Morgenstein 提交于
      There is a chance that the VF mlx4 RoCE driver (mlx4_ib) may see a 0-mac
      as the current default MAC address when a RoCE interface first comes up.
      
      In this case, the RoCE driver registers the 0-mac to get its MAC index --
      used in the INIT2RTR transition when it creates its proxy Q1 qp's.
      
      If we do not allow QP1 to be created, the RoCE driver will not come up.
      If we do not register the 0-mac, but simply use a random mac-index,
      QP1 will attempt to send packets with an someone's else source MAC which
      will get the system into more troubled.
      
      Since a 0-mac was previously used to indicate a free slot, this leads to
      errors, both when the 0-mac is registered and when it is unregistered.
      
      The required fix is to check in addition that the slot containing the
      0-mac has a reference count of zero.
      
      Additionally, when comparing MAC addresses, need to mask out the 2 MSBs
      of the u64 mac on both sides of the comparison.
      
      Note that when the EN driver (mlx4_en) comes up, it set itself a proper
      mac --> the RoCE driver gets to be notified on that and further handing
      is done with the update qp command, as was added by commit 9433c188
      ("IB/mlx4: Invoke UPDATE_QP for proxy QP1 on MAC changes").
      Signed-off-by: NJack Morgenstein <jackm@dev.mellanox.co.il>
      Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com>
      Signed-off-by: NRoland Dreier <roland@purestorage.com>
      f4fd40b2
  5. 09 7月, 2014 2 次提交
  6. 31 5月, 2014 1 次提交
  7. 09 5月, 2014 1 次提交
  8. 06 5月, 2014 1 次提交
  9. 29 3月, 2014 1 次提交
  10. 21 3月, 2014 1 次提交
    • M
      net/mlx4: Adapt code for N-Port VF · 449fc488
      Matan Barak 提交于
      Adds support for N-Port VFs, this includes:
      1. Adding support in the wrapped FW command
      	In wrapped commands, we need to verify and convert
      	the slave's port into the real physical port.
      	Furthermore, when sending the response back to the slave,
      	a reverse conversion should be made.
      2. Adjusting sqpn for QP1 para-virtualization
      	The slave assumes that sqpn is used for QP1 communication.
      	If the slave is assigned to a port != (first port), we need
      	to adjust the sqpn that will direct its QP1 packets into the
      	correct endpoint.
      3. Adjusting gid[5] to modify the port for raw ethernet
      	In B0 steering, gid[5] contains the port. It needs
      	to be adjusted into the physical port.
      4. Adjusting number of ports in the query / ports caps in the FW commands
      	When a slave queries the hardware, it needs to view only
      	the physical ports it's assigned to.
      5. Adjusting the sched_qp according to the port number
      	The QP port is encoded in the sched_qp, thus in modify_qp we need
      	to encode the correct port in sched_qp.
      Signed-off-by: NMatan Barak <matanb@mellanox.com>
      Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      449fc488
  11. 13 3月, 2014 3 次提交
  12. 19 1月, 2014 1 次提交
  13. 01 1月, 2014 1 次提交
  14. 08 11月, 2013 1 次提交
  15. 05 11月, 2013 3 次提交
  16. 27 4月, 2013 2 次提交
  17. 12 4月, 2013 1 次提交
  18. 08 3月, 2013 1 次提交
  19. 08 2月, 2013 1 次提交
  20. 01 10月, 2012 1 次提交
  21. 19 7月, 2012 1 次提交
  22. 12 7月, 2012 1 次提交
    • J
      mlx4: Put physical GID and P_Key table sizes in mlx4_phys_caps struct and paravirtualize them · 6634961c
      Jack Morgenstein 提交于
      To allow easy paravirtualization of P_Key and GID table sizes, keep
      paravirtualized sizes in mlx4_dev->caps, but save the actual physical
      sizes from FW in struct: mlx4_dev->phys_cap.
      
      In addition, in SR-IOV mode, do the following:
      
      1. Reduce reported P_Key table size by 1.
         This is done to reserve the highest P_Key index for internal use,
         for declaring an invalid P_Key in P_Key paravirtualization.
         We require a P_Key index which always contain an invalid P_Key
         value for this purpose (i.e., one which cannot be modified by
         the subnet manager).  The way to do this is to reduce the
         P_Key table size reported to the subnet manager by 1, so that
         it will not attempt to access the P_Key at index #127.
      
      2. Paravirtualize the GID table size to 1. Thus, each guest sees
         only a single GID (at its paravirtualized index 0).
      
      In addition, since we are paravirtualizing the GID table size to 1, we
      add paravirtualization of the master GID event here (i.e., we do not
      do ib_dispatch_event() for the GUID change event on the master, since
      its (only) GUID never changes).
      Signed-off-by: NJack Morgenstein <jackm@dev.mellanox.co.il>
      Signed-off-by: NRoland Dreier <roland@purestorage.com>
      6634961c
  23. 08 7月, 2012 2 次提交
    • H
      {NET, IB}/mlx4: Add device managed flow steering firmware API · 0ff1fb65
      Hadar Hen Zion 提交于
      The driver is modified to support three operation modes.
      
      If supported by firmware use the device managed flow steering
      API, that which we call device managed steering mode. Else, if
      the firmware supports the B0 steering mode use it, and finally,
      if none of the above, use the A0 steering mode.
      
      When the steering mode is device managed, the code is modified
      such that L2 based rules set by the mlx4_en driver for Ethernet
      unicast and multicast, and the IB stack multicast attach calls
      done through the mlx4_ib driver are all routed to use the device
      managed API.
      
      When attaching rule using device managed flow steering API,
      the firmware returns a 64 bit registration id, which is to be
      provided during detach.
      
      Currently the firmware is always programmed during HCA initialization
      to use standard L2 hashing. Future work should be done to allow
      configuring the flow-steering hash function with common, non
      proprietary means.
      Signed-off-by: NHadar Hen Zion <hadarh@mellanox.co.il>
      Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0ff1fb65
    • H
      net/mlx4: Set steering mode according to device capabilities · c96d97f4
      Hadar Hen Zion 提交于
      Instead of checking the firmware supported steering mode in various
      places in the code, add a dedicated field in the mlx4 device capabilities
      structure which is written once during the initialization flow and read
      across the code.
      
      This also set the grounds for add new steering modes. Currently two modes
      are supported, and are named after the ConnectX HW versions A0 and B0.
      
      A0 steering uses mac_index, vlan_index and priority to steer traffic
      into pre-defined range of QPs.
      
      B0 steering uses Ethernet L2 hashing rules and is enabled only
      if the firmware supports both unicast and multicast B0 steering,
      
      The current steering modes are relevant for Ethernet traffic only,
      such that Infiniband steering remains untouched.
      Signed-off-by: NHadar Hen Zion <hadarh@mellanox.co.il>
      Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c96d97f4
  24. 07 6月, 2012 1 次提交
    • J
      mlx4_core: Fix setting VL_cap in mlx4_SET_PORT wrapper flow · edc4a67e
      Jack Morgenstein 提交于
      Commit 096335b3 ("mlx4_core: Allow dynamic MTU configuration for
      IB ports") modifies the port VL setting.  This exposes a bug in
      mlx4_common_set_port(), where the VL cap value passed in (inside the
      command mailbox) is incorrectly zeroed-out:
      
      mlx4_SET_PORT modifies the VL_cap field (byte 3 of the mailbox).
      Since the SET_PORT command is paravirtualized on the master as well as
      on the slaves, mlx4_SET_PORT_wrapper() is invoked on the master.  This
      calls mlx4_common_set_port() where mailbox byte 3 gets overwritten by
      code which should only set a single bit in that byte (for the reset
      qkey counter flag) -- but instead overwrites the entire byte.
      
      The result is that when running in SR-IOV mode, the VL_cap will be set
      to zero -- fix this.
      Signed-off-by: NJack Morgenstein <jackm@dev.mellanox.co.il>
      Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com>
      Signed-off-by: NRoland Dreier <roland@purestorage.com>
      edc4a67e
  25. 16 5月, 2012 1 次提交
  26. 05 4月, 2012 1 次提交
  27. 13 3月, 2012 1 次提交
    • O
      mlx4_core: Allow dynamic MTU configuration for IB ports · 096335b3
      Or Gerlitz 提交于
      Set the MTU for IB ports in the driver instead of using the firmware
      default of 2KB (the driver defaults to 4KB).  Allow for dynamic mtu
      configuration through a new, per-port sysfs entry.
      
      Since there's a dependency between the port MTU and the max number of
      HW VLs the port can support, apply a mim/max approach, using a loop
      that goes down from the highest possible number of VLs to the lowest,
      using the firmware return status to know whether the requested number
      of VLs is possible with a given MTU.
      
      For now, as with the dynamic link type change / VPI support, the sysfs
      entry to change the mtu is exposed only when NOT running in SR-IOV
      mode.  To allow changing the MTU for the master in SR-IOV mode,
      primary-function-initiated FLR (Function Level Reset) needs to be
      implemented.
      Signed-off-by: NOr Gerlitz <ogerlitz@mellanox.com>
      Signed-off-by: NRoland Dreier <roland@purestorage.com>
      096335b3
  28. 07 3月, 2012 2 次提交
  29. 15 2月, 2012 1 次提交
  30. 23 1月, 2012 2 次提交
  31. 17 12月, 2011 1 次提交