RE: [PATCH v4 41/41] vfio: Compile out iommufd for PPC target

2023-11-07 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, November 7, 2023 9:44 PM >Subject: Re: [PATCH v4 41/41] vfio: Compile out iommufd for PPC target > >On 11/2/23 08:13, Zhenzhong Duan wrote: >> Since PPC doesn't support IOMMUFD, make iommufd related code >> compiled out. >> >>

RE: [PATCH v4 27/41] util/char_dev: Add open_cdev()

2023-11-07 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, November 7, 2023 9:38 PM >Subject: Re: [PATCH v4 27/41] util/char_dev: Add open_cdev() > >On 11/2/23 08:12, Zhenzhong Duan wrote: >> From: Yi Liu >> >> /dev/vfio/devices/vfioX may not exist. In that case it is still possible

RE: [PATCH v4 26/41] backends/iommufd: Introduce the iommufd object

2023-11-07 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, November 7, 2023 9:33 PM >Subject: Re: [PATCH v4 26/41] backends/iommufd: Introduce the iommufd object > >On 11/2/23 08:12, Zhenzhong Duan wrote: >> From: Eric Auger [...] >> diff --git a/qapi/qom.json b/qapi/qom.json >> index

RE: [PATCH v4 30/41] vfio/iommufd: Add support for iova_ranges

2023-11-06 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, November 7, 2023 1:19 AM >Subject: Re: [PATCH v4 30/41] vfio/iommufd: Add support for iova_ranges > >On 11/2/23 08:12, Zhenzhong Duan wrote: >> Some vIOMMU such as virtio-iommu use iova ranges from host side to >> setup

RE: [PATCH v4 22/41] vfio/spapr: switch to spapr IOMMU BE add/del_section_window

2023-11-06 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, November 7, 2023 1:33 AM >Subject: Re: [PATCH v4 22/41] vfio/spapr: switch to spapr IOMMU BE >add/del_section_window > >On 11/2/23 08:12, Zhenzhong Duan wrote: >> No fucntional change intended. >> >> Signed-off-by: Zhenzhong

RE: [PATCH v3 23/37] Add iommufd configure option

2023-10-31 Thread Duan, Zhenzhong
Hi All, >-Original Message- >From: Cédric Le Goater >Sent: Tuesday, October 31, 2023 4:59 PM >Subject: Re: [PATCH v3 23/37] Add iommufd configure option > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> This adds "--enable-iommufd/--disable-iommufd" to enable or disable >> iommufd support,

RE: [PATCH v3 29/37] vfio/iommufd: Bypass EEH if iommufd backend

2023-10-31 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, October 31, 2023 5:01 PM >Subject: Re: [PATCH v3 29/37] vfio/iommufd: Bypass EEH if iommufd backend > >On 10/31/23 03:26, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >&

RE: [PATCH v3 06/37] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-31 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, October 31, 2023 3:58 PM >Subject: Re: [PATCH v3 06/37] vfio: Introduce base object for VFIOContainer and >targetted interface > >On 10/30/23 03:40, Duan, Zhenzhong wrote: >> >> >>> -

RE: [PATCH v3 30/37] vfio/pci: Extract out a helper vfio_pci_get_pci_hot_reset_info

2023-10-30 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 30, 2023 10:00 PM >Subject: Re: [PATCH v3 30/37] vfio/pci: Extract out a helper >vfio_pci_get_pci_hot_reset_info > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> This helper will be used by both legacy and iommufd

RE: [PATCH v3 31/37] vfio/pci: Adapt vfio pci hot reset support with iommufd BE

2023-10-30 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 30, 2023 10:05 PM >Subject: Re: [PATCH v3 31/37] vfio/pci: Adapt vfio pci hot reset support with >iommufd BE > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> As pci hot reset path need to reference pci specific functions

RE: [PATCH v3 29/37] vfio/iommufd: Bypass EEH if iommufd backend

2023-10-30 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 30, 2023 9:57 PM >Subject: Re: [PATCH v3 29/37] vfio/iommufd: Bypass EEH if iommufd backend > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> IBM EEH is only supported by legacy backend currently, bypass it >> for IOMMUFD

RE: [PATCH v3 27/37] vfio/iommufd: Switch to manual hwpt allocation

2023-10-30 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 30, 2023 9:52 PM >Subject: Re: [PATCH v3 27/37] vfio/iommufd: Switch to manual hwpt allocation > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> IOMMUFD supports auto allocated hwpt and manually allocated one. >> Manually

RE: [PATCH v3 25/37] util/char_dev: Add open_cdev()

2023-10-30 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 30, 2023 10:54 PM >Subject: Re: [PATCH v3 25/37] util/char_dev: Add open_cdev() > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Yi Liu >> >> /dev/vfio/devices/vfioX may not exist. In that case it is still possible

RE: [PATCH v3 18/37] vfio/container: Implement attach/detach_device

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Saturday, October 28, 2023 12:07 AM >Subject: Re: [PATCH v3 18/37] vfio/container: Implement attach/detach_device > >Sorry, previous email was empty. Friday effect ! > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Eric Auger >> >>

RE: [PATCH v3 19/37] vfio/spapr: Introduce spapr backend and target interface

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Saturday, October 28, 2023 12:05 AM >Subject: Re: [PATCH v3 19/37] vfio/spapr: Introduce spapr backend and target >interface > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> Introduce an empry spapr backend which will hold spapr specific

RE: [PATCH v3 14/37] vfio/container: Move vrdl_list, pgsizes and dma_max_mappings to base container

2023-10-29 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 11:52 PM >Subject: Re: [PATCH v3 14/37] vfio/container: Move vrdl_list, pgsizes and >dma_max_mappings to base container > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Eric Auger >> ... >>

RE: [PATCH v3 11/37] vfio/container: Switch to IOMMU BE set_dirty_page_tracking/query_dirty_bitmap API

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 10:53 PM >Subject: Re: [PATCH v3 11/37] vfio/container: Switch to IOMMU BE >set_dirty_page_tracking/query_dirty_bitmap API > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Eric Auger >> >>

RE: [PATCH v3 10/37] vfio/container: Move space field to base container

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 10:46 PM >Subject: Re: [PATCH v3 10/37] vfio/container: Move space field to base >container > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Move the space field to the base object. Also

RE: [PATCH v3 09/37] vfio/common: Move giommu_list in base container

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 10:39 PM >Subject: Re: [PATCH v3 09/37] vfio/common: Move giommu_list in base >container > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Move the giommu_list field in the base object and

RE: [PATCH v3 08/37] vfio/container: Switch to dma_map|unmap API

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 10:26 PM >Subject: Re: [PATCH v3 08/37] vfio/container: Switch to dma_map|unmap API > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> From: Eric Auger >> >> No fucntional change intended. >> >> Signed-off-by: Eric

RE: [PATCH v3 07/37] vfio/container: Introduce a empty VFIOIOMMUOps

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 10:21 PM >Subject: Re: [PATCH v3 07/37] vfio/container: Introduce a empty >VFIOIOMMUOps > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> This empty VFIOIOMMUOps named vfio_legacy_ops will hold all general >> IOMMU

RE: [PATCH v3 06/37] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-29 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 10:03 PM >Subject: Re: [PATCH v3 06/37] vfio: Introduce base object for VFIOContainer and >targetted interface > >On 10/26/23 12:30, Zhenzhong Duan wrote: >> Introduce a dumb VFIOContainer base object and its

RE: [PATCH v3 24/37] backends/iommufd: Introduce the iommufd object

2023-10-27 Thread Duan, Zhenzhong
>-Original Message- >From: Markus Armbruster >Sent: Friday, October 27, 2023 4:31 PM >Subject: Re: [PATCH v3 24/37] backends/iommufd: Introduce the iommufd object > >"Duan, Zhenzhong" writes: > >>>-Original Message- >>> From:

RE: [PATCH v3 00/37] vfio: Adopt iommufd

2023-10-27 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Cédric Le Goater >Sent: Friday, October 27, 2023 3:46 PM >Subject: Re: [PATCH v3 00/37] vfio: Adopt iommufd > >On 10/27/23 08:17, Duan, Zhenzhong wrote: >> Hi Markus, >> >>> -Original Message- >>

RE: [PATCH v3 24/37] backends/iommufd: Introduce the iommufd object

2023-10-27 Thread Duan, Zhenzhong
>-Original Message- >From: Markus Armbruster >Sent: Thursday, October 26, 2023 9:28 PM >Subject: Re: [PATCH v3 24/37] backends/iommufd: Introduce the iommufd object > >Zhenzhong Duan writes: > >> From: Eric Auger >> >> Introduce an iommufd object which allows the interaction >> with

RE: [PATCH v3 00/37] vfio: Adopt iommufd

2023-10-27 Thread Duan, Zhenzhong
Hi Markus, >-Original Message- >From: Markus Armbruster >Sent: Thursday, October 26, 2023 9:27 PM >Subject: Re: [PATCH v3 00/37] vfio: Adopt iommufd > >Zhenzhong Duan writes: > >> Hi, >> >> Thanks all for giving guides and comments on previous series, here is >> the v3 of pure iommufd

RE: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-24 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 23, 2023 11:29 PM > >Subject: Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and >targetted interface > >On 10/20/23 10:19, Eric Auger wrote: >> Hi, >> On 10/20/23

RE: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Friday, October 20, 2023 4:19 PM >Subject: Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and >targetted interface > >Hi, >On 10/20/23 07:48, Duan, Zhenzhong wrote: >> Hi Cédric, >> >

