Commit 06bff9e3 authored by Thomas Gleixner's avatar Thomas Gleixner

genirq/msi: Provide struct msi_map

A simple struct to hold a MSI index / Linux interrupt number pair. It will
be returned from the dynamic vector allocation function and handed back to
the corresponding free() function.
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Reviewed-by: default avatarKevin Tian <kevin.tian@intel.com>
Acked-by: default avatarMarc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20221124232326.326410494@linutronix.de
parent 4d5a4ccc
......@@ -18,6 +18,19 @@ enum msi_domain_ids {
MSI_MAX_DEVICE_IRQDOMAINS,
};
/**
* msi_map - Mapping between MSI index and Linux interrupt number
* @index: The MSI index, e.g. slot in the MSI-X table or
* a software managed index if >= 0. If negative
* the allocation function failed and it contains
* the error code.
* @virq: The associated Linux interrupt number
*/
struct msi_map {
int index;
int virq;
};
unsigned int msi_domain_get_virq(struct device *dev, unsigned int domid, unsigned int index);
/**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment