1. 02 1月, 2017 2 次提交
    • M
      qed*: Change maximal number of queues · e1d32acb
      Mintz, Yuval 提交于
      Today qede requests contexts that would suffice for 64 'whole'
      combined queues [192 meant for 64 rx, tx and xdp tx queues],
      but registers netdev and limits the number of queues based on
      information received by qed. In turn, qed doesn't take context
      into account when informing qede how many queues it can support.
      
      This would lead to a configuration problem in case user tries
      configuring >64 combined queues to interface [or >96 in case
      xdp isn't enabled]. Since we don't have a mangement firware
      that actually provides so many interrupt lines to a single
      device we're currently safe but that's about to change soon.
      
      The new maximum is hence changed:
        - For RoCE devices, the limit would remain 64.
        - For non-RoCE devices, the limit might be higher [depending
          on the actual configuration of the device].
      qed would start enforcing that limit in both scenarios.
      Signed-off-by: NYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e1d32acb
    • M
      qed*: Update to dual-license · e8f1cb50
      Mintz, Yuval 提交于
      Since the submission of the qedr driver, there's inconsistency
      in the licensing of the various qed/qede files - some are GPLv2
      and some are dual-license.
      Since qedr requires dual-license and it's dependent on both,
      we're updating the licensing of all qed/qede source files.
      Signed-off-by: NYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e8f1cb50
  2. 18 12月, 2016 1 次提交
  3. 14 12月, 2016 1 次提交
  4. 06 12月, 2016 1 次提交
  5. 03 12月, 2016 2 次提交
  6. 01 12月, 2016 2 次提交
    • M
      qed*: Handle-based L2-queues. · 3da7a37a
      Mintz, Yuval 提交于
      The driver needs to maintain several FW/HW-indices for each one of
      its queues. Currently, that mapping is done by the QED where it uses
      an rx/tx array of so-called hw-cids, populating them whenever a new
      queue is opened and clearing them upon destruction of said queues.
      
      This maintenance is far from ideal - there's no real reason why
      QED needs to maintain such a data-structure. It becomes even worse
      when considering the fact that the PF's queues and its child VFs' queues
      are all mapped into the same data-structure.
      As a by-product, the set of parameters an interface needs to supply for
      queue APIs is non-trivial, and some of the variables in the API
      structures have different meaning depending on their exact place
      in the configuration flow.
      
      This patch re-organizes the way L2 queues are configured and maintained.
      In short:
        - Required parameters for queue init are now well-defined.
        - Qed would allocate a queue-cid based on parameters.
          Upon initialization success, it would return a handle to caller.
        - Queue-handle would be maintained by entity requesting queue-init,
          not necessarily qed.
        - All further queue-APIs [update, destroy] would use the opaque
          handle as reference for the queue instead of various indices.
      
      The possible owners of such handles:
        - PF queues [qede] - complete handles based on provided configuration.
        - VF queues [qede] - fw-context-less handles, containing only relative
          information; Only the PF-side would need the absolute indices
          for configuration, so they're omitted here.
        - VF queues [qed, PF-side] - complete handles based on VF initialization.
      Signed-off-by: NYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      3da7a37a
    • M
      qed: Optimize qed_chain datapath usage · 6d937acf
      Mintz, Yuval 提交于
      The chain structure and functions are widely used by the qed* modules,
      both for configuration and datapath.
      E.g., qede's Tx has one such chain and its Rx has two.
      
      Currently, the strucutre's fields which are required for datapath
      related functions [produce/consume] are intertwined with fields which
      are required only for configuration purposes [init/destroy/etc.].
      
      This patch re-arranges the chain structure so that all the fields which
      are required for datapath usage could reside in a single cacheline instead
      of the two which are required today.
      Signed-off-by: NYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6d937acf
  7. 11 11月, 2016 2 次提交
  8. 10 11月, 2016 1 次提交
    • M
      qed: Prevent stack corruption on MFW interaction · bb480242
      Mintz, Yuval 提交于
      Driver uses a union for copying data to & from management firmware
      when interacting with it.
      Problem is that the function always copies sizeof(union) while commit
      2edbff8d ("qed: Learn resources from management firmware") is casting
      a union elements which is of smaller size [24-byte instead of 88-bytes].
      
      Also, the union contains some inappropriate elements which increase its
      size [should have been 32-bytes]. While this shouldn't corrupt other
      PF messages to the MFW [as management firmware enforces permissions so
      that each PF is allowed to write only to its own mailbox] we fix this
      here as well.
      
      Fixes: 2edbff8d ("qed: Learn resources from management firmware")
      Signed-off-by: NYuval Mintz <Yuval.Mintz@cavium.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bb480242
  9. 01 11月, 2016 7 次提交
  10. 23 10月, 2016 2 次提交
  11. 19 10月, 2016 2 次提交
  12. 14 10月, 2016 8 次提交
  13. 13 10月, 2016 2 次提交
  14. 04 10月, 2016 6 次提交
  15. 20 9月, 2016 1 次提交