Re: [PATCH 3/7] of/iommu: add multi-map support

From: Robin Murphy

Date: Tue Jan 27 2026 - 09:25:42 EST


On 2026-01-27 11:45 am, Dmitry Baryshkov wrote:
On Mon, Jan 26, 2026 at 05:55:46PM +0530, Vikash Garodia wrote:
From: Charan Teja Kalla <charan.kalla@xxxxxxxxxxxxxxxx>

When multiple mappings are present for an input id, linux matches just
the first one. There is a usecase[1] where all the mappings are to be
maintained in parallel for an iommu-map entry of a same input id.

This contradicts the IOMMU idealogy (at least as far as I understood it
fom the maintainers): the device (driver) doesn't control which IOMMUs
are getting used. Instead _all_ defined entries should get used. For
iommu-map it means that if the map defines several entries for a single
function, then all entries should always get mapped.

Indeed there is no concept of "multi-map" - if a single input ID represents more than one thing then that notion of "input ID" is fundamentally wrong. A single *device* may have multiple IDs, as in the case of PCI bridge aliasing, but in that case there are multiple things to map.

Thanks,
Robin.