diff options
author | Jakub Kicinski <kuba@kernel.org> | 2024-02-23 02:24:56 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-02-23 02:29:26 +0300 |
commit | fecc51559a844b7f74119159c3cdb25b80b4e2c6 (patch) | |
tree | 2cf1e49810eb0c58e552f722cc2ab2742e62cf43 /drivers/net/ethernet/broadcom/asp2/bcmasp.c | |
parent | 0fb848d1a41e0d3895cb157810862db6046063dd (diff) | |
parent | 6714ebb922ab15a209dfc3c1ed29d4bb0abc9f02 (diff) | |
download | linux-fecc51559a844b7f74119159c3cdb25b80b4e2c6.tar.xz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Cross-merge networking fixes after downstream PR.
Conflicts:
net/ipv4/udp.c
f796feabb9f5 ("udp: add local "peek offset enabled" flag")
56667da7399e ("net: implement lockless setsockopt(SO_PEEK_OFF)")
Adjacent changes:
net/unix/garbage.c
aa82ac51d633 ("af_unix: Drop oob_skb ref before purging queue in GC.")
11498715f266 ("af_unix: Remove io_uring code for GC.")
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/broadcom/asp2/bcmasp.c')
-rw-r--r-- | drivers/net/ethernet/broadcom/asp2/bcmasp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/ethernet/broadcom/asp2/bcmasp.c b/drivers/net/ethernet/broadcom/asp2/bcmasp.c index 29b04a274d07..80245c65cc90 100644 --- a/drivers/net/ethernet/broadcom/asp2/bcmasp.c +++ b/drivers/net/ethernet/broadcom/asp2/bcmasp.c @@ -535,9 +535,6 @@ int bcmasp_netfilt_get_all_active(struct bcmasp_intf *intf, u32 *rule_locs, int j = 0, i; for (i = 0; i < NUM_NET_FILTERS; i++) { - if (j == *rule_cnt) - return -EMSGSIZE; - if (!priv->net_filters[i].claimed || priv->net_filters[i].port != intf->port) continue; @@ -547,6 +544,9 @@ int bcmasp_netfilt_get_all_active(struct bcmasp_intf *intf, u32 *rule_locs, priv->net_filters[i - 1].wake_filter) continue; + if (j == *rule_cnt) + return -EMSGSIZE; + rule_locs[j++] = priv->net_filters[i].fs.location; } |