1. 15 4月, 2021 3 次提交
    • J
      ice: refactor ITR data structures · d59684a0
      Jesse Brandeburg 提交于
      Use a dedicated bitfield in order to both increase
      the amount of checking around the length of ITR writes
      as well as simplify the checks of dynamic mode.
      
      Basically unpack the "high bit means dynamic" logic
      into bitfields.
      
      Also, remove some unused ITR defines.
      Signed-off-by: NJesse Brandeburg <jesse.brandeburg@intel.com>
      Tested-by: NTony Brelinski <tonyx.brelinski@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      d59684a0
    • J
      ice: manage interrupts during poll exit · b7306b42
      Jesse Brandeburg 提交于
      The driver would occasionally miss that there were outstanding
      descriptors to clean when exiting busy/napi poll. This issue has
      been in the code since the introduction of the ice driver.
      
      Attempt to "catch" any remaining work by triggering a software
      interrupt when exiting napi poll or busy-poll. This will not
      cause extra interrupts in the case of normal execution.
      
      This issue was found when running sfnt-pingpong, with busy
      poll enabled, and typically with larger I/O sizes like > 8192,
      the program would occasionally report > 1 second maximums
      to complete a ping pong.
      Signed-off-by: NJesse Brandeburg <jesse.brandeburg@intel.com>
      Tested-by: NTony Brelinski <tonyx.brelinski@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      b7306b42
    • J
      ice: replace custom AIM algorithm with kernel's DIM library · cdf1f1f1
      Jacob Keller 提交于
      The ice driver has support for adaptive interrupt moderation, an
      algorithm for tuning the interrupt rate dynamically. This algorithm
      is based on various assumptions about ring size, socket buffer size,
      link speed, SKB overhead, ethernet frame overhead and more.
      
      The Linux kernel has support for a dynamic interrupt moderation
      algorithm known as "dimlib". Replace the custom driver-specific
      implementation of dynamic interrupt moderation with the kernel's
      algorithm.
      
      The Intel hardware has a different hardware implementation than the
      originators of the dimlib code had to work with, which requires the
      driver to use a slightly different set of inputs for the actual
      moderation values, while getting all the advice from dimlib of
      better/worse, shift left or right.
      
      The change made for this implementation is to use a pair of values
      for each of the 5 "slots" that the dimlib moderation expects, and
      the driver will program those pairs when dimlib recommends a slot to
      use. The currently implementation uses two tables, one for receive
      and one for transmit, and the pairs of values in each slot set the
      maximum delay of an interrupt and a maximum number of interrupts per
      second (both expressed in microseconds).
      
      There are two separate kinds of bugs fixed by using DIMLIB, one is
      UDP single stream send was too slow, and the other is that 8K
      ping-pong was going to the most aggressive moderation and has much
      too high latency.
      
      The overall result of using DIMLIB is that we meet or exceed our
      performance expectations set based on the old algorithm.
      Co-developed-by: NJesse Brandeburg <jesse.brandeburg@intel.com>
      Signed-off-by: NJesse Brandeburg <jesse.brandeburg@intel.com>
      Signed-off-by: NJacob Keller <jacob.e.keller@intel.com>
      Tested-by: NTony Brelinski <tonyx.brelinski@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      cdf1f1f1
  2. 01 4月, 2021 1 次提交
  3. 23 3月, 2021 1 次提交
  4. 18 3月, 2021 1 次提交
  5. 12 3月, 2021 1 次提交
  6. 13 2月, 2021 3 次提交
  7. 09 2月, 2021 2 次提交
  8. 05 2月, 2021 1 次提交
  9. 27 1月, 2021 1 次提交
    • N
      ice: Implement flow for IPv6 next header (extension header) · 1b0b0b58
      Nick Nunley 提交于
      This patch is based on a similar change to i40e by Slawomir Laba:
      "i40e: Implement flow for IPv6 next header (extension header)".
      
      When a packet contains an IPv6 header with next header which is
      an extension header and not a protocol one, the kernel function
      skb_transport_header called with such sk_buff will return a
      pointer to the extension header and not to the TCP one.
      
      The above explained call caused a problem with packet processing
      for skb with encapsulation for tunnel with ICE_TX_CTX_EIPT_IPV6.
      The extension header was not skipped at all.
      
      The ipv6_skip_exthdr function does check if next header of the IPV6
      header is an extension header and doesn't modify the l4_proto pointer
      if it points to a protocol header value so its safe to omit the
      comparison of exthdr and l4.hdr pointers. The ipv6_skip_exthdr can
      return value -1. This means that the skipping process failed
      and there is something wrong with the packet so it will be dropped.
      
      Fixes: a4e82a81 ("ice: Add support for tunnel offloads")
      Signed-off-by: NNick Nunley <nicholas.d.nunley@intel.com>
      Tested-by: NTony Brelinski <tonyx.brelinski@intel.com>
      Signed-off-by: NTony Nguyen <anthony.l.nguyen@intel.com>
      1b0b0b58
  10. 09 1月, 2021 2 次提交
  11. 10 12月, 2020 1 次提交
  12. 01 12月, 2020 1 次提交
  13. 01 9月, 2020 1 次提交
  14. 27 8月, 2020 1 次提交
  15. 01 8月, 2020 3 次提交
  16. 29 7月, 2020 1 次提交
  17. 31 5月, 2020 1 次提交
  18. 23 5月, 2020 2 次提交
  19. 22 5月, 2020 3 次提交
  20. 15 5月, 2020 1 次提交
    • J
      ice: Add XDP frame size to driver · d4ecdbf7
      Jesper Dangaard Brouer 提交于
      This driver uses different memory models depending on PAGE_SIZE at
      compile time. For PAGE_SIZE 4K it uses page splitting, meaning for
      normal MTU frame size is 2048 bytes (and headroom 192 bytes). For
      larger MTUs the driver still use page splitting, by allocating
      order-1 pages (8192 bytes) for RX frames. For PAGE_SIZE larger than
      4K, driver instead advance its rx_buffer->page_offset with the frame
      size "truesize".
      
      For XDP frame size calculations, this mean that in PAGE_SIZE larger
      than 4K mode the frame_sz change on a per packet basis. For the page
      split 4K PAGE_SIZE mode, xdp.frame_sz is more constant and can be
      updated once outside the main NAPI loop.
      
      The default setting in the driver uses build_skb(), which provides
      the necessary headroom and tailroom for XDP-redirect in RX-frame
      (in both modes).
      
      There is one complication, which is legacy-rx mode (configurable via
      ethtool priv-flags). There are zero headroom in this mode, which is a
      requirement for XDP-redirect to work. The conversion to xdp_frame
      (convert_to_xdp_frame) will detect this insufficient space, and
      xdp_do_redirect() call will fail. This is deemed acceptable, as it
      allows other XDP actions to still work in legacy-mode. In
      legacy-mode + larger PAGE_SIZE due to lacking tailroom, we also
      accept that xdp_adjust_tail shrink doesn't work.
      Signed-off-by: NJesper Dangaard Brouer <brouer@redhat.com>
      Signed-off-by: NAlexei Starovoitov <ast@kernel.org>
      Cc: intel-wired-lan@lists.osuosl.org
      Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
      Cc: Alexander Duyck <alexander.duyck@gmail.com>
      Link: https://lore.kernel.org/bpf/158945347002.97035.328088795813704587.stgit@firesoul
      d4ecdbf7
  21. 16 2月, 2020 2 次提交
  22. 13 2月, 2020 2 次提交
  23. 04 1月, 2020 2 次提交
  24. 07 11月, 2019 1 次提交
  25. 05 11月, 2019 2 次提交