linux_dsm_epyc7002/drivers/net/ethernet/netronome/nfp
John Hurley b12c97d45c nfp: flower: fix cb_ident duplicate in indirect block register
Previously the identifier used for indirect block callback registry and
for block rule cb registry (when done via indirect blocks) was the pointer
to the netdev we were interested in receiving updates on. This worked fine
if a single app existed that registered one callback per netdev of
interest. However, if multiple cards are in place and, in turn, multiple
apps, then each app may register the same callback with the same
identifier to both the netdev's indirect block cb list and to a block's cb
list. This can lead to EEXIST errors and/or incorrect cb deletions.

Prevent this conflict by using the app pointer as the identifier for
netdev indirect block cb registry, allowing each app to register a unique
callback per netdev. For block cb registry, the same app may register
multiple cbs to the same block if using TC shared blocks. Instead of the
app, use the pointer to the allocated cb_priv data as the identifier here.
This means that there can be a unique block callback for each app/netdev
combo.

Fixes: 3166dd07a9 ("nfp: flower: offload tunnel decap rules via indirect TC blocks")
Reported-by: Edward Cree <ecree@solarflare.com>
Signed-off-by: John Hurley <john.hurley@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-12-17 23:34:12 -08:00
..
abm nfp: abm: allow to opt-out of RED offload 2018-12-16 12:41:42 -08:00
bpf nfp: bpf: implement jitting of BPF_ALU | BPF_ARSH | BPF_* 2018-12-07 13:30:48 -08:00
flower nfp: flower: fix cb_ident duplicate in indirect block register 2018-12-17 23:34:12 -08:00
nfpcore nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nic nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
Makefile nfp: abm: add cls_u32 offload for simple band classification 2018-11-19 18:53:46 -08:00
nfp_abi.h nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_app_nic.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_app.c nfp: add offloads on representors 2018-11-30 13:30:44 -08:00
nfp_app.h nfp: register a notifier handler in a central location for the device 2018-11-07 11:45:22 -08:00
nfp_asm.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_asm.h nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_devlink.c nfp: devlink port split support for 1x100G CXP NIC 2018-10-15 22:29:55 -07:00
nfp_hwmon.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_main.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_main.h nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_net_common.c nfp: report more info when reconfiguration fails 2018-11-30 13:30:45 -08:00
nfp_net_ctrl.c nfp: add offset to all TLV parsing errors 2018-11-30 13:30:44 -08:00
nfp_net_ctrl.h nfp: add offloads on representors 2018-11-30 13:30:44 -08:00
nfp_net_debugdump.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_net_debugfs.c nfp: convert to DEFINE_SHOW_ATTRIBUTE 2018-12-03 17:33:38 -08:00
nfp_net_ethtool.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_net_main.c nfp: pass ctrl_bar pointer to nfp_net_alloc 2018-11-08 20:48:00 -08:00
nfp_net_repr.c nfp: add offloads on representors 2018-11-30 13:30:44 -08:00
nfp_net_repr.h nfp: add offloads on representors 2018-11-30 13:30:44 -08:00
nfp_net_sriov.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_net_sriov.h nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_net.h nfp: report more info when reconfiguration fails 2018-11-30 13:30:45 -08:00
nfp_netvf_main.c nfp: pass ctrl_bar pointer to nfp_net_alloc 2018-11-08 20:48:00 -08:00
nfp_port.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_port.h nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00
nfp_shared_buf.c nfp: replace long license headers with SPDX 2018-10-11 12:16:21 -07:00