diff options
| author | Vincent Jardin <[email protected]> | 2026-07-30 00:21:17 +0200 |
|---|---|---|
| committer | Peng Fan <[email protected]> | 2026-08-11 15:48:22 +0800 |
| commit | 289b1bae1c798b12729f5467fcb34fffa49ef9a8 (patch) | |
| tree | 25012a778310661ca6fac5e343dce649a4a7017f | |
| parent | d13ee7acafb93a8b8753083ee82a594da121f745 (diff) | |
pci: layerscape: fix pci_iommu_extra hotplug
We can have many pci hotplug groups, each introduced
by a "pci@<addr>" token such as,
pci_iommu_extra=pci@0x3600000,1.0.0,hp,pci@0x3700000,1.0.0,hp,
pci@0x3800000,1.0.0,hp,pci@0x3900000,1.0.0,hp
Without this fix, we have the error:
Added iommu map for hotplug 1.0.0
ERROR: invalid action in extra iommu entry
ERROR: invalid action in extra iommu entry
ERROR: invalid action in extra iommu entry
Fixes: 2a5bbb13cc39 ("pci: layerscape: add a way of specifying additional iommu mappings")
Signed-off-by: Vincent Jardin <[email protected]>
Reviewed-by: Neil Armstrong <[email protected]>
Signed-off-by: Peng Fan <[email protected]>
| -rw-r--r-- | drivers/pci/pcie_layerscape_fixup.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/pci/pcie_layerscape_fixup.c b/drivers/pci/pcie_layerscape_fixup.c index 97c38c0bfa7..5299aee63db 100644 --- a/drivers/pci/pcie_layerscape_fixup.c +++ b/drivers/pci/pcie_layerscape_fixup.c @@ -319,6 +319,11 @@ static struct extra_iommu_entry *get_extra_iommu_ents(void *blob, /* Hot-plug entry */ entries[i].action = EXTRA_IOMMU_ENTRY_HOTPLUG; p += 2; + /* Skip the comma separator so it check the + * next "pci@" group. + */ + if (*p == ',') + p++; } else if (!strncmp(p, "vfs", 3) || !strncmp(p, "noari_vfs", 9)) { /* VFs or VFs with ARI disabled entry */ |
