public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] misc: mrvl-cn10k-dpi: add PCI_IOV dependency
@ 2024-07-19 10:38 Arnd Bergmann
  2024-07-19 11:05 ` [EXTERNAL] " Vamsi Krishna Attunuru
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2024-07-19 10:38 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Arnd Bergmann, Vamsi Attunuru, Srujana Challa, linux-kernel

From: Arnd Bergmann <arnd@arndb.de>

I found one more missing dependency in the new driver: when building
without CONFIG_PCI_IOV, pci_sriov_configure_simple() cannot be
called directly:

drivers/misc/mrvl_cn10k_dpi.c: In function 'dpi_remove':
include/linux/stddef.h:9:14: error: called object is not a function or function pointer
    9 | #define NULL ((void *)0)
      |              ^
include/linux/pci.h:2416:41: note: in expansion of macro 'NULL'
 2416 | #define pci_sriov_configure_simple      NULL
      |                                         ^~~~
drivers/misc/mrvl_cn10k_dpi.c:652:9: note: in expansion of macro 'pci_sriov_configure_simple'
  652 |         pci_sriov_configure_simple(pdev, 0);

Add this to the Kconfig file as well.

Fixes: 5f67eef6dff3 ("misc: mrvl-cn10k-dpi: add Octeon CN10K DPI administrative driver")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/misc/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig
index a1ae3f9c0707..b6f5733a6ee2 100644
--- a/drivers/misc/Kconfig
+++ b/drivers/misc/Kconfig
@@ -589,7 +589,7 @@ config NSM
 
 config MARVELL_CN10K_DPI
 	tristate "Octeon CN10K DPI driver"
-	depends on PCI
+	depends on PCI && PCI_IOV
 	depends on ARCH_THUNDER || (COMPILE_TEST && 64BIT)
 	help
 	  Enables Octeon CN10K DMA packet interface (DPI) driver which
-- 
2.39.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* RE: [EXTERNAL] [PATCH] misc: mrvl-cn10k-dpi: add PCI_IOV dependency
  2024-07-19 10:38 [PATCH] misc: mrvl-cn10k-dpi: add PCI_IOV dependency Arnd Bergmann
@ 2024-07-19 11:05 ` Vamsi Krishna Attunuru
  0 siblings, 0 replies; 2+ messages in thread
From: Vamsi Krishna Attunuru @ 2024-07-19 11:05 UTC (permalink / raw)
  To: Arnd Bergmann, Greg Kroah-Hartman
  Cc: Arnd Bergmann, Srujana Challa, linux-kernel@vger.kernel.org



>-----Original Message-----
>From: Arnd Bergmann <arnd@kernel.org>
>Sent: Friday, July 19, 2024 4:08 PM
>To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>Cc: Arnd Bergmann <arnd@arndb.de>; Vamsi Krishna Attunuru
><vattunuru@marvell.com>; Srujana Challa <schalla@marvell.com>; linux-
>kernel@vger.kernel.org
>Subject: [EXTERNAL] [PATCH] misc: mrvl-cn10k-dpi: add PCI_IOV dependency
>
>From: Arnd Bergmann <arnd@ arndb. de> I found one more missing
>dependency in the new driver: when building without CONFIG_PCI_IOV,
>pci_sriov_configure_simple() cannot be called directly:
>drivers/misc/mrvl_cn10k_dpi. c: In function 'dpi_remove':
>
>From: Arnd Bergmann <arnd@arndb.de>
>
>I found one more missing dependency in the new driver: when building
>without CONFIG_PCI_IOV, pci_sriov_configure_simple() cannot be called
>directly:
>
>drivers/misc/mrvl_cn10k_dpi.c: In function 'dpi_remove':
>include/linux/stddef.h:9:14: error: called object is not a function or function
>pointer
>    9 | #define NULL ((void *)0)
>      |              ^
>include/linux/pci.h:2416:41: note: in expansion of macro 'NULL'
> 2416 | #define pci_sriov_configure_simple      NULL
>      |                                         ^~~~
>drivers/misc/mrvl_cn10k_dpi.c:652:9: note: in expansion of macro
>'pci_sriov_configure_simple'
>  652 |         pci_sriov_configure_simple(pdev, 0);
>
>Add this to the Kconfig file as well.
>
>Fixes: 5f67eef6dff3 ("misc: mrvl-cn10k-dpi: add Octeon CN10K DPI
>administrative driver")
>Signed-off-by: Arnd Bergmann <arnd@arndb.de>
>---
> drivers/misc/Kconfig | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig index
>a1ae3f9c0707..b6f5733a6ee2 100644
>--- a/drivers/misc/Kconfig
>+++ b/drivers/misc/Kconfig
>@@ -589,7 +589,7 @@ config NSM
>
> config MARVELL_CN10K_DPI
> 	tristate "Octeon CN10K DPI driver"
>-	depends on PCI
>+	depends on PCI && PCI_IOV
> 	depends on ARCH_THUNDER || (COMPILE_TEST && 64BIT)
> 	help
> 	  Enables Octeon CN10K DMA packet interface (DPI) driver which
>--
>2.39.2

Ohk, my apologies for that. Arnd, thank you for the solution.

Tested-by: Vamsi Attunuru <vattunuru@marvell.com>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-07-19 11:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-19 10:38 [PATCH] misc: mrvl-cn10k-dpi: add PCI_IOV dependency Arnd Bergmann
2024-07-19 11:05 ` [EXTERNAL] " Vamsi Krishna Attunuru

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox