Subject: Re: [RFC net] net: make page pool stall netdev unregistration to avoid IOMMU crashes

From: Jakub Kicinski <[email-masked]>
Date: Wed, 7 Aug 2024 07:29:08 -0700

On Wed, 7 Aug 2024 19:00:35 +0800 Yunsheng Lin wrote:
> > Note that page pool pages may last forever, we have seen it happen
> > e.g. when application leaks a socket and page is stuck in its rcv queue.  
> 
> We saw some page_pool pages might last forever too, but were not sure
> if it was the same reason as above? Are there some cmds/ways to debug
> if a application leaks a socket and page is stuck in its rcv queue?

I used drgn to scan all sockets to find the page.

> > Hopefully this is fine in this particular case, as we will only stall
> > unregistering of devices which want the page pool to manage the DMA
> > mapping for them, i.e. HW backed netdevs. And obviously keeping
> > the netdev around is preferable to a crash.