]> git.baikalelectronics.ru Git - kernel.git/commit
net: page_pool: API cleanup and comments
authorIlias Apalodimas <ilias.apalodimas@linaro.org>
Thu, 20 Feb 2020 07:41:55 +0000 (09:41 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 20 Feb 2020 18:09:25 +0000 (10:09 -0800)
commit59e80254ea04af57b8f37ae57926d0c8b5c58bcb
treec5a4fb4e4bb915ff29b7f65b2d49e8ba651dc1d1
parent0cd76e5f79deeba083370da65704f2f71309b3a0
net: page_pool: API cleanup and comments

Functions starting with __ usually indicate those which are exported,
but should not be called directly. Update some of those declared in the
API and make it more readable.

page_pool_unmap_page() and page_pool_release_page() were doing
exactly the same thing calling __page_pool_clean_page().  Let's
rename __page_pool_clean_page() to page_pool_release_page() and
export it in order to show up on perf logs and get rid of
page_pool_unmap_page().

Finally rename __page_pool_put_page() to page_pool_put_page() since we
can now directly call it from drivers and rename the existing
page_pool_put_page() to page_pool_put_full_page() since they do the same
thing but the latter is trying to sync the full DMA area.

This patch also updates netsec, mvneta and stmmac drivers which use
those functions.

Suggested-by: Jonathan Lemon <jonathan.lemon@gmail.com>
Acked-by: Toke Høiland-Jørgensen <toke@redhat.com>
Acked-by: Jesper Dangaard Brouer <brouer@redhat.com>
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvneta.c
drivers/net/ethernet/socionext/netsec.c
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
include/net/page_pool.h
net/core/page_pool.c
net/core/xdp.c