]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
thunderx: enable page recycling for non-XDP case
authorDean Nelson <dnelson@redhat.com>
Tue, 26 Mar 2019 15:53:19 +0000 (11:53 -0400)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Wed, 14 Aug 2019 09:18:49 +0000 (11:18 +0200)
commit29645f2ddf769ec42cb3ae4f9f08b6db66fdf3f1
tree9a720686eecd02b4829e932162795f43341a94b3
parent736205f8413739f18f901b41cb3de3e6d8ca2698
thunderx: enable page recycling for non-XDP case

BugLink: https://bugs.launchpad.net/bugs/1838116
[ Upstream commit b3e208069477588c06f4d5d986164b435bb06e6d ]

Commit 773225388dae15e72790 ("net: thunderx: Optimize page recycling for XDP")
added code to nicvf_alloc_page() that inadvertently disables receive buffer
page recycling for the non-XDP case by always NULL'ng the page pointer.

This patch corrects two if-conditionals to allow for the recycling of non-XDP
mode pages by only setting the page pointer to NULL when the page is not ready
for recycling.

Fixes: 773225388dae ("net: thunderx: Optimize page recycling for XDP")
Signed-off-by: Dean Nelson <dnelson@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/net/ethernet/cavium/thunder/nicvf_queues.c