Re: [PATCH v3 05/11] iommu: Pass in a viommu pointer to domain_alloc_user op

2024-10-17 Thread Nicolin Chen
On Thu, Oct 17, 2024 at 02:38:55PM -0300, Jason Gunthorpe wrote: > On Thu, Oct 17, 2024 at 10:21:31AM -0700, Nicolin Chen wrote: > > On Thu, Oct 17, 2024 at 01:51:51PM -0300, Jason Gunthorpe wrote: > > > On Wed, Oct 09, 2024 at 09:38:05AM -0700, Nicolin Chen wrote: > > > > With a viommu object wrap

Re: [PATCH v3 05/11] iommu: Pass in a viommu pointer to domain_alloc_user op

2024-10-17 Thread Jason Gunthorpe
On Thu, Oct 17, 2024 at 10:21:31AM -0700, Nicolin Chen wrote: > On Thu, Oct 17, 2024 at 01:51:51PM -0300, Jason Gunthorpe wrote: > > On Wed, Oct 09, 2024 at 09:38:05AM -0700, Nicolin Chen wrote: > > > With a viommu object wrapping a potentially shareable S2 domain, a nested > > > domain should be a

Re: [PATCH v3 05/11] iommu: Pass in a viommu pointer to domain_alloc_user op

2024-10-17 Thread Nicolin Chen
On Thu, Oct 17, 2024 at 01:51:51PM -0300, Jason Gunthorpe wrote: > On Wed, Oct 09, 2024 at 09:38:05AM -0700, Nicolin Chen wrote: > > With a viommu object wrapping a potentially shareable S2 domain, a nested > > domain should be allocated by associating to a viommu instead. > > > > For drivers with

Re: [PATCH v3 05/11] iommu: Pass in a viommu pointer to domain_alloc_user op

2024-10-17 Thread Jason Gunthorpe
On Wed, Oct 09, 2024 at 09:38:05AM -0700, Nicolin Chen wrote: > With a viommu object wrapping a potentially shareable S2 domain, a nested > domain should be allocated by associating to a viommu instead. > > For drivers without a viommu support, keep the parent domain input, which > should be just

[PATCH v3 05/11] iommu: Pass in a viommu pointer to domain_alloc_user op

2024-10-09 Thread Nicolin Chen
With a viommu object wrapping a potentially shareable S2 domain, a nested domain should be allocated by associating to a viommu instead. For drivers without a viommu support, keep the parent domain input, which should be just viommu->hwpt->common.domain otherwise. Signed-off-by: Nicolin Chen ---