diff options
| author | Nirmoy Das <nirmoyd@nvidia.com> | 2026-10-14 06:36:32 -0700 |
|---|---|---|
| committer | Jason Gunthorpe <jgg@nvidia.com> | 2026-10-14 21:16:12 -0300 |
| commit | 440ca8a4b69f40088065b9e05ef11373292a254e (patch) | |
| tree | 314a626db22edbc514879d16cdc8209715fba246 /scripts/basic/split-include.c | |
| parent | 769f2cd9226c96619d77fa16af84de74cae41b6b (diff) | |
| download | linux-next-440ca8a4b69f40088065b9e05ef11373292a254e.tar.gz linux-next-440ca8a4b69f40088065b9e05ef11373292a254e.zip | |
iommufd: Fix event queue release use-after-free
iommufd_eventq_fops_release() drops the file's users reference before
reading eventq->ictx. Once that reference is dropped, IOMMU_DESTROY in
another thread can remove and free the event queue, so the later load
accesses freed memory.
Read ictx while the users reference still pins the event queue, then
drop the reference and put the saved context. The context reference
taken by iommufd_eventq_init() keeps ictx valid until the put. Fault and
vEVENTQ file descriptors share this release path.
Fixes: 07838f7fd529 ("iommufd: Add iommufd fault object")
Cc: stable@vger.kernel.org
Assisted-by: LLM, Specula
Signed-off-by: Nirmoy Das <nirmoyd@nvidia.com>
Link: https://patch.msgid.link/20261014133632.3440297-1-nirmoyd@nvidia.com
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'scripts/basic/split-include.c')
0 files changed, 0 insertions, 0 deletions
