diff options
author | David S. Miller <davem@davemloft.net> | 2018-08-02 10:55:32 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-08-02 10:55:32 -0700 |
commit | 89b1698c93a9dee043154f33d96bca9964e705f1 (patch) | |
tree | dd9dcb1965baae8edcf0b496aaa6a70609b6fc11 /net/core/xdp.c | |
parent | ffd7ce3cd9c294f1ff49ec02cdbd1bc7cb913db6 (diff) | |
parent | e30cb13c5a09ff5f043a6570c32e49b063bea6a1 (diff) |
Merge ra.kernel.org:/pub/scm/linux/kernel/git/davem/net
The BTF conflicts were simple overlapping changes.
The virtio_net conflict was an overlap of a fix of statistics counter,
happening alongisde a move over to a bonafide statistics structure
rather than counting value on the stack.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core/xdp.c')
-rw-r--r-- | net/core/xdp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/core/xdp.c b/net/core/xdp.c index 57285383ed00..c013b836006b 100644 --- a/net/core/xdp.c +++ b/net/core/xdp.c @@ -348,7 +348,8 @@ static void __xdp_return(void *data, struct xdp_mem_info *mem, bool napi_direct, rcu_read_lock(); /* mem->id is valid, checked in xdp_rxq_info_reg_mem_model() */ xa = rhashtable_lookup(mem_id_ht, &mem->id, mem_id_rht_params); - xa->zc_alloc->free(xa->zc_alloc, handle); + if (!WARN_ON_ONCE(!xa)) + xa->zc_alloc->free(xa->zc_alloc, handle); rcu_read_unlock(); default: /* Not possible, checked in xdp_rxq_info_reg_mem_model() */ |