[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC v3 18/18] vfio/as: Allow the selection of a given iommu backend
From: |
Eric Auger |
Subject: |
Re: [RFC v3 18/18] vfio/as: Allow the selection of a given iommu backend |
Date: |
Fri, 3 Feb 2023 18:57:02 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.1 |
Hi Jason,
On 2/3/23 13:51, Jason Gunthorpe wrote:
> On Tue, Jan 31, 2023 at 09:53:05PM +0100, Eric Auger wrote:
>> Now we support two types of iommu backends, let's add the capability
>> to select one of them. This depends on whether an iommufd object has
>> been linked with the vfio-pci device:
>>
>> if the user wants to use the legacy backend, it shall not
>> link the vfio-pci device with any iommufd object:
>>
>> -device vfio-pci,host=0000:02:00.0
>>
>> This is called the legacy mode/backend.
>>
>> If the user wants to use the iommufd backend (/dev/iommu) it
>> shall pass an iommufd object id in the vfio-pci device options:
>>
>> -object iommufd,id=iommufd0
>> -device vfio-pci,host=0000:02:00.0,iommufd=iommufd0
>>
>> Note the /dev/iommu device may have been pre-opened by a
>> management tool such as libvirt. This mode is no more considered
>> for the legacy backend. So let's remove the "TODO" comment.
> The vfio cdev should also be pre-openable like iommufd?
where does the requirement come from?
Thanks
Eric
>
> Jason
>