1. 10 5月, 2018 1 次提交
    • J
      nfp: bpf: allow zero-length capabilities · 26aeb9da
      Jakub Kicinski 提交于
      Some BPF capabilities carry no value, they simply indicate feature
      is present.  Our capability parsing loop will exit early if last
      capability is zero-length because it's looking for more than 8 bytes
      of data (8B is our TLV header length).  Allow the last capability to
      be zero-length.
      
      This bug would lead to driver failing to probe with the following error
      if the last capability FW advertises is zero-length:
      
          nfp: BPF capabilities left after parsing, parsed:92 total length:100
          nfp: invalid BPF capabilities at offset:92
      
      Note the "parsed" and "length" values are 8 apart.
      
      No shipping FW runs into this issue, but we can't guarantee that will
      remain the case.
      
      Fixes: 77a844ee ("nfp: bpf: prepare for parsing BPF FW capabilities")
      Signed-off-by: NJakub Kicinski <jakub.kicinski@netronome.com>
      Reviewed-by: NQuentin Monnet <quentin.monnet@netronome.com>
      Signed-off-by: NDaniel Borkmann <daniel@iogearbox.net>
      26aeb9da
  2. 30 3月, 2018 1 次提交
  3. 29 3月, 2018 3 次提交
  4. 08 2月, 2018 2 次提交
  5. 26 1月, 2018 1 次提交
  6. 23 1月, 2018 2 次提交
  7. 20 1月, 2018 2 次提交
  8. 15 1月, 2018 4 次提交
  9. 10 1月, 2018 4 次提交
  10. 28 12月, 2017 1 次提交
  11. 21 12月, 2017 2 次提交
    • J
      nfp: bpf: keep track of the offloaded program · d3f89b98
      Jakub Kicinski 提交于
      After TC offloads were converted to callbacks we have no choice
      but keep track of the offloaded filter in the driver.
      
      The check for nn->dp.bpf_offload_xdp was a stop gap solution
      to make sure failed TC offload won't disable XDP, it's no longer
      necessary.  nfp_net_bpf_offload() will return -EBUSY on
      TC vs XDP conflicts.
      
      Fixes: 3f7889c4 ("net: sched: cls_bpf: call block callbacks for offload")
      Signed-off-by: NJakub Kicinski <jakub.kicinski@netronome.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d3f89b98
    • J
      cls_bpf: fix offload assumptions after callback conversion · 102740bd
      Jakub Kicinski 提交于
      cls_bpf used to take care of tracking what offload state a filter
      is in, i.e. it would track if offload request succeeded or not.
      This information would then be used to issue correct requests to
      the driver, e.g. requests for statistics only on offloaded filters,
      removing only filters which were offloaded, using add instead of
      replace if previous filter was not added etc.
      
      This tracking of offload state no longer functions with the new
      callback infrastructure.  There could be multiple entities trying
      to offload the same filter.
      
      Throw out all the tracking and corresponding commands and simply
      pass to the drivers both old and new bpf program.  Drivers will
      have to deal with offload state tracking by themselves.
      
      Fixes: 3f7889c4 ("net: sched: cls_bpf: call block callbacks for offload")
      Signed-off-by: NJakub Kicinski <jakub.kicinski@netronome.com>
      Acked-by: NJiri Pirko <jiri@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      102740bd
  12. 16 12月, 2017 1 次提交
  13. 15 12月, 2017 3 次提交
  14. 03 12月, 2017 1 次提交
  15. 05 11月, 2017 4 次提交
  16. 02 11月, 2017 2 次提交
  17. 27 10月, 2017 1 次提交
  18. 21 10月, 2017 2 次提交
  19. 15 10月, 2017 1 次提交
  20. 10 10月, 2017 1 次提交
  21. 04 9月, 2017 1 次提交