RE: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-19 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Cédric Le Goater >Sent: Thursday, October 19, 2023 8:18 PM >Subject: Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and >targetted interface > >On 10/19/23 04:29, Duan, Zhenzhong wrote: >>> -

RE: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-18 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, October 18, 2023 4:04 PM >Subject: Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and >targetted interface > >On 10/18/23 04:41, Duan, Zhenzhong wrote: >> Hi Cédric, &

RE: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and targetted interface

2023-10-17 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Cédric Le Goater >Sent: Tuesday, October 17, 2023 11:51 PM >Subject: Re: [PATCH v2 02/27] vfio: Introduce base object for VFIOContainer and >targetted interface > >On 10/16/23 10:31, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Introduce a dumb

RE: [PATCH v2 01/27] vfio: Rename VFIOContainer into VFIOLegacyContainer

2023-10-17 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Tuesday, October 17, 2023 11:51 PM >Subject: Re: [PATCH v2 01/27] vfio: Rename VFIOContainer into >VFIOLegacyContainer > >Hello, > >On 10/16/23 10:31, Zhenzhong Duan wrote: >> From: Eric Auger >> >> In the prospect to introduce a base

RE: [PATCH v2 17/27] backends/iommufd: Introduce the iommufd object

2023-10-17 Thread Duan, Zhenzhong
Hi Markus, >-Original Message- >From: Markus Armbruster >Sent: Monday, October 16, 2023 6:01 PM >Subject: Re: [PATCH v2 17/27] backends/iommufd: Introduce the iommufd object > >Zhenzhong Duan writes: > >> From: Eric Auger >> >> Introduce an iommufd object which allows the interaction

RE: [PATCH] vfio/pci: Remove vfio_detach_device from vfio_realize error path

2023-10-11 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Thursday, October 12, 2023 4:10 AM >To: eric.auger@gmail.com; eric.au...@redhat.com; qemu- >de...@nongnu.org; alex.william...@redhat.com; c...@redhat.com; Duan, >Zhenzhong ; Liu, Yi L ; >yangh...@redhat.com >S

RE: [PATCH v5 07/15] vfio/pci: Introduce vfio_[attach/detach]_device

2023-10-10 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Monday, October 9, 2023 5:09 PM >Subject: [PATCH v5 07/15] vfio/pci: Introduce vfio_[attach/detach]_device > >We want the VFIO devices to be able to use two different >IOMMU backends, the legacy VFIO one and the new iommufd one. >

RE: [PATCH v4 10/15] vfio/ccw: Use vfio_[attach/detach]_device

2023-10-09 Thread Duan, Zhenzhong
tach]_device > >Hi Zhenzhong, > >On 10/9/23 03:25, Duan, Zhenzhong wrote: >> >>> -Original Message- >>> From: Eric Auger >>> Sent: Monday, October 9, 2023 1:46 AM >>> Subject: Re: [PATCH v4 10/15] vfio/ccw: Use vfio_[attach/detach]_device &g

RE: [PATCH 0/3] vfio: memory leak fix and code cleanup

2023-10-09 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Monday, October 9, 2023 2:32 PM >Subject: Re: [PATCH 0/3] vfio: memory leak fix and code cleanup > >On 10/9/23 04:20, Zhenzhong Duan wrote: >> Hi, >> >> This trivial patchset fixes a incremental memory leak in rare case, >> and some

RE: [PATCH v4 10/15] vfio/ccw: Use vfio_[attach/detach]_device

2023-10-08 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Monday, October 9, 2023 1:46 AM >Subject: Re: [PATCH v4 10/15] vfio/ccw: Use vfio_[attach/detach]_device > >Hi Zhenzhong, >On 10/8/23 12:21, Duan, Zhenzhong wrote: >> Hi Eric, >> >>> -Original M

RE: [PATCH v4 10/15] vfio/ccw: Use vfio_[attach/detach]_device

2023-10-08 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Wednesday, October 4, 2023 11:44 PM >Subject: [PATCH v4 10/15] vfio/ccw: Use vfio_[attach/detach]_device > >Let the vfio-ccw device use vfio_attach_device() and >vfio_detach_device(), hence hiding the details of the used >IOMMU

RE: [PATCH v2 09/12] vfio/ccw: Use vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
Hi Eric, Matthew, >-Original Message- >From: Matthew Rosato >Sent: Wednesday, September 27, 2023 9:26 PM >Subject: Re: [PATCH v2 09/12] vfio/ccw: Use vfio_[attach/detach]_device > >On 9/27/23 8:09 AM, Duan, Zhenzhong wrote: >> >> >>> -Ori

RE: [PATCH v2 11/12] vfio/common: Introduce two kinds of VFIO device lists

2023-09-27 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 9:14 PM >Subject: Re: [PATCH v2 11/12] vfio/common: Introduce two kinds of VFIO device >lists > >Hi Zhenzhong, >On 9/26/23 13:32, Zhenzhong Duan wrote: >> In VFIO subsystem, there are different VFIO

RE: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 8:23 PM >Subject: Re: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device > > > >On 9/27/23 12:07, Duan, Zhenzhong wrote: >> Hi Eric, >> >>> -Origina

RE: [PATCH v2 08/12] vfio/ap: Use vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Subject: Re: [PATCH v2 08/12] vfio/ap: Use vfio_[attach/detach]_device > > > >On 9/27/23 13:52, Duan, Zhenzhong wrote: >> >>> -Original Message- >>> From: Eric Auger >>> Sent: Wednesd

RE: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, September 27, 2023 6:17 PM >Subject: Re: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device > >On 9/26/23 13:32, Zhenzhong Duan wrote: >> From: Eric Auger >> >> We want the VFIO devices to be able to use two

RE: [PATCH v2 09/12] vfio/ccw: Use vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 6:00 PM >Subject: Re: [PATCH v2 09/12] vfio/ccw: Use vfio_[attach/detach]_device > > > >On 9/26/23 13:32, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Let the vfio-ccw device use vfio_attach_device() and >>

RE: [PATCH v2 08/12] vfio/ap: Use vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 5:16 PM >Subject: Re: [PATCH v2 08/12] vfio/ap: Use vfio_[attach/detach]_device > >Hi Zhenzhong, > >On 9/26/23 13:32, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Let the vfio-ap device use

RE: [PATCH v2 07/12] vfio/platform: Use vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 5:11 PM >Subject: Re: [PATCH v2 07/12] vfio/platform: Use vfio_[attach/detach]_device > >Hi, > >On 9/26/23 13:32, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Let the vfio-platform device use

RE: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 5:02 PM >Subject: Re: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device > >Hi Zhenzhong, > >On 9/26/23 13:32, Zhenzhong Duan wrote: >> From: Eric Auger >> >> We want the VFIO devices to be

RE: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device

2023-09-27 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 27, 2023 3:36 PM >Subject: Re: [PATCH v2 06/12] vfio/pci: Introduce vfio_[attach/detach]_device > >Hi Zhenzhong, > >On 9/26/23 13:32, Zhenzhong Duan wrote: >> From: Eric Auger >> >> We want the VFIO devices to be able to

RE: [PATCH v1 04/22] vfio/common: Introduce vfio_container_add|del_section_window()

2023-09-26 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Duan, Zhenzhong >Sent: Thursday, September 21, 2023 6:14 PM >Subject: RE: [PATCH v1 04/22] vfio/common: Introduce >vfio_container_add|del_section_window() > >Hi Cédric, > >>-Original Message- >>From

RE: [PATCH v1 16/22] backends/iommufd: Introduce the iommufd object

