Subject: Re: linux-next: Tree for Jul 16 (drivers/vfio/cdx/intr.c)

From: Krzysztof Kozlowski <[email-masked]>
Date: Thu, 17 Jul 2025 08:52:04 +0200

On 17/07/2025 01:07, Randy Dunlap wrote:
> 
> 
> On 7/16/25 4:25 AM, Stephen Rothwell wrote:
>> Hi all,
>>
>> Changes since 20250715:
>>
> 
> on ARCH=um SUBARCH=x86_64:
> 
> ../drivers/vfio/cdx/intr.c: In function ‘vfio_cdx_msi_enable’:
> ../drivers/vfio/cdx/intr.c:41:15: error: implicit declaration of function ‘msi_domain_alloc_irqs’; did you mean ‘msi_domain_get_virq’? [-Wimplicit-function-declaration]
>    41 |         ret = msi_domain_alloc_irqs(dev, MSI_DEFAULT_DOMAIN, nvec);
>       |               ^~~~~~~~~~~~~~~~~~~~~
>       |               msi_domain_get_virq
> ../drivers/vfio/cdx/intr.c: In function ‘vfio_cdx_msi_disable’:
> ../drivers/vfio/cdx/intr.c:135:9: error: implicit declaration of function ‘msi_domain_free_irqs_all’ [-Wimplicit-function-declaration]
>   135 |         msi_domain_free_irqs_all(dev, MSI_DEFAULT_DOMAIN);
>       |         ^~~~~~~~~~~~~~~~~~~~~~~~
> 
> 
> Those missing functions are provided by CONFIG_GENERIC_MSI_IRQ
> (which is not set).
> 
> Should VFIO_CDX select GENERIC_MSI_IRQ or just not build on ARCH=um?

I think this will be also resolved with my change to select
GENERIC_MSI_IRQ by CDX_BUS, but to be fair, I think that VFIO_CDX should
also select GENERIC_MSI_IRQ. My reasoning is that:
1. GENERIC_MSI_IRQ is non-user selectable, thus it is supposed to be
selected by Kconfig entries
2. Every explicit user of a code should select such symbol, not rely on
someone else selecting it.

I will send a patch proposing this.

Best regards,
Krzysztof