Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-18 Thread Cédric Le Goater
On 7/18/24 15:47, Joao Martins wrote: On 17/07/2024 10:31, Joao Martins wrote: On 17/07/2024 10:28, Cédric Le Goater wrote: @@ -224,6 +300,11 @@ static void iommufd_cdev_detach_container(VFIODevice *vbasedev,   {   Error *err = NULL; +    if (vbasedev->hwpt) { +    iommufd_cdev_aut

RE: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-18 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >creation > >On 18/07/2024 08:44, Duan, Zhenzhong wrote: >>>>>> If existing hwpt doesn't support dirty tracking. >>>>>>

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-18 Thread Joao Martins
On 17/07/2024 10:31, Joao Martins wrote: > On 17/07/2024 10:28, Cédric Le Goater wrote: @@ -224,6 +300,11 @@ static void > iommufd_cdev_detach_container(VFIODevice *vbasedev,   {   Error *err = NULL; +    if (vbasedev->hwpt) { +    i

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-18 Thread Joao Martins
On 18/07/2024 08:44, Duan, Zhenzhong wrote: > If existing hwpt doesn't support dirty tracking. > Another device supporting dirty tracking attaches to that hwpt, what >> will happen? > Hmm, It succeeds as there's no incompatbility. At the very least I plan on blocking

RE: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-18 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >creation > >On 17/07/2024 11:05, Duan, Zhenzhong wrote: >>> -Original Message- >>> From: Joao Martins >>> Subject: Re:

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Joao Martins
On 17/07/2024 11:05, Duan, Zhenzhong wrote: >> -Original Message- >> From: Joao Martins >> Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >> creation >> >> On 17/07/2024 03:18, Duan, Zhenzhong wrote: >>> >>> &

RE: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >creation > >On 17/07/2024 03:18, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >>> From: Joao Martins >>&g

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Joao Martins
On 17/07/2024 10:48, Duan, Zhenzhong wrote: > > >> -Original Message- >> From: Joao Martins >> Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >> creation >> >> On 17/07/2024 03:52, Duan, Zhenzhong wrote: >>> >>

RE: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >creation > >On 17/07/2024 03:52, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >>> From: Joao Martins >>> S

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Joao Martins
On 17/07/2024 10:28, Cédric Le Goater wrote: >>> @@ -224,6 +300,11 @@ static void iommufd_cdev_detach_container(VFIODevice *vbasedev, >>>   { >>>   Error *err = NULL; >>> >>> +    if (vbasedev->hwpt) { >>> +    iommufd_cdev_autodomains_put(vbasedev, container);

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Cédric Le Goater
On 7/17/24 11:09, Joao Martins wrote: On 17/07/2024 03:52, Duan, Zhenzhong wrote: -Original Message- From: Joao Martins Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation On 16/07/2024 17:44, Joao Martins wrote: On 16/07/2024 17:04, Eric Auger wrote: Hi

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Joao Martins
On 17/07/2024 03:52, Duan, Zhenzhong wrote: > > >> -Original Message- >> From: Joao Martins >> Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >> creation >> >> On 16/07/2024 17:44, Joao Martins wrote: >>>

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-17 Thread Joao Martins
On 17/07/2024 03:18, Duan, Zhenzhong wrote: > > >> -Original Message- >> From: Joao Martins >> Subject: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation >> >> There's generally two modes of operation for IOMMUFD: >> >> * The simple user API which intends to perform relativel

RE: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Subject: Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain >creation > >On 16/07/2024 17:44, Joao Martins wrote: >> On 16/07/2024 17:04, Eric Auger wrote: >>> Hi Joao, >>> >>> On 7/12/2

RE: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Subject: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation > >There's generally two modes of operation for IOMMUFD: > >* The simple user API which intends to perform relatively simple things >with IOMMUs e.g. DPDK. It generally create

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Eric Auger
On 7/16/24 18:44, Joao Martins wrote: > On 16/07/2024 17:04, Eric Auger wrote: >> Hi Joao, >> >> On 7/12/24 13:46, Joao Martins wrote: >>> There's generally two modes of operation for IOMMUFD: >>> >>> * The simple user API which intends to perform relatively simple things >>> with IOMMUs e.g. DP

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Joao Martins
On 16/07/2024 17:44, Joao Martins wrote: > On 16/07/2024 17:04, Eric Auger wrote: >> Hi Joao, >> >> On 7/12/24 13:46, Joao Martins wrote: >>> There's generally two modes of operation for IOMMUFD: >>> >>> * The simple user API which intends to perform relatively simple things >>> with IOMMUs e.g. DP

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Joao Martins
On 16/07/2024 17:04, Eric Auger wrote: > Hi Joao, > > On 7/12/24 13:46, Joao Martins wrote: >> There's generally two modes of operation for IOMMUFD: >> >> * The simple user API which intends to perform relatively simple things >> with IOMMUs e.g. DPDK. It generally creates an IOAS and attach to VF

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Eric Auger
Hi Joao, On 7/12/24 13:46, Joao Martins wrote: > There's generally two modes of operation for IOMMUFD: > > * The simple user API which intends to perform relatively simple things > with IOMMUs e.g. DPDK. It generally creates an IOAS and attach to VFIO It generally creates? can you explicit what i

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Cédric Le Goater
On 7/12/24 13:46, Joao Martins wrote: There's generally two modes of operation for IOMMUFD: * The simple user API which intends to perform relatively simple things with IOMMUs e.g. DPDK. It generally creates an IOAS and attach to VFIO and mainly performs IOAS_MAP and UNMAP. * The native IOMMUFD

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Joao Martins
On 16/07/2024 10:39, Cédric Le Goater wrote: > On 7/12/24 13:46, Joao Martins wrote: >> There's generally two modes of operation for IOMMUFD: >> >> * The simple user API which intends to perform relatively simple things >> with IOMMUs e.g. DPDK. It generally creates an IOAS and attach to VFIO >> an

Re: [PATCH v4 05/12] vfio/iommufd: Introduce auto domain creation

2024-07-16 Thread Cédric Le Goater
On 7/12/24 13:46, Joao Martins wrote: There's generally two modes of operation for IOMMUFD: * The simple user API which intends to perform relatively simple things with IOMMUs e.g. DPDK. It generally creates an IOAS and attach to VFIO and mainly performs IOAS_MAP and UNMAP. * The native IOMMUFD