2023-09-22 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, September 22, 2023 3:16 PM ... >> +int iommufd_backend_map_dma(IOMMUFDBackend *be, uint32_t ioas, >hwaddr iova, >> +ram_addr_t size, void *vaddr, bool readonly) >> +{ >> +int ret; >> +struct

RE: [PATCH v1 13/22] vfio: Add base container

2023-09-21 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Friday, September 22, 2023 1:20 AM >Subject: Re: [PATCH v1 13/22] vfio: Add base container > >Hi Zhenzhong, >On 9/21/23 05:35, Duan, Zhenzhong wrote: >> Hi Eric, >> >>> -Original Message

RE: [PATCH v1 12/22] vfio/ccw: Use vfio_[attach/detach]_device

2023-09-21 Thread Duan, Zhenzhong
static functions, local to container.c. >> >> Signed-off-by: Eric Auger >> Signed-off-by: Yi Liu >> Signed-off-by: Zhenzhong Duan > >Zhenzhong, > >Could you please resend 1-12 independantly as a prereq series for iommufd >support ? I think there wouldn't be

RE: [PATCH v1 05/22] vfio/common: Extract out vfio_kvm_device_[add/del]_fd

2023-09-21 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Thursday, September 21, 2023 4:42 PM >Subject: Re: [PATCH v1 05/22] vfio/common: Extract out >vfio_kvm_device_[add/del]_fd > >On 9/20/23 13:49, Eric Auger wrote: >> Hi Zhenzhong, >> >> On 8/30/23 12:37, Zhenzhong Duan wrote: >>>

RE: [PATCH v1 09/22] vfio/container: Introduce vfio_[attach/detach]_device

2023-09-21 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Thursday, September 21, 2023 5:45 PM >Subject: Re: [PATCH v1 09/22] vfio/container: Introduce >vfio_[attach/detach]_device > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Eric Auger >> >> We want the VFIO devices to be able to use

RE: [PATCH v1 04/22] vfio/common: Introduce vfio_container_add|del_section_window()

2023-09-21 Thread Duan, Zhenzhong
Hi Cédric, >-Original Message- >From: Cédric Le Goater >Sent: Thursday, September 21, 2023 4:29 PM >Subject: Re: [PATCH v1 04/22] vfio/common: Introduce >vfio_container_add|del_section_window() > >Hello Zhenzhong, > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Eric Auger >> >>

RE: [PATCH v1 07/22] vfio/common: Refactor vfio_viommu_preset() to be group agnostic

2023-09-21 Thread Duan, Zhenzhong
>-Original Message- >From: Alex Williamson >Sent: Thursday, September 21, 2023 6:51 AM >Subject: Re: [PATCH v1 07/22] vfio/common: Refactor vfio_viommu_preset() to >be group agnostic > >On Wed, 30 Aug 2023 18:37:39 +0800 >Zhenzhong Duan wrote: > >> So that it doesn't need to be moved

RE: [PATCH v1 05/22] vfio/common: Extract out vfio_kvm_device_[add/del]_fd

2023-09-21 Thread Duan, Zhenzhong
>-Original Message- >From: Alex Williamson >Sent: Thursday, September 21, 2023 5:40 AM >Subject: Re: [PATCH v1 05/22] vfio/common: Extract out >vfio_kvm_device_[add/del]_fd > >On Wed, 30 Aug 2023 18:37:37 +0800 >Zhenzhong Duan wrote: > >> ...which will be used by both legacy and

RE: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Duan, Zhenzhong
te: >>> On 9/20/23 05:42, Duan, Zhenzhong wrote: >>>> >>>> >>>>> -Original Message- >>>>> From: Cédric Le Goater >>>>> Sent: Wednesday, September 20, 2023 1:08 AM >>>>> Subject: Re: [PATCH v1 15/22

RE: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Jason Gunthorpe >Sent: Thursday, September 21, 2023 2:20 AM >Subject: Re: [PATCH v1 15/22] Add iommufd configure option > >On Wed, Sep 20, 2023 at 12:17:24PM -0600, Alex Williamson wrote: > >> > The iommufd design requires one open of the /dev/iommu to be

RE: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Thursday, September 21, 2023 1:31 AM >Subject: Re: [PATCH v1 13/22] vfio: Add base container > >Hi Zhenzhong, > >On 9/19/23 19:23, Cédric Le Goater wrote: >> On 8/30/23 12:37, Zhenzhong Duan wrote: >>> From: Yi Liu >>> >>> Abstract

RE: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 9:54 PM >Subject: Re: [PATCH v1 13/22] vfio: Add base container > >Hi Cedric, > >On 9/19/23 19:23, Cédric Le Goater wrote: >> On 8/30/23 12:37, Zhenzhong Duan wrote: >>> From: Yi Liu >>> >>> Abstract the

RE: [PATCH v1 09/22] vfio/container: Introduce vfio_[attach/detach]_device

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 9:33 PM >Subject: Re: [PATCH v1 09/22] vfio/container: Introduce >vfio_[attach/detach]_device > >Hi Zhenzhong, > >In the commit title I would replace vfio/container by vfio/pci to match >next patches Make sense,

RE: [PATCH v1 08/22] vfio/common: Move legacy VFIO backend code into separate container.c

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 9:12 PM >Subject: Re: [PATCH v1 08/22] vfio/common: Move legacy VFIO backend code >into separate container.c > >Hi, > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Yi Liu >> >> Move all the code really

RE: [PATCH v1 07/22] vfio/common: Refactor vfio_viommu_preset() to be group agnostic

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 9:01 PM >Subject: Re: [PATCH v1 07/22] vfio/common: Refactor vfio_viommu_preset() to >be group agnostic > > > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> So that it doesn't need to be moved into container.c as

RE: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, September 20, 2023 8:58 PM >Subject: Re: [PATCH v1 13/22] vfio: Add base container > >On 9/20/23 10:48, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >>> From: Céd

RE: [PATCH v1 17/22] util/char_dev: Add open_cdev()

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Daniel P. Berrangé >Sent: Wednesday, September 20, 2023 8:39 PM >Subject: Re: [PATCH v1 17/22] util/char_dev: Add open_cdev() > >On Wed, Aug 30, 2023 at 06:37:49PM +0800, Zhenzhong Duan wrote: >> From: Yi Liu >> >> /dev/vfio/devices/vfioX may not exist. In

RE: [PATCH v1 06/22] vfio/common: Add a vfio device iterator

2023-09-20 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 8:26 PM >Subject: Re: [PATCH v1 06/22] vfio/common: Add a vfio device iterator > >Hi Zhenzhong, > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> With a vfio device iterator added, we can make some migration

RE: [PATCH v1 06/22] vfio/common: Add a vfio device iterator

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Alex Williamson >Subject: Re: [PATCH v1 06/22] vfio/common: Add a vfio device iterator > >On Wed, 30 Aug 2023 18:37:38 +0800 >Zhenzhong Duan wrote: > >> With a vfio device iterator added, we can make some migration and reset >> related functions group

RE: [PATCH v1 15/22] Add iommufd configure option

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, September 20, 2023 8:20 PM >Subject: Re: [PATCH v1 15/22] Add iommufd configure option > >On 9/20/23 05:42, Duan, Zhenzhong wrote: >> >> >>> -Original Message- >>

RE: [PATCH v1 05/22] vfio/common: Extract out vfio_kvm_device_[add/del]_fd

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 7:49 PM >Subject: Re: [PATCH v1 05/22] vfio/common: Extract out >vfio_kvm_device_[add/del]_fd > >Hi Zhenzhong, > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> ...which will be used by both legacy and iommufd

RE: [PATCH v1 04/22] vfio/common: Introduce vfio_container_add|del_section_window()

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 7:23 PM >Subject: Re: [PATCH v1 04/22] vfio/common: Introduce >vfio_container_add|del_section_window() > >Hi Zhenzhong, >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Eric Auger >> >> Introduce helper

RE: [PATCH v1 02/22] Update linux-header to support iommufd cdev and hwpt alloc

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Wednesday, September 20, 2023 7:05 PM >Subject: Re: [PATCH v1 02/22] Update linux-header to support iommufd cdev and >hwpt alloc > > > >On 9/15/23 05:02, Duan, Zhenzhong wrote: >> Hi Eric, >> >&g

RE: [PATCH v1 13/22] vfio: Add base container

2023-09-20 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, September 20, 2023 1:24 AM >Subject: Re: [PATCH v1 13/22] vfio: Add base container > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From: Yi Liu >> >> Abstract the VFIOContainer to be a base object. It is supposed to be >>

RE: [PATCH v1 15/22] Add iommufd configure option

2023-09-19 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, September 20, 2023 1:08 AM >Subject: Re: [PATCH v1 15/22] Add iommufd configure option > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> This adds "--enable-iommufd/--disable-iommufd" to enable or disable >> iommufd support,

RE: [PATCH v1 14/22] vfio/common: Simplify vfio_viommu_preset()

2023-09-19 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Wednesday, September 20, 2023 12:01 AM >Subject: Re: [PATCH v1 14/22] vfio/common: Simplify vfio_viommu_preset() > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> Commit "vfio/container-base: Introduce [attach/detach]_device container

RE: [PATCH v1 00/22] vfio: Adopt iommufd

2023-09-15 Thread Duan, Zhenzhong
>-Original Message- >From: Cédric Le Goater >Sent: Friday, September 15, 2023 8:43 PM >Subject: Re: [PATCH v1 00/22] vfio: Adopt iommufd > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> Hi All, >> >> As the kernel side iommufd cdev and hot reset feature have been queued, >> also hwpt alloc

RE: [PATCH v1 02/22] Update linux-header to support iommufd cdev and hwpt alloc

2023-09-14 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Thursday, September 14, 2023 10:46 PM >Subject: Re: [PATCH v1 02/22] Update linux-header to support iommufd cdev and >hwpt alloc > >Hi Zhenzhong, > >On 8/30/23 12:37, Zhenzhong Duan wrote: >> From

RE: [PATCH v1 00/22] vfio: Adopt iommufd

2023-09-14 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Thursday, September 14, 2023 5:04 PM >To: Duan, Zhenzhong ; qemu-devel@nongnu.org >Cc: alex.william...@redhat.com; c...@redhat.com; j...@nvidia.com; >nicol...@nvidia.com; Martins, Joao ; >pet...@redhat.com; jaso

RE: [PATCH v1] vfio/common: Separate vfio-pci ranges

2023-09-11 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Sent: Monday, September 11, 2023 6:20 PM >To: Duan, Zhenzhong ; qemu-devel@nongnu.org >Cc: Alex Williamson ; Cedric Le Goater >; Avihai Horon ; Gerd Hoffmann > >Subject: Re: [PATCH v1] vfio/common: Separate vfio-pci range

RE: [PATCH v1] vfio/common: Separate vfio-pci ranges

2023-09-11 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Sent: Monday, September 11, 2023 6:13 PM >Subject: Re: [PATCH v1] vfio/common: Separate vfio-pci ranges > >On 11/09/2023 10:48, Duan, Zhenzhong wrote: >>> -Original Message- >>> From: Joao Martins &g

RE: [PATCH v1] vfio/common: Separate vfio-pci ranges

2023-09-11 Thread Duan, Zhenzhong
>-Original Message- >From: Joao Martins >Sent: Monday, September 11, 2023 5:07 PM >Subject: Re: [PATCH v1] vfio/common: Separate vfio-pci ranges > >On 11/09/2023 09:57, Duan, Zhenzhong wrote: >>> -Original Message- >>> From: qemu-devel-bounces

RE: [PATCH v1] vfio/common: Separate vfio-pci ranges

2023-09-11 Thread Duan, Zhenzhong
>-Original Message- >From: qemu-devel-bounces+zhenzhong.duan=intel@nongnu.org devel-bounces+zhenzhong.duan=intel@nongnu.org> On Behalf Of Joao >Martins >Sent: Friday, September 8, 2023 5:30 PM >Subject: [PATCH v1] vfio/common: Separate vfio-pci ranges > >QEMU computes the DMA

Re: [PATCH v4 12/15] vfio/common: Support device dirty page tracking with vIOMMU

2023-09-08 Thread Duan, Zhenzhong
On 9/8/2023 6:11 PM, Joao Martins wrote: On 08/09/2023 07:11, Duan, Zhenzhong wrote: Hi Joao, On 6/23/2023 5:48 AM, Joao Martins wrote: Currently, device dirty page tracking with vIOMMU is not supported, and a blocker is added and the migration is prevented. When vIOMMU is used, IOVA

Re: [PATCH v4 15/15] vfio/common: Block migration with vIOMMUs without address width limits

2023-09-08 Thread Duan, Zhenzhong
On 6/23/2023 5:48 AM, Joao Martins wrote: Only block the case when the underlying vIOMMU model does not report any address space limits, in addition to DMA translation being off or no vIOMMU present. The limits are needed such that can define the IOVA limits that arm the device dirty tracker.

Re: [PATCH v4 06/15] intel-iommu: Implement get_attr() method

2023-09-08 Thread Duan, Zhenzhong
On 6/23/2023 5:48 AM, Joao Martins wrote: Implement IOMMU MR get_attr() method and use the dma_translation property to report the IOMMU_ATTR_DMA_TRANSLATION attribute. Additionally add the necessary get_iommu_attr into the PCIIOMMUOps to support pci_device_iommu_get_attr(). The callback in

Re: [PATCH v4 12/15] vfio/common: Support device dirty page tracking with vIOMMU

2023-09-08 Thread Duan, Zhenzhong
Hi Joao, On 6/23/2023 5:48 AM, Joao Martins wrote: Currently, device dirty page tracking with vIOMMU is not supported, and a blocker is added and the migration is prevented. When vIOMMU is used, IOVA ranges are DMA mapped/unmapped on the fly as requesting by the vIOMMU. These IOVA ranges can

RE: [PATCH v1 21/22] vfio/pci: Allow the selection of a given iommu backend

2023-09-06 Thread Duan, Zhenzhong
>-Original Message- >From: Jason Gunthorpe >Sent: Thursday, September 7, 2023 9:11 AM >To: Alex Williamson >Subject: Re: [PATCH v1 21/22] vfio/pci: Allow the selection of a given iommu >backend > >On Wed, Sep 06, 2023 at 01:09:26PM -0600, Alex Williamson wrote: >> On Wed, 6 Sep 2023

RE: [RFC PATCH v4 22/24] vfio/pci: Adapt vfio pci hot reset support with iommufd BE

2023-08-17 Thread Duan, Zhenzhong
>-Original Message- >From: Nicolin Chen >Sent: Thursday, August 17, 2023 1:26 PM >Subject: Re: [RFC PATCH v4 22/24] vfio/pci: Adapt vfio pci hot reset support >with iommufd BE > >On Wed, Jul 12, 2023 at 03:25:26PM +0800, Zhenzhong Duan wrote: > >> +#ifdef CONFIG_IOMMUFD >> +static

RE: [RFC PATCH v4 21/24] vfio/as: Add vfio device iterator callback for iommufd

2023-08-17 Thread Duan, Zhenzhong
>-Original Message- >From: Nicolin Chen >Sent: Thursday, August 17, 2023 1:49 PM >Subject: Re: [RFC PATCH v4 21/24] vfio/as: Add vfio device iterator callback >for >iommufd > >On Wed, Jul 12, 2023 at 03:25:25PM +0800, Zhenzhong Duan wrote: > >> The way to get vfio device pointer is

RE: [RFC PATCH v4 00/24] vfio: Adopt iommufd

2023-08-02 Thread Duan, Zhenzhong
>-Original Message- >From: Nicolin Chen >Subject: Re: [RFC PATCH v4 00/24] vfio: Adopt iommufd > >On Tue, Aug 01, 2023 at 08:28:01AM +, Duan, Zhenzhong wrote: > >> Ping, any comments or suggestions are appreciated. > >Zhenzhong, I'd love to, yet haven'

RE: [RFC PATCH v4 00/24] vfio: Adopt iommufd

2023-08-01 Thread Duan, Zhenzhong
Ping, any comments or suggestions are appreciated. Thanks Zhenzhong >-Original Message- >From: Duan, Zhenzhong >Sent: Wednesday, July 12, 2023 3:25 PM >To: qemu-devel@nongnu.org >Cc: alex.william...@redhat.com; c...@redhat.com; j...@nvidia.com; >nicol...@n

RE: [RFC PATCH v4 20/24] vfio/iommufd: Implement the iommufd backend

2023-07-14 Thread Duan, Zhenzhong
>-Original Message- >From: Joel Granados >Sent: Friday, July 14, 2023 5:23 PM >Subject: Re: [RFC PATCH v4 20/24] vfio/iommufd: Implement the iommufd >backend > >On Wed, Jul 12, 2023 at 03:25:24PM +0800, Zhenzhong Duan wrote: >> From: Yi Liu ... >> +static int vfio_get_devicefd(const char

RE: [RFC PATCH v4 02/24] Update linux-header per VFIO device cdev v14

2023-07-12 Thread Duan, Zhenzhong
>-Original Message- >From: Cornelia Huck >Sent: Wednesday, July 12, 2023 5:36 PM >Subject: RE: [RFC PATCH v4 02/24] Update linux-header per VFIO device cdev >v14 > >On Wed, Jul 12 2023, "Duan, Zhenzhong" >wrote: > >>>-Origina

RE: [RFC PATCH v4 02/24] Update linux-header per VFIO device cdev v14

2023-07-12 Thread Duan, Zhenzhong
>-Original Message- >From: Cornelia Huck >Sent: Wednesday, July 12, 2023 3:49 PM >Subject: Re: [RFC PATCH v4 02/24] Update linux-header per VFIO device cdev >v14 > >On Wed, Jul 12 2023, Zhenzhong Duan wrote: > >> Signed-off-by: Zhenzhong Duan >> --- >> linux-headers/linux/iommufd.h |

RE: [PATCH 2/2] virtio-iommu: Rework the trace in virtio_iommu_set_page_size_mask()

2023-07-06 Thread Duan, Zhenzhong
>-Original Message- >From: Jean-Philippe Brucker >Sent: Thursday, July 6, 2023 10:36 PM >Subject: Re: [PATCH 2/2] virtio-iommu: Rework the trace in >virtio_iommu_set_page_size_mask() > >On Wed, Jul 05, 2023 at 03:16:31PM +0200, Eric Auger wrote: >> >>> diff --git

RE: [PATCH v2 1/2] virtio-iommu: Fix 64kB host page size VFIO device assignment

2023-07-06 Thread Duan, Zhenzhong
>-Original Message- >From: Eric Auger >Sent: Thursday, July 6, 2023 12:51 AM >Subject: [PATCH v2 1/2] virtio-iommu: Fix 64kB host page size VFIO device >assignment > >When running on a 64kB page size host and protecting a VFIO device with the >virtio-iommu, qemu crashes with this kind of

RE: [PATCH 1/2] virtio-iommu: Fix 64kB host page size VFIO device assignment

2023-07-06 Thread Duan, Zhenzhong
>-Original Message- >From: Jean-Philippe Brucker >Sent: Wednesday, July 5, 2023 7:33 PM >Subject: Re: [PATCH 1/2] virtio-iommu: Fix 64kB host page size VFIO device >assignment > >On Wed, Jul 05, 2023 at 10:13:11AM +, Duan, Zhenzhong wrote: >> >-

RE: [PATCH 2/2] virtio-iommu: Rework the trace in virtio_iommu_set_page_size_mask()

2023-07-06 Thread Duan, Zhenzhong
Hi Eric, >-Original Message- >From: Eric Auger >Sent: Wednesday, July 5, 2023 9:17 PM >Subject: Re: [PATCH 2/2] virtio-iommu: Rework the trace in >virtio_iommu_set_page_size_mask() > >Hi Zhenghong, > >On 7/5/23 10:17, Duan, Zhenzhong wrote: >> >>>

RE: [PATCH 1/2] virtio-iommu: Fix 64kB host page size VFIO device assignment

2023-07-05 Thread Duan, Zhenzhong
>-Original Message- >From: Jean-Philippe Brucker >Sent: Wednesday, July 5, 2023 4:29 PM >Subject: Re: [PATCH 1/2] virtio-iommu: Fix 64kB host page size VFIO device >assignment > >On Wed, Jul 05, 2023 at 04:52:09AM +, Duan, Zhenzhong wrote: >> Hi Eric, &

<    1   2   3   4   >