Skip to contentSkip to conversation

hw/arm/virt-acpi-build: Fix GSIV values of the {GERR, Sync} interrupts

PATCH Applied Zenghui Yu 3 participants 7 messages Apr 2, 2021 – Apr 8, 2021

lore
Share & tools
lore

Zenghui Yu

author
#0 lore raw

PATCH 1/1 hw/arm/virt-acpi-build: Fix GSIV values of the {GERR, Sync} interrupts

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")
---
 hw/arm/virt-acpi-build.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
hw/arm/virt-acpi-build.c +2 -2
index f5a2b2d4cb..60fe2e65a7 100644
@@ -292,8 +292,8 @@ build_iort(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms)
         smmu->flags = cpu_to_le32(ACPI_IORT_SMMU_V3_COHACC_OVERRIDE);
         smmu->event_gsiv = cpu_to_le32(irq);
         smmu->pri_gsiv = cpu_to_le32(irq + 1);
-        smmu->gerr_gsiv = cpu_to_le32(irq + 2);
-        smmu->sync_gsiv = cpu_to_le32(irq + 3);
+        smmu->sync_gsiv = cpu_to_le32(irq + 2);
+        smmu->gerr_gsiv = cpu_to_le32(irq + 3);
 
         /* Identity RID mapping covering the whole input RID range */
         idmap = &smmu->id_mapping_array[0];
Signature · 1 line
2.19.1
Acked-by on v1 1/1
#1 lore raw

Hi Zenghui,

Quoted 6 lines · Zenghui Yu

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")

Thanks!

Eric

Quoted 20 lines
---
 hw/arm/virt-acpi-build.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
hw/arm/virt-acpi-build.c +2 -2
index f5a2b2d4cb..60fe2e65a7 100644
@@ -292,8 +292,8 @@ build_iort(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms)
         smmu->flags = cpu_to_le32(ACPI_IORT_SMMU_V3_COHACC_OVERRIDE);
         smmu->event_gsiv = cpu_to_le32(irq);
         smmu->pri_gsiv = cpu_to_le32(irq + 1);
-        smmu->gerr_gsiv = cpu_to_le32(irq + 2);
-        smmu->sync_gsiv = cpu_to_le32(irq + 3);
+        smmu->sync_gsiv = cpu_to_le32(irq + 2);
+        smmu->gerr_gsiv = cpu_to_le32(irq + 3);
 
         /* Identity RID mapping covering the whole input RID range */
         idmap = &smmu->id_mapping_array[0];
#2 lore raw
Quoted 11 lines · Auger Eric

Hi Zenghui,

Quoted 6 lines · Zenghui Yu

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")

Eric, when you send an acked-by tag do you mean to say that you've reviewed the patch, or merely that you think it's basically the right thing but you haven't actually looked at the details?

(I ask because if the former I can just put this in target-arm.next, but if the latter then I need to dig out the SMMU spec and review the patch myself :-))

thanks
-- PMM

#3 lore raw

Hi Peter,

Quoted 9 lines · Peter Maydell
Quoted 8 lines · Auger Eric

Hi Zenghui,

Quoted 4 lines · Zenghui Yu

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Quoted 7 lines
Quoted 3 lines
Quoted 2 lines
Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")

Eric, when you send an acked-by tag do you mean to say that you've reviewed the patch, or merely that you think it's basically the right thing but you haven't actually looked at the details?

I mean I have reviewed the patch carefully and I think it is good to go. I thought that as a maintainer for the arm smmu component I was supposed to send an A-b instead of an R-b.

Quoted 4 lines

(I ask because if the former I can just put this in target-arm.next, but if the latter then I need to dig out the SMMU spec and review the patch myself :-))

Yes that's rather the former but obviously if you have some cycles / interest in the topic I am more than happy to get your opinion too!

Thanks

Eric

Quoted 4 lines

thanks
-- PMM

#4 lore raw
Quoted 17 lines · Auger Eric

Hi Peter,

Quoted 13 lines · Peter Maydell
Quoted 11 lines · Auger Eric

Hi Zenghui,

Quoted 6 lines · Zenghui Yu

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")
Quoted 7 lines
Quoted 3 lines

Eric, when you send an acked-by tag do you mean to say that you've reviewed the patch, or merely that you think it's basically the right thing but you haven't actually looked at the details?

I mean I have reviewed the patch carefully and I think it is good to go. I thought that as a maintainer for the arm smmu component I was supposed to send an A-b instead of an R-b.

The usual meaning I think is that "Acked-by" means "I'm the maintainer, I've seen this going by, and I'm basically OK with this" (ie it's you saying "I'm not NAKing it") -- so it's not as "strong" as a "Reviewed-by" tag (which means "I've reviewed it").

thanks
-- PMM

#5 lore raw

Hi Peter,

Quoted 22 lines · Peter Maydell
Quoted 21 lines · Auger Eric

Hi Peter,

Quoted 16 lines · Peter Maydell
Quoted 11 lines · Auger Eric

Hi Zenghui,

Quoted 6 lines · Zenghui Yu

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")

Eric, when you send an acked-by tag do you mean to say that you've reviewed the patch, or merely that you think it's basically the right thing but you haven't actually looked at the details?

Quoted 8 lines
Quoted 3 lines

I mean I have reviewed the patch carefully and I think it is good to go. I thought that as a maintainer for the arm smmu component I was supposed to send an A-b instead of an R-b.

The usual meaning I think is that "Acked-by" means "I'm the maintainer, I've seen this going by, and I'm basically OK with this" (ie it's you saying "I'm not NAKing it") -- so it's not as "strong" as a "Reviewed-by" tag (which means "I've reviewed it").

Hum OK, I thought it was stronger than the R-b. So in the future, wrt the SMMU component, I will give an R-b as I always do a proper review.

Thanks

Eric

Quoted 4 lines

thanks
-- PMM

#6 lore raw
In reply to Zenghui Yu
Quoted 17 lines · Zenghui Yu

The GSIV values in SMMUv3 IORT node are not correct as they don't match the SMMUIrq enumeration, which describes the IRQ<->PIN mapping used by our emulated vSMMU.

Fixes a703b4f6c1ee ("hw/arm/virt-acpi-build: Add smmuv3 node in IORT table")
---
 hw/arm/virt-acpi-build.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
hw/arm/virt-acpi-build.c +0 -0
index f5a2b2d4cb..60fe2e65a7 100644
@@ -292,8 +292,8 @@ build_iort(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms)
         smmu->flags = cpu_to_le32(ACPI_IORT_SMMU_V3_COHACC_OVERRIDE);

hw/arm/virt-acpi-build.c build_iort(GArray *table_data, BIOSLinker *linker, VirtMachineState *vms)

Quoted 10 lines
hw/arm/virt-acpi-build.c +2 -3
         smmu->event_gsiv = cpu_to_le32(irq);
         smmu->pri_gsiv = cpu_to_le32(irq + 1);
-        smmu->gerr_gsiv = cpu_to_le32(irq + 2);
-        smmu->sync_gsiv = cpu_to_le32(irq + 3);
+        smmu->sync_gsiv = cpu_to_le32(irq + 2);
+        smmu->gerr_gsiv = cpu_to_le32(irq + 3);
 
         /* Identity RID mapping covering the whole input RID range */
         idmap = &smmu->id_mapping_array[0];
--

Applied to target-arm.next, thanks.

-- PMM