On Wed, Jul 21, 2021 at 05:17:21PM +0800, Ming Lei wrote: > +bool device_has_managed_msi_irq(struct device *dev) > +{ > + struct msi_desc *desc; > + > + if (IS_ENABLED(CONFIG_GENERIC_MSI_IRQ)) { And inline stub for the !CONFIG_GENERIC_MSI_IRQ would seem nicer so that we don't even nee the call. Also please add a kerneldoc comment, and as Greg said this probably doesn't belong into drivers/base and device.h but something in the irq layer. Maybe Thomas has a preference.