Re: [PATCH v6 0/4] Add larger page size support for USB audio offload path

From: Wesley Cheng

Date: Wed Nov 18 2026 - 17:30:11 EST




On 11/17/2026 1:59 AM, Mathias Nyman wrote:
Hi



Hi Mathias,

Was wondering if this design looked a bit more acceptable?  Was able to figure out a way to achieve what you had suggested earlier mitigating the dma free problem I mentioned in my previous email.  If there are any issues w/ this please let me know.

Thanks
Wesley Cheng

Big picture looks good
I got stuck on the "no_pool_rings[EP_CTX_PER_DEV]" solution in [PATCH v6 2/4].

It reveals and reminds me of how poorly designed existing xhci_free_dev() is.

I tried to quickly fix that fist by 'unlinking' vdev from xhci->devs[]
inside the lock, preventing it from being dereferenced based on slot_id
somewhere else, and then free it without the lock.

I ended up with a huge mess that rewrites vdev free/allocation,
slot enable/disable, xhci_discover_or_reset_device() and xhci_resume().

Seems like best solution for now is to add "no_pool_rings[]" to support the
larger page size, and then later rework the vdev allocation/free and
slot enabling/disabling. I'll take a look at the details of the series.

I also have another sideband change attempting to fix the use-after-free
stale vdev pointer in sideband. It basically swaps vdev to udev.
I'll post it on the list. Let me know your thoughts on it.

Sure, I assume you're talking about:
https://lore.kernel.org/all/20261118125109.1429538-1-mathias.nyman@xxxxxxxxxxxxxxx/

If so, let me look it over, pull it into my branch and test it out if it looks good. I wasn't able to reliably reproduce the issue that Lianqin initially reported, so I'll see if I can figure out a way to exercise that call path.

Thanks
Wesley Cheng