1. 01 8月, 2020 1 次提交
  2. 29 7月, 2020 1 次提交
  3. 24 7月, 2020 1 次提交
  4. 02 7月, 2020 1 次提交
  5. 19 6月, 2020 1 次提交
  6. 31 5月, 2020 2 次提交
  7. 29 5月, 2020 1 次提交
  8. 28 5月, 2020 2 次提交
  9. 23 5月, 2020 3 次提交
    • B
      ice: Implement aRFS · 28bf2672
      Brett Creeley 提交于
      Enable accelerated Receive Flow Steering (aRFS). It is used to steer Rx
      flows to a specific queue. This functionality is triggered by the network
      stack through ndo_rx_flow_steer and requires Flow Director (ntuple on) to
      function.
      
      The fltr_info is used to add/remove/update flow rules in the HW, the
      fltr_state is used to determine what to do with the filter with respect
      to HW and/or SW, and the flow_id is used in co-ordination with the
      network stack.
      
      The work for aRFS is split into two paths: the ndo_rx_flow_steer
      operation and the ice_service_task. The former is where the kernel hands
      us an Rx SKB among other items to setup aRFS and the latter is where
      the driver adds/updates/removes filter rules from HW and updates filter
      state.
      
      In the Rx path the following things can happen:
              1. New aRFS entries are added to the hash table and the state is
                 set to ICE_ARFS_INACTIVE so the filter can be updated in HW
                 by the ice_service_task path.
              2. aRFS entries have their Rx Queue updated if we receive a
                 pre-existing flow_id and the filter state is ICE_ARFS_ACTIVE.
                 The state is set to ICE_ARFS_INACTIVE so the filter can be
                 updated in HW by the ice_service_task path.
              3. aRFS entries marked as ICE_ARFS_TODEL are deleted
      
      In the ice_service_task path the following things can happen:
              1. New aRFS entries marked as ICE_ARFS_INACTIVE are added or
                 updated in HW.
                 and their state is updated to ICE_ARFS_ACTIVE.
              2. aRFS entries are deleted from HW and their state is updated
                 to ICE_ARFS_TODEL.
      Signed-off-by: NBrett Creeley <brett.creeley@intel.com>
      Signed-off-by: NMadhu Chittim <madhu.chittim@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      28bf2672
    • H
      ice: Restore filters following reset · 83af0039
      Henry Tieman 提交于
      Following a reset, Flow Director filters are cleared from the hardware.
      Rebuild the filters using the software structures containing the filter
      rules.
      Signed-off-by: NHenry Tieman <henry.w.tieman@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      83af0039
    • H
      ice: Initialize Flow Director resources · 148beb61
      Henry Tieman 提交于
      Flow Director allows for redirection based on ntuple rules. Rules are
      programmed using the ethtool set-ntuple interface. Supported actions are
      redirect to queue and drop.
      
      Setup the initial framework to process Flow Director filters. Create and
      allocate resources to manage and program filters to the hardware. Filters
      are processed via a sideband interface; a control VSI is created to manage
      communication and process requests through the sideband. Upon allocation of
      resources, update the hardware tables to accept perfect filters.
      Signed-off-by: NHenry Tieman <henry.w.tieman@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      148beb61
  10. 22 5月, 2020 3 次提交
  11. 11 3月, 2020 4 次提交
  12. 16 2月, 2020 4 次提交
    • B
      ice: remove unnecessary fallthrough comments · 752eee06
      Bruce Allan 提交于
      Fallthrough comments are used to explicitly indicate the code is intended
      to flow from one case statement to the next in a switch statement rather
      than break out of the switch statement.  They are only needed when a case
      has one or more statements to execute before falling through to the next
      case, not when there is a list of cases for which the same statement(s)
      should be executed.
      Signed-off-by: NBruce Allan <bruce.w.allan@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      752eee06
    • B
      ice: Fix implicit queue mapping mode in ice_vsi_get_qs · 39066dc5
      Brett Creeley 提交于
      Currently in ice_vsi_get_qs() we set the mapping_mode for Tx and Rx to
      vsi->[tx|rx]_mapping_mode, but the problem is vsi->[tx|rx]_mapping_mode
      have not been set yet. This was working because ICE_VSI_MAP_CONTIG is
      defined to 0. Fix this by being explicit with our mapping mode by
      initializing the Tx and Rx structure's mapping_mode to
      ICE_VSI_MAP_CONTIG and then setting the vsi->[tx|rx]_mapping_mode to the
      [tx|rx]_qs_cfg.mapping_mode values.
      
      Also, only assign the vsi->[tx|rx]_mapping_mode when the queues are
      successfully mapped to the VSI. With this change there was no longer a
      need to initialize the ret variable to 0 so remove that.
      Signed-off-by: NBrett Creeley <brett.creeley@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      39066dc5
    • B
      ice: Add support to enable/disable all Rx queues before waiting · 13a6233b
      Brett Creeley 提交于
      Currently when we enable/disable all Rx queues we do the following
      sequence for each Rx queue and then move to the next queue.
      
      1. Enable/Disable the Rx queue via register write.
      2. Read the configuration register to determine if the Rx queue was
      enabled/disabled successfully.
      
      In some cases enabling/disabling queue 0 fails because of step 2 above.
      Fix this by doing step 1 for all of the Rx queues and then step 2 for
      all of the Rx queues.
      
      Also, there are cases where we enable/disable a single queue (i.e.
      SR-IOV and XDP) so add a new function that does step 1 and 2 above with
      a read flush in between.
      
      This change also required a single Rx queue to be enabled/disabled with
      and without waiting for the change to propagate through hardware. Fix
      this by adding a boolean wait flag to the necessary functions.
      
      Also, add the keywords "one" and "all" to distinguish between
      enabling/disabling a single Rx queue and all Rx queues respectively.
      Signed-off-by: NBrett Creeley <brett.creeley@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      13a6233b
    • B
      ice: Add initial support for QinQ · 42f3efef
      Brett Creeley 提交于
      Allow support for S-Tag + C-Tag VLAN traffic by disabling pruning when
      there are no 0x8100 VLAN interfaces currently created on top of the PF.
      When an 0x8100 VLAN interface is configured, enable pruning and only
      support single and double C-Tag VLAN traffic. If all of the 0x8100
      interfaces that were created on top of the PF are removed via
      ethtool -K <iface> rx-vlan-filter off or via ip tools, then disable
      pruning and allow S-Tag + C-Tag traffic again.
      
      Add VLAN 0 filter by default for the PF. This is because a bridge
      sets the default_pvid to 1, sends the request down to
      ice_vlan_rx_add_vid(), and we never get the request to add VLAN 0 via
      the 8021q module which causes all untagged traffic to be dropped.
      Signed-off-by: NBrett Creeley <brett.creeley@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      42f3efef
  13. 13 2月, 2020 5 次提交
  14. 26 1月, 2020 2 次提交
  15. 25 1月, 2020 1 次提交
  16. 04 1月, 2020 3 次提交
    • M
      ice: Restore interrupt throttle settings after VSI rebuild · 61dc79ce
      Michal Swiatkowski 提交于
      After each rebuild driver deallocates q_vectors, so the interrupt
      throttle rate (ITR) settings get lost.
      
      Create a function to save and restore ITR for each queue. If a user
      increases the number of queues, restore all the previous queue
      settings for each existing queue, and the additional queues will
      get the default setting.
      Signed-off-by: NMichal Swiatkowski <michal.swiatkowski@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      61dc79ce
    • B
      ice: Add code to keep track of current dflt_vsi · fc0f39bc
      Brett Creeley 提交于
      We can't have more than one default VSI so prevent another VSI from
      overwriting the current dflt_vsi. This was achieved by adding the
      following functions:
      
      ice_is_dflt_vsi_in_use()
      - Used to check if the default VSI is already being used.
      
      ice_is_vsi_dflt_vsi()
      - Used to check if VSI passed in is in fact the default VSI.
      
      ice_set_dflt_vsi()
      - Used to set the default VSI via a switch rule
      
      ice_clear_dflt_vsi()
      - Used to clear the default VSI via a switch rule.
      
      Also, there was no need to introduce any locking because all mailbox
      events and synchronization of switch filters for the PF happen in the
      service task.
      Signed-off-by: NBrett Creeley <brett.creeley@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      fc0f39bc
    • B
      ice: Fix VF spoofchk · cd6d6b83
      Brett Creeley 提交于
      There are many things wrong with the function
      ice_set_vf_spoofchk().
      
      1. The VSI being modified is the PF VSI, not the VF VSI.
      2. We are enabling Rx VLAN pruning instead of Tx VLAN anti-spoof.
      3. The spoofchk setting for each VF is not initialized correctly
         or re-initialized correctly on reset.
      
      To fix [1] we need to make sure we are modifying the VF VSI.
      This is done by using the vf->lan_vsi_idx to index into the PF's
      VSI array.
      
      To fix [2] replace setting Rx VLAN pruning in ice_set_vf_spoofchk()
      with setting Tx VLAN anti-spoof.
      
      To Fix [3] we need to make sure the initial VSI settings match what
      is done in ice_set_vf_spoofchk() for spoofchk=on. Also make sure
      this also works for VF reset. This was done by modifying ice_vsi_init()
      to account for the current spoofchk state of the VF VSI.
      
      Because of these changes, Tx VLAN anti-spoof needs to be removed
      from ice_cfg_vlan_pruning(). This is okay for the VF because this
      is now controlled from the admin enabling/disabling spoofchk. For the
      PF, Tx VLAN anti-spoof should not be set. This change requires us to
      call ice_set_vf_spoofchk() when configuring promiscuous mode for
      the VF which requires ice_set_vf_spoofchk() to move in order to prevent
      a forward declaration prototype.
      
      Also, add VLAN 0 by default when allocating a VF since the PF is unaware
      if the guest OS is running the 8021q module. Without this, MDD events will
      trigger on untagged traffic because spoofcheck is enabled by default. Due
      to this change, ignore add/delete messages for VLAN 0 from VIRTCHNL since
      this is added/deleted during VF initialization/teardown respectively and
      should not be modified.
      Signed-off-by: NBrett Creeley <brett.creeley@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      cd6d6b83
  17. 23 11月, 2019 3 次提交
  18. 09 11月, 2019 2 次提交