On Tue, Jan 31, 2023 at 08:58:02AM -0800, Steve Sistare wrote: > Fix bugs in the interfaces that allow the underlying memory object of an > iova range to be mapped in a new address space. They allow userland to > indefinitely block vfio mediated device kernel threads, and do not > propagate the locked_vm count to a new mm. Also fix a pre-existing bug > that allows locked_vm underflow. > > The fixes impose restrictions that eliminate waiting conditions, so > revert the dead code: > commit 898b9eaeb3fe ("vfio/type1: block on invalid vaddr") > commit 487ace134053 ("vfio/type1: implement notify callback") > commit ec5e32940cc9 ("vfio: iommu driver notify callback") I would still rather we delete this API. Something that doesn't work with iommufd, and doesn't work with mdevs doesn't seem like it should be in the kernel. But it is up to Alex, and the code looks fine: Reviewed-by: Jason Gunthorpe <jgg@xxxxxxxxxx> Jason