![]() |
|
Message-ID: <87o6xvixep.fsf@toke.dk> Date: Thu, 20 Mar 2025 15:34:06 +0100 From: Toke Høiland-Jørgensen <toke@...hat.com> To: Yunsheng Lin <linyunsheng@...wei.com>, Yunsheng Lin <yunshenglin0825@...il.com>, "David S. Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>, Jesper Dangaard Brouer <hawk@...nel.org>, Saeed Mahameed <saeedm@...dia.com>, Leon Romanovsky <leon@...nel.org>, Tariq Toukan <tariqt@...dia.com>, Andrew Lunn <andrew+netdev@...n.ch>, Eric Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>, Ilias Apalodimas <ilias.apalodimas@...aro.org>, Simon Horman <horms@...nel.org>, Andrew Morton <akpm@...ux-foundation.org>, Mina Almasry <almasrymina@...gle.com>, Yonglong Liu <liuyonglong@...wei.com>, Pavel Begunkov <asml.silence@...il.com>, Matthew Wilcox <willy@...radead.org>, Robin Murphy <robin.murphy@....com>, IOMMU <iommu@...ts.linux.dev>, segoon@...nwall.com, solar@...nwall.com, kernel-hardening@...ts.openwall.com Cc: netdev@...r.kernel.org, bpf@...r.kernel.org, linux-rdma@...r.kernel.org, linux-mm@...ck.org, Qiuling Ren <qren@...hat.com>, Yuying Ma <yuma@...hat.com> Subject: Re: [PATCH net-next 3/3] page_pool: Track DMA-mapped pages and unmap them when destroying the pool Yunsheng Lin <linyunsheng@...wei.com> writes: > On 2025/3/19 20:18, Toke Høiland-Jørgensen wrote: >>> >>> All I asked is about moving PP_MAGIC_MASK macro into poison.h if you >>> still want to proceed with reusing the page->pp_magic as the masking and >>> the signature to be masked seems reasonable to be in the same file. >> >> Hmm, my thinking was that this would be a lot of irrelevant stuff to put >> into poison.h, but I suppose we could do so if the mm folks don't object :) > > The masking and the signature to be masked is correlated, I am not sure > what you meant by 'irrelevant stuff' here. Well, looking at it again, mostly the XA_LIMIT define, I guess. But I can just leave that in the PP header. > As you seemed to have understood most of my concern about reusing > page->pp_magic, I am not going to argue with you about the uncertainty > of security and complexity of different address layout for different > arches again. > > But I am still think it is not the way forward with the reusing of > page->pp_magic through doing some homework about the 'POISON_POINTER'. > If you still think my idea is complex and still want to proceed with > reusing the space of page->pp_magic, go ahead and let the maintainers > decide if it is worth the security risk and performance degradation. Yeah, thanks for taking the time to go through the implications. On balance, I still believe reusing the bits is a better solution, but it will of course ultimately be up to the maintainers to decide. I will post a v2 of this series with the adjustments we've discussed, and try to outline the tradeoffs and risks involved in the description, and then leave it to the maintainers to decide which approach they want to move forward with. -Toke
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.