On 8/20/21 4:36 AM, Li, Chunming wrote: > The current SMMU V3 device model only support PCI/PCIe devices, > so we update it to support non-PCI/PCIe devices. > > hw/arm/smmuv3: > . Create IOMMU memory regions for non-PCI/PCIe devices based on their > SID > . Add sid-map property to store non-PCI/PCIe devices SID > . Update implementation of CFGI commands based on device SID > hw/arm/smmu-common: > . Differentiate PCI/PCIe and non-PCI/PCIe devices SID getting strategy > hw/arm/virt: > . Add PL330 DMA controller and connect with SMMUv3 for testing > . Add smmuv3_sidmap for non-PCI/PCIe devices SID setting > > Signed-off-by: Chunming Li <chunming...@verisilicon.com> > Signed-off-by: Renwei Liu <renwei....@verisilicon.com> > --- > This patch depends on PL330 memory region connection patch: > https://patchew.org/QEMU/4c23c17b8e87e74e906a25a3254a03f4fa1fe...@shasxm03.verisilicon.com/ > > hw/arm/smmuv3.c | 75 ++++++++++++++++++------ > hw/arm/virt.c | 110 ++++++++++++++++++++++++++++++++++- > include/hw/arm/smmu-common.h | 12 +++- > include/hw/arm/smmuv3.h | 2 + > include/hw/arm/virt.h | 3 + > 5 files changed, 181 insertions(+), 21 deletions(-) > > diff --git a/hw/arm/smmuv3.c b/hw/arm/smmuv3.c > index 01b60bee4..c4da05d8b 100644 > --- a/hw/arm/smmuv3.c > +++ b/hw/arm/smmuv3.c > @@ -32,6 +32,7 @@ > #include "hw/arm/smmuv3.h" > #include "smmuv3-internal.h" > #include "smmu-internal.h" > +#include "hw/qdev-properties.h" > > /** > * smmuv3_trigger_irq - pulse @irq if enabled and update > @@ -612,7 +613,7 @@ static SMMUTransCfg *smmuv3_get_config(SMMUDevice *sdev, > SMMUEventInfo *event) > return cfg; > } > > -static void smmuv3_flush_config(SMMUDevice *sdev) > +static void __attribute__((unused)) smmuv3_flush_config(SMMUDevice *sdev) > {
Why keep this function if unused?