* Re: [PATCH] vfio: fix link failures when CONFIG_PCI_MSI is disabled [not found] <20160203205108.GA9181@charon.olymp> @ 2016-02-12 18:17 ` Alex Williamson 2016-02-17 15:37 ` Luis Henriques [not found] ` <1455743138-17224-1-git-send-email-luis.henriques@canonical.com> 1 sibling, 1 reply; 3+ messages in thread From: Alex Williamson @ 2016-02-12 18:17 UTC (permalink / raw) To: Luis Henriques; +Cc: kvm, linux-kernel, linux-pci@vger.kernel.org On Wed, 3 Feb 2016 20:51:08 +0000 Luis Henriques <luis.henriques@canonical.com> wrote: > The following link failure occurs when CONFIG_PCI_MSI is not set: > > drivers/built-in.o: In function `vfio_msi_set_vector_signal': > :(.text+0x626640): undefined reference to `pci_write_msi_msg' > > Signed-off-by: Luis Henriques <luis.henriques@canonical.com> > --- > drivers/vfio/pci/Kconfig | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/vfio/pci/Kconfig b/drivers/vfio/pci/Kconfig > index 02912f180c6d..b9dbfc9aeee1 100644 > --- a/drivers/vfio/pci/Kconfig > +++ b/drivers/vfio/pci/Kconfig > @@ -1,6 +1,6 @@ > config VFIO_PCI > tristate "VFIO support for PCI devices" > - depends on VFIO && PCI && EVENTFD > + depends on VFIO && PCI_MSI && EVENTFD > select VFIO_VIRQFD > select IRQ_BYPASS_MANAGER > help > It seems like a better solution would be to have pci stub these out with static inlines when !CONFIG_PCI_MSI, we already do that for quite a lot of MSI and MSI-X callbacks. MSI/X on the device clearly won't work if the host doesn't support MSI, and maybe there are improvements to be made there, but MSI is a subcomponent of vfio-pci, the module itself shouldn't depend on MSI. Thanks, Alex ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] vfio: fix link failures when CONFIG_PCI_MSI is disabled 2016-02-12 18:17 ` [PATCH] vfio: fix link failures when CONFIG_PCI_MSI is disabled Alex Williamson @ 2016-02-17 15:37 ` Luis Henriques 0 siblings, 0 replies; 3+ messages in thread From: Luis Henriques @ 2016-02-17 15:37 UTC (permalink / raw) To: Alex Williamson; +Cc: kvm, linux-kernel, linux-pci@vger.kernel.org On Fri, Feb 12, 2016 at 11:17:58AM -0700, Alex Williamson wrote: > On Wed, 3 Feb 2016 20:51:08 +0000 > Luis Henriques <luis.henriques@canonical.com> wrote: > > > The following link failure occurs when CONFIG_PCI_MSI is not set: > > > > drivers/built-in.o: In function `vfio_msi_set_vector_signal': > > :(.text+0x626640): undefined reference to `pci_write_msi_msg' > > > > Signed-off-by: Luis Henriques <luis.henriques@canonical.com> > > --- > > drivers/vfio/pci/Kconfig | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/vfio/pci/Kconfig b/drivers/vfio/pci/Kconfig > > index 02912f180c6d..b9dbfc9aeee1 100644 > > --- a/drivers/vfio/pci/Kconfig > > +++ b/drivers/vfio/pci/Kconfig > > @@ -1,6 +1,6 @@ > > config VFIO_PCI > > tristate "VFIO support for PCI devices" > > - depends on VFIO && PCI && EVENTFD > > + depends on VFIO && PCI_MSI && EVENTFD > > select VFIO_VIRQFD > > select IRQ_BYPASS_MANAGER > > help > > > > > It seems like a better solution would be to have pci stub these out > with static inlines when !CONFIG_PCI_MSI, we already do that for quite > a lot of MSI and MSI-X callbacks. MSI/X on the device clearly won't > work if the host doesn't support MSI, and maybe there are improvements > to be made there, but MSI is a subcomponent of vfio-pci, the module > itself shouldn't depend on MSI. Thanks, > > Alex > Thanks for reviewing. I'll submit a new patch later today, stubbing pci_write_msi_msg() to fix this failure. Cheers, -- Luís ^ permalink raw reply [flat|nested] 3+ messages in thread
[parent not found: <1455743138-17224-1-git-send-email-luis.henriques@canonical.com>]
* Re: [PATCH] PCI/MSI: stub pci_write_msi_msg when CONFIG_PCI_MSI is disabled [not found] ` <1455743138-17224-1-git-send-email-luis.henriques@canonical.com> @ 2016-02-17 21:19 ` Alex Williamson 0 siblings, 0 replies; 3+ messages in thread From: Alex Williamson @ 2016-02-17 21:19 UTC (permalink / raw) To: Luis Henriques Cc: kvm, linux-kernel, Bjorn Helgaas, linux-pci@vger.kernel.org [cc +bjorn, +linux-pci] On Wed, 17 Feb 2016 21:05:38 +0000 Luis Henriques <luis.henriques@canonical.com> wrote: > Stubbing function pci_write_msi_msg when CONFIG_PCI_MSI is disabled fixes > a link failure in vfio: > > drivers/built-in.o: In function `vfio_msi_set_vector_signal': > :(.text+0x626640): undefined reference to `pci_write_msi_msg' > > Signed-off-by: Luis Henriques <luis.henriques@canonical.com> > --- > include/linux/msi.h | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/include/linux/msi.h b/include/linux/msi.h > index a2a0068a8387..09dc375d11d8 100644 > --- a/include/linux/msi.h > +++ b/include/linux/msi.h > @@ -105,18 +105,19 @@ struct msi_desc { > > struct pci_dev *msi_desc_to_pci_dev(struct msi_desc *desc); > void *msi_desc_to_pci_sysdata(struct msi_desc *desc); > +void pci_write_msi_msg(unsigned int irq, struct msi_msg *msg); > #else /* CONFIG_PCI_MSI */ > static inline void *msi_desc_to_pci_sysdata(struct msi_desc *desc) > { > return NULL; > } > +static inline void pci_write_msi_msg(unsigned int irq, struct msi_msg *msg) { } > #endif /* CONFIG_PCI_MSI */ > > struct msi_desc *alloc_msi_entry(struct device *dev); > void free_msi_entry(struct msi_desc *entry); > void __pci_read_msi_msg(struct msi_desc *entry, struct msi_msg *msg); > void __pci_write_msi_msg(struct msi_desc *entry, struct msi_msg *msg); > -void pci_write_msi_msg(unsigned int irq, struct msi_msg *msg); > > u32 __pci_msix_desc_mask_irq(struct msi_desc *desc, u32 flag); > u32 __pci_msi_desc_mask_irq(struct msi_desc *desc, u32 mask, u32 flag); ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-02-17 21:19 UTC | newest] Thread overview: 3+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- [not found] <20160203205108.GA9181@charon.olymp> 2016-02-12 18:17 ` [PATCH] vfio: fix link failures when CONFIG_PCI_MSI is disabled Alex Williamson 2016-02-17 15:37 ` Luis Henriques [not found] ` <1455743138-17224-1-git-send-email-luis.henriques@canonical.com> 2016-02-17 21:19 ` [PATCH] PCI/MSI: stub pci_write_msi_msg " Alex Williamson
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).