]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net: make page_pool_ref_netmem work with net iovs
authorPavel Begunkov <asml.silence@gmail.com>
Wed, 8 Jan 2025 22:06:22 +0000 (14:06 -0800)
committerJakub Kicinski <kuba@kernel.org>
Thu, 16 Jan 2025 02:44:30 +0000 (18:44 -0800)
commitcbc16bceea784210d585a42ac9f8f10ce62b300e
tree31b871fdb0ad99bf19a11597b183794ecb245845
parent6be7aca91009865d8c2b73589270224a6b6e67ab
net: make page_pool_ref_netmem work with net iovs

page_pool_ref_netmem() should work with either netmem representation, but
currently it casts to a page with netmem_to_page(), which will fail with
net iovs. Use netmem_get_pp_ref_count_ref() instead.

Fixes: 8ab79ed50cf1 ("page_pool: devmem support")
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: David Wei <dw@davidwei.uk>
Link: https://lore.kernel.org/20250108220644.3528845-2-dw@davidwei.uk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
include/net/page_pool/helpers.h