Re: [PATCH net-next v1 01/11] net: Get skb fragment addresses through netmem
From: Björn Töpel
Date: Mon Nov 16 2026 - 09:31:42 EST
Jakub Kicinski <kuba@xxxxxxxxxx> writes:
> On Tue, 10 Nov 2026 11:20:22 +0100 Björn Töpel wrote:
>> skb_frag_address() goes through struct page, so a net_iov never has an
>> address. Only unreadable memory should lack one: XDP and BPF read
>> fragments through this helper, and AF_XDP UMEM will back readable
>> net_iovs. netmem_address() also returns NULL, not a bogus pointer, for
>> an unmapped highmem page.
>>
>> Generic code needs the size of a net_iov to find its address, so keep
>> it in struct net_iov_area instead of the devmem binding.
>
> IIRC netmem is supposed to be used for frags and memory CPU never needs
> to access.
netmem covers pages too, and netmem.rst already allows readable net_iovs
("Decouple net_iov from unreadability"); the in-tree ones just happen to
be unreadable.
> This patch looks odd. I haven't read the rest of the series yet but at
> the very least commit message should explain why this aberration is
> needed / correct.
I'll expand the wording in the commit message.