[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d08b9abf-9b42-47ae-9ec7-36b59931ffb5@gmail.com>
Date: Tue, 13 May 2025 13:58:10 +0100
From: Pavel Begunkov <asml.silence@...il.com>
To: Byungchul Park <byungchul@...com>, Mina Almasry <almasrymina@...gle.com>
Cc: willy@...radead.org, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-mm@...ck.org, kernel_team@...ynix.com,
kuba@...nel.org, ilias.apalodimas@...aro.org, harry.yoo@...cle.com,
hawk@...nel.org, akpm@...ux-foundation.org, ast@...nel.org,
daniel@...earbox.net, davem@...emloft.net, john.fastabend@...il.com,
andrew+netdev@...n.ch, edumazet@...gle.com, pabeni@...hat.com,
vishal.moola@...il.com
Subject: Re: [RFC 01/19] netmem: rename struct net_iov to struct netmem_desc
On 5/13/25 03:00, Byungchul Park wrote:
> On Mon, May 12, 2025 at 12:14:13PM -0700, Mina Almasry wrote:
>> On Mon, May 12, 2025 at 6:29 AM Byungchul Park <byungchul@...com> wrote:
>>>
>>> On Mon, May 12, 2025 at 02:11:13PM +0100, Pavel Begunkov wrote:
>>>> On 5/9/25 12:51, Byungchul Park wrote:
>>>>> To simplify struct page, the page pool members of struct page should be
>>>>> moved to other, allowing these members to be removed from struct page.
>>>>>
>>>>> Reuse struct net_iov for also system memory, that already mirrored the
>>>>> page pool members.
>>>>>
>>>>> Signed-off-by: Byungchul Park <byungchul@...com>
>>>>> ---
>>>>> include/linux/skbuff.h | 4 +--
>>>>> include/net/netmem.h | 20 ++++++------
>>>>> include/net/page_pool/memory_provider.h | 6 ++--
>>>>> io_uring/zcrx.c | 42 ++++++++++++-------------
>>>>
>>>> You're unnecessarily complicating it for yourself. It'll certainly
>>>> conflict with changes in the io_uring tree, and hence it can't
>>>> be taken normally through the net tree.
>>>>
>>>> Why are you renaming it in the first place? If there are good
>>>
>>> It's because the struct should be used for not only io vetor things but
>>> also system memory. Current network code uses struct page as system
>>> memory descriptor but struct page fields for page pool will be gone.
>>>
>>> So I had to reuse struct net_iov and I thought renaming it made more
>>> sense. It'd be welcome if you have better idea.
>>>
>>
>> As I said in another thread, struct page should not embed struct
>
> I don't understand here. Can you explain more? Do you mean do not use
> place holder?
I assume this:
struct netmem_desc {
...
};
struct net_iov {
netmem_desc desc;
};
struct page {
union {
// eventually will go away
netmem_desc desc;
...
};
};
And to avoid conflicts with io_uring, you can send something like the
following to the net tree, and finish the io_uring conversion later.
struct net_iov {
struct_group_tagged(netmem_desc, desc,
...
);
};
--
Pavel Begunkov
Powered by blists - more mailing lists