diff options
author | Matteo Croce <mcroce@microsoft.com> | 2020-07-07 16:19:13 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-07 23:03:21 +0300 |
commit | 4e48978cd28ce51945c08650e5c5502ca41e1fcc (patch) | |
tree | 5b5039830e3a61daa0590688ae25f8069a323470 /net/ipv4 | |
parent | b416268b7a819c0508ed0dc81461e513b110f2ac (diff) | |
download | linux-4e48978cd28ce51945c08650e5c5502ca41e1fcc.tar.xz |
mvpp2: fix pointer check
priv->page_pool is an array, so comparing against it will always return true.
Do a meaningful check by checking priv->page_pool[0] instead.
While at it, clear the page_pool pointers on deallocation, or when an
allocation error happens during init.
Reported-by: Colin Ian King <colin.king@canonical.com>
Fixes: c2d6fe6163de ("mvpp2: XDP TX support")
Signed-off-by: Matteo Croce <mcroce@microsoft.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
0 files changed, 0 insertions, 0 deletions