iopt_release_pages() calls dma_buf_unpin() without taking that lock,
so every iommufd_ioas_destroy()/iommufd_ioas_unmap() that releases
the last reference on a DMABUF-backed iopt_pages triggers a WARN.
This was hit while running tools/testing/selftests/iommu/iommufd:
WARNING:drivers/dma-buf/dma-buf.c:1137 at dma_buf_unpin+0x62/0x70RIP: 0010:dma_buf_unpin+0x62/0x70Call Trace:<TASK>dma_buf_unpin+0x62/0x70iopt_release_pages+0xe4/0x190iopt_unmap_iova_range+0x1c7/0x290iopt_unmap_all+0x1a/0x30iommufd_ioas_destroy+0x1d/0x50iommufd_fops_release+0x93/0x150__fput+0xfc/0x2c0__x64_sys_close+0x3d/0x80do_syscall_64+0x65/0x180</TASK>
Take the dma_resv lock around dma_buf_unpin() in iopt_release_pages(),
matching the iopt_map_dmabuf() convention. dma_buf_detach() acquires the
reservation lock internally, so it must remain outside the locked region.