irqdomain: Add irq domain MSI and MSI_REMAP flags
authorEric Auger <eric.auger@redhat.com>
Thu, 19 Jan 2017 20:57:57 +0000 (20:57 +0000)
committerWill Deacon <will.deacon@arm.com>
Mon, 23 Jan 2017 15:00:44 +0000 (15:00 +0000)
commit631a9639ac413da6242cb15558ebd661cf633622
tree02bd936b0fae2a4b8410550de6ed63bb1aff8ac8
parent50019f09a4baa0bd6635d4933c1bfed22d66b640
irqdomain: Add irq domain MSI and MSI_REMAP flags

We introduce two new enum values for the irq domain flag:
- IRQ_DOMAIN_FLAG_MSI indicates the irq domain corresponds to
  an MSI domain
- IRQ_DOMAIN_FLAG_MSI_REMAP indicates the irq domain has MSI
  remapping capabilities.

Those values will be useful to check all MSI irq domains have
MSI remapping support when assessing the safety of IRQ assignment
to a guest.

irq_domain_hierarchical_is_msi_remap() allows to check if an
irq domain or any parent implements MSI remapping.

Signed-off-by: Eric Auger <eric.auger@redhat.com>
Reviewed-by: Marc Zyngier <marc.zyngier@arm.com>
Reviewed-by: Tomasz Nowicki <tomasz.nowicki@caviumnetworks.com>
Tested-by: Tomasz Nowicki <tomasz.nowicki@caviumnetworks.com>
Tested-by: Bharat Bhushan <bharat.bhushan@nxp.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
include/linux/irqdomain.h
kernel/irq/irqdomain.c