qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Eric Auger <eric.auger@redhat.com>
To: Shameer Kolothum <skolothumtho@nvidia.com>,
	Nicolin Chen <nicolinc@nvidia.com>
Cc: "qemu-arm@nongnu.org" <qemu-arm@nongnu.org>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	"peter.maydell@linaro.org" <peter.maydell@linaro.org>,
	"Jason Gunthorpe" <jgg@nvidia.com>,
	"ddutile@redhat.com" <ddutile@redhat.com>,
	"berrange@redhat.com" <berrange@redhat.com>,
	"Nathan Chen" <nathanc@nvidia.com>,
	"Matt Ochs" <mochs@nvidia.com>,
	"smostafa@google.com" <smostafa@google.com>,
	"linuxarm@huawei.com" <linuxarm@huawei.com>,
	"wangzhou1@hisilicon.com" <wangzhou1@hisilicon.com>,
	"jiangkunkun@huawei.com" <jiangkunkun@huawei.com>,
	"jonathan.cameron@huawei.com" <jonathan.cameron@huawei.com>,
	"zhangfei.gao@linaro.org" <zhangfei.gao@linaro.org>,
	"zhenzhong.duan@intel.com" <zhenzhong.duan@intel.com>,
	"shameerkolothum@gmail.com" <shameerkolothum@gmail.com>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>
Subject: Re: [RFC PATCH v3 05/15] hw/arm/smmuv3-accel: Introduce smmuv3 accel device
Date: Fri, 5 Sep 2025 12:17:59 +0200	[thread overview]
Message-ID: <e2761aa2-1edf-42e9-97f6-e6bcedafd828@redhat.com> (raw)
In-Reply-To: <CH3PR12MB754884A2F1673D1424EE8378AB03A@CH3PR12MB7548.namprd12.prod.outlook.com>



On 9/5/25 10:22 AM, Shameer Kolothum wrote:
>
>> -----Original Message-----
>> From: Eric Auger <eric.auger@redhat.com>
>> Sent: 04 September 2025 15:33
>> To: Nicolin Chen <nicolinc@nvidia.com>; Shameer Kolothum
>> <skolothumtho@nvidia.com>
>> Cc: qemu-arm@nongnu.org; qemu-devel@nongnu.org;
>> peter.maydell@linaro.org; Jason Gunthorpe <jgg@nvidia.com>;
>> ddutile@redhat.com; berrange@redhat.com; Nathan Chen
>> <nathanc@nvidia.com>; Matt Ochs <mochs@nvidia.com>;
>> smostafa@google.com; linuxarm@huawei.com; wangzhou1@hisilicon.com;
>> jiangkunkun@huawei.com; jonathan.cameron@huawei.com;
>> zhangfei.gao@linaro.org; zhenzhong.duan@intel.com;
>> shameerkolothum@gmail.com
>> Subject: Re: [RFC PATCH v3 05/15] hw/arm/smmuv3-accel: Introduce smmuv3
>> accel device
>>
>> External email: Use caution opening links or attachments
>>
>>
>> On 7/14/25 7:23 PM, Nicolin Chen wrote:
>>> On Mon, Jul 14, 2025 at 04:59:31PM +0100, Shameer Kolothum wrote:
>>>> Also setup specific PCIIOMMUOps for accel SMMUv3 as accel
>>>> SMMUv3 will have different handling for those ops callbacks in
>>>> subsequent patches.
>>>>
>>>> The "accel" property is not yet added, so users cannot set it at this
>>>> point. It will be introduced in a subsequent patch once the necessary
>>>> support is in place.
>>>>
>>>> Signed-off-by: Shameer Kolothum
>>>> <shameerali.kolothum.thodi@huawei.com>
>>> Overall the patch looks good to me,
>>> Reviewed-by: Nicolin Chen <nicolinc@nvidia.com>
>>>
>>> with some nits:
>>>
>>>> @@ -61,7 +61,8 @@ arm_common_ss.add(when: 'CONFIG_ARMSSE',
>> if_true:
>>>> files('armsse.c'))
>>>>  arm_common_ss.add(when: 'CONFIG_FSL_IMX7', if_true:
>>>> files('fsl-imx7.c', 'mcimx7d-sabre.c'))
>>>>  arm_common_ss.add(when: 'CONFIG_FSL_IMX8MP', if_true:
>>>> files('fsl-imx8mp.c'))
>>>>  arm_common_ss.add(when: 'CONFIG_FSL_IMX8MP_EVK', if_true:
>>>> files('imx8mp-evk.c'))
>>>> -arm_common_ss.add(when: 'CONFIG_ARM_SMMUV3', if_true:
>>>> files('smmuv3.c'))
>>>> +arm_ss.add(when: 'CONFIG_ARM_SMMUV3', if_true: files('smmuv3.c'))
>>>> +arm_ss.add(when: ['CONFIG_ARM_SMMUV3', 'CONFIG_IOMMUFD'],
>> if_true:
>>>> +files('smmuv3-accel.c'))
>>> Wondering why "arm_common_ss" is changed to "arm_ss"?
>> Indeed why did you need to change that?
> Thanks for going through the series. I will go through all the comments and
> rework the series soon, but a quick one on the above question.
>
> I was getting this compile error as now we use #include CONFIG_DEVICES to check
> CONFIG_IOMMUFD 
>
> .d -o libsystem_arm.a.p/hw_arm_smmuv3.c.o -c ../hw/arm/smmuv3.c
> In file included from ../hw/arm/smmuv3.c:35:
> ../hw/arm/smmuv3-accel.h:17:10: error: #include expects "FILENAME" or <FILENAME>
>    17 | #include CONFIG_DEVICES
>       |          ^~~~~~~~~~~~~~
> ../hw/arm/smmuv3-accel.h:55:13: error: attempt to use poisoned "CONFIG_ARM_SMMUV3"
>    55 | #if defined(CONFIG_ARM_SMMUV3) && defined(CONFIG_IOMMUFD)
>       |             ^
> ../hw/arm/smmuv3-accel.h:55:43: error: attempt to use poisoned "CONFIG_IOMMUFD"
>    55 | #if defined(CONFIG_ARM_SMMUV3) && defined(CONFIG_IOMMUFD)
>       |                                           ^
> ninja: build stopped: subcommand failed.
> make[1]: *** [Makefile:168: run-ninja] Error 1
> make[1]: Leaving directory '/root/qemu-hisi/build'
>
> And with arm_common_ss.add, it looks like the compiler is missing
> '-DCONFIG_DEVICES="aarch64-softmmu-config-devices.h"'.
I guess this is because devices are arch specific so it cannot be
"common" anymore. Looks sensible to me. Adding Philippe in the loop.

Unrelated to that, do you have a way to opt-out SMMUv3 HW acceleration.
Some people might not be interested in that feature.

Eric
>
> Not sure how to fix this with arm_common_ss.add. Please let me know
> If there is a way to address this.
>
> Thanks,
> Shameer
>
>
>



  reply	other threads:[~2025-09-05 10:19 UTC|newest]

Thread overview: 98+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-14 15:59 [RFC PATCH v3 00/15] hw/arm/virt: Add support for user-creatable accelerated SMMUv3 Shameer Kolothum via
2025-07-14 15:59 ` [RFC PATCH v3 01/15] backends/iommufd: Introduce iommufd_backend_alloc_viommu Shameer Kolothum via
2025-07-14 16:22   ` Nicolin Chen
2025-07-15  9:14   ` Jonathan Cameron via
2025-07-14 15:59 ` [RFC PATCH v3 02/15] backends/iommufd: Introduce iommufd_vdev_alloc Shameer Kolothum via
2025-07-14 16:27   ` Nicolin Chen
2025-07-15  9:19   ` Jonathan Cameron via
2025-07-14 15:59 ` [RFC PATCH v3 03/15] hw/arm/smmu-common: Factor out common helper functions and export Shameer Kolothum via
2025-07-15  9:27   ` Jonathan Cameron via
2025-07-14 15:59 ` [RFC PATCH v3 04/15] hw/arm/smmu-common: Introduce smmu_iommu_ops_by_type() helper Shameer Kolothum via
2025-07-14 16:38   ` Nicolin Chen via
2025-07-15  9:30   ` Jonathan Cameron via
2025-09-04  7:55   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 05/15] hw/arm/smmuv3-accel: Introduce smmuv3 accel device Shameer Kolothum via
2025-07-14 17:23   ` Nicolin Chen
2025-09-04 14:33     ` Eric Auger
2025-09-05  8:22       ` Shameer Kolothum
2025-09-05 10:17         ` Eric Auger [this message]
2025-07-15  9:45   ` Jonathan Cameron via
2025-07-15 10:48   ` Duan, Zhenzhong
2025-07-15 17:29     ` Nicolin Chen
2025-07-16  3:38       ` Duan, Zhenzhong
2025-07-16  9:27         ` Shameerali Kolothum Thodi via
2025-09-04 14:31           ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 06/15] hw/arm/smmuv3-accel: Restrict accelerated SMMUv3 to vfio-pci endpoints with iommufd Shameer Kolothum via
2025-07-14 18:18   ` Nicolin Chen
2025-07-15  9:51   ` Jonathan Cameron via
2025-07-15 10:53   ` Duan, Zhenzhong
2025-07-15 17:59     ` Nicolin Chen
2025-07-16  6:26       ` Duan, Zhenzhong
2025-07-16  9:34         ` Shameerali Kolothum Thodi via
2025-07-16 10:32           ` Duan, Zhenzhong
2025-07-16 17:51           ` Nicolin Chen
2025-07-16 18:21             ` Nicolin Chen
2025-09-05  8:34             ` Eric Auger
2025-09-05  8:14         ` Eric Auger
2025-07-16  8:06       ` Shameerali Kolothum Thodi via
2025-09-05  8:29         ` Eric Auger
2025-08-06  0:55   ` Nicolin Chen
2025-09-05  8:42   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 07/15] hw/arm/smmuv3: Implement get_viommu_cap() callback Shameer Kolothum via
2025-07-14 18:31   ` Nicolin Chen
2025-09-05  8:49   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 08/15] hw/arm/smmuv3-accel: Add set/unset_iommu_device callback Shameer Kolothum via
2025-07-14 19:11   ` Nicolin Chen
2025-07-15 10:29   ` Jonathan Cameron via
2025-07-15 17:01     ` Nicolin Chen
2025-07-16  9:33       ` Jonathan Cameron via
2025-09-05  9:27   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 09/15] hw/arm/smmuv3-accel: Support nested STE install/uninstall support Shameer Kolothum via
2025-07-14 19:37   ` Nicolin Chen
2025-07-15 23:12   ` Nicolin Chen
2025-07-16  8:36     ` Shameerali Kolothum Thodi via
2025-07-16 18:17       ` Nicolin Chen
2025-09-05  9:51       ` Eric Auger
2025-09-05  9:40   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 10/15] hw/arm/smmuv3-accel: Allocate a vDEVICE object for device Shameer Kolothum via
2025-07-14 19:43   ` Nicolin Chen
2025-09-05  9:57   ` Eric Auger
2025-09-05 18:36     ` Nicolin Chen
2025-07-14 15:59 ` [RFC PATCH v3 11/15] hw/pci/pci: Introduce optional get_msi_address_space() callback Shameer Kolothum via
2025-07-14 19:50   ` Nicolin Chen
2025-09-05 10:11     ` Eric Auger
2025-09-05 10:11   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 12/15] hw/arm/smmuv3-accel: Introduce helpers to batch and issue cache invalidations Shameer Kolothum via
2025-07-14 19:55   ` Nicolin Chen
2025-07-15 10:39   ` Jonathan Cameron via
2025-07-15 17:07     ` Nicolin Chen
2025-09-05 10:31   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 13/15] hw/arm/smmuv3: Forward invalidation commands to hw Shameer Kolothum via
2025-07-15 10:46   ` Jonathan Cameron via
2025-07-15 17:22     ` Nicolin Chen
2025-07-16  7:32       ` Shameerali Kolothum Thodi via
2025-09-05 12:45   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 14/15] Read and validate host SMMUv3 feature bits Shameer Kolothum via
2025-07-14 20:04   ` Nicolin Chen via
2025-07-14 20:24     ` Nicolin Chen via
2025-07-15 10:48   ` Jonathan Cameron via
2025-07-16  2:57   ` Nicolin Chen via
2025-07-16 10:26     ` Shameerali Kolothum Thodi via
2025-07-16 18:37       ` Nicolin Chen
2025-07-16 11:51     ` Jason Gunthorpe
2025-07-16 17:35       ` Nicolin Chen
2025-07-16 17:45         ` Jason Gunthorpe
2025-07-16 18:09           ` Nicolin Chen
2025-07-16 18:42             ` Jason Gunthorpe
2025-07-16 18:53               ` Nicolin Chen
2025-09-05 13:04           ` Eric Auger
2025-07-22 17:42   ` Nicolin Chen
2025-09-05 13:20   ` Eric Auger
2025-07-14 15:59 ` [RFC PATCH v3 15/15] hw/arm/smmu-common: Add accel property for SMMU dev Shameer Kolothum via
2025-07-14 20:00   ` Nicolin Chen
2025-07-15 10:49   ` Jonathan Cameron via
2025-09-05 10:36   ` Eric Auger
2025-07-14 16:14 ` [RFC PATCH v3 00/15] hw/arm/virt: Add support for user-creatable accelerated SMMUv3 Nicolin Chen via
2025-07-14 20:22   ` Nicolin Chen via
2025-07-15 10:46 ` Duan, Zhenzhong
2025-07-16  7:27   ` Shameerali Kolothum Thodi via

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e2761aa2-1edf-42e9-97f6-e6bcedafd828@redhat.com \
    --to=eric.auger@redhat.com \
    --cc=berrange@redhat.com \
    --cc=ddutile@redhat.com \
    --cc=jgg@nvidia.com \
    --cc=jiangkunkun@huawei.com \
    --cc=jonathan.cameron@huawei.com \
    --cc=linuxarm@huawei.com \
    --cc=mochs@nvidia.com \
    --cc=nathanc@nvidia.com \
    --cc=nicolinc@nvidia.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=shameerkolothum@gmail.com \
    --cc=skolothumtho@nvidia.com \
    --cc=smostafa@google.com \
    --cc=wangzhou1@hisilicon.com \
    --cc=zhangfei.gao@linaro.org \
    --cc=zhenzhong.duan@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).