genirq/msi: Provide msi_device_populate/destroy_sysfs()
Add new allocation functions which can be activated by domain info flags. They store the groups pointer in struct msi_device_data. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Tested-by: Michael Kelley <mikelley@microsoft.com> Tested-by: Nishanth Menon <nm@ti.com> Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Jason Gunthorpe <jgg@nvidia.com> Link: https://lore.kernel.org/r/20211210221813.988659194@linutronix.de
This commit is contained in:
parent
686073e9f8
commit
bf6e054e0e
2 changed files with 44 additions and 2 deletions
|
|
@ -56,6 +56,8 @@ struct irq_data;
|
|||
struct msi_desc;
|
||||
struct pci_dev;
|
||||
struct platform_msi_priv_data;
|
||||
struct attribute_group;
|
||||
|
||||
void __get_cached_msi_msg(struct msi_desc *entry, struct msi_msg *msg);
|
||||
#ifdef CONFIG_GENERIC_MSI_IRQ
|
||||
void get_cached_msi_msg(unsigned int irq, struct msi_msg *msg);
|
||||
|
|
@ -174,9 +176,11 @@ struct msi_desc {
|
|||
/**
|
||||
* msi_device_data - MSI per device data
|
||||
* @properties: MSI properties which are interesting to drivers
|
||||
* @attrs: Pointer to the sysfs attribute group
|
||||
*/
|
||||
struct msi_device_data {
|
||||
unsigned long properties;
|
||||
const struct attribute_group **attrs;
|
||||
};
|
||||
|
||||
int msi_setup_device_data(struct device *dev);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue