netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] net: thunderx: add 64-bit dependency
@ 2015-05-28 14:00 Arnd Bergmann
  2015-05-28 15:49 ` David Daney
  2015-05-31  6:39 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Arnd Bergmann @ 2015-05-28 14:00 UTC (permalink / raw)
  To: netdev
  Cc: David Miller, Sunil Goutham, Maciej Czekaj, David Daney,
	Sunil Goutham, Ganapatrao Kulkarni, Aleksey Makarov,
	Tomasz Nowicki, Robert Richter, Kamil Rytarowski,
	Thanneeru Srinivasulu, Sruthi Vangala

The thunderx ethernet driver fails to build on architectures
that do not have an atomic readq() and writeq() function for
64-bit PCI bus access:

drivers/net/ethernet/cavium/thunder/thunder_bgx.c: In function 'bgx_reg_read':
include/asm-generic/io.h:195:23: error: implicit declaration of function 'readq' [-Werror=implicit-function-declaration]

It seems impossible to get this driver to work on most 32-bit
hardware, so it's better to add an explicit dependency, in
order to let us keep building 'allmodconfig' kernels on
all architectures.

As the driver is meant for the internal hardware on an arm64 SoC, this
is not a problem for usability. Allowing the build on all 64-bit
architectures rather than just CONFIG_ARM64 on the other hand means that
we get the benefit of build testing on x86.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>

diff --git a/drivers/net/ethernet/cavium/Kconfig b/drivers/net/ethernet/cavium/Kconfig
index 6365fb4242be..fc3d8e3ee807 100644
--- a/drivers/net/ethernet/cavium/Kconfig
+++ b/drivers/net/ethernet/cavium/Kconfig
@@ -4,7 +4,7 @@
 
 config NET_VENDOR_CAVIUM
 	tristate "Cavium ethernet drivers"
-	depends on PCI
+	depends on PCI && 64BIT
 	---help---
 	  Enable support for the Cavium ThunderX Network Interface
 	  Controller (NIC). The NIC provides the controller and DMA

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

* Re: [PATCH] net: thunderx: add 64-bit dependency
  2015-05-28 14:00 [PATCH] net: thunderx: add 64-bit dependency Arnd Bergmann
@ 2015-05-28 15:49 ` David Daney
  2015-05-31  6:39 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Daney @ 2015-05-28 15:49 UTC (permalink / raw)
  To: Arnd Bergmann, David Miller
  Cc: netdev, Sunil Goutham, Maciej Czekaj, David Daney,
	Ganapatrao Kulkarni, Aleksey Makarov, Tomasz Nowicki,
	Robert Richter, Kamil Rytarowski, Thanneeru Srinivasulu,
	Sruthi Vangala

On 05/28/2015 07:00 AM, Arnd Bergmann wrote:
> The thunderx ethernet driver fails to build on architectures
> that do not have an atomic readq() and writeq() function for
> 64-bit PCI bus access:
>
> drivers/net/ethernet/cavium/thunder/thunder_bgx.c: In function 'bgx_reg_read':
> include/asm-generic/io.h:195:23: error: implicit declaration of function 'readq' [-Werror=implicit-function-declaration]
>
> It seems impossible to get this driver to work on most 32-bit
> hardware, so it's better to add an explicit dependency, in
> order to let us keep building 'allmodconfig' kernels on
> all architectures.
>
> As the driver is meant for the internal hardware on an arm64 SoC, this
> is not a problem for usability. Allowing the build on all 64-bit
> architectures rather than just CONFIG_ARM64 on the other hand means that
> we get the benefit of build testing on x86.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>


Thanks for the quick fix.  I agree with your analysis...

Acked-by: David Daney <david.daney@cavium.com>

>
> diff --git a/drivers/net/ethernet/cavium/Kconfig b/drivers/net/ethernet/cavium/Kconfig
> index 6365fb4242be..fc3d8e3ee807 100644
> --- a/drivers/net/ethernet/cavium/Kconfig
> +++ b/drivers/net/ethernet/cavium/Kconfig
> @@ -4,7 +4,7 @@
>
>   config NET_VENDOR_CAVIUM
>   	tristate "Cavium ethernet drivers"
> -	depends on PCI
> +	depends on PCI && 64BIT
>   	---help---
>   	  Enable support for the Cavium ThunderX Network Interface
>   	  Controller (NIC). The NIC provides the controller and DMA
>

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

* Re: [PATCH] net: thunderx: add 64-bit dependency
  2015-05-28 14:00 [PATCH] net: thunderx: add 64-bit dependency Arnd Bergmann
  2015-05-28 15:49 ` David Daney
@ 2015-05-31  6:39 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2015-05-31  6:39 UTC (permalink / raw)
  To: arnd
  Cc: netdev, sgoutham, mjc, david.daney, ganapatrao.kulkarni,
	aleksey.makarov, tomasz.nowicki, rrichter, kamil, tsrinivasulu,
	svangala

From: Arnd Bergmann <arnd@arndb.de>
Date: Thu, 28 May 2015 16:00:46 +0200

> The thunderx ethernet driver fails to build on architectures
> that do not have an atomic readq() and writeq() function for
> 64-bit PCI bus access:
> 
> drivers/net/ethernet/cavium/thunder/thunder_bgx.c: In function 'bgx_reg_read':
> include/asm-generic/io.h:195:23: error: implicit declaration of function 'readq' [-Werror=implicit-function-declaration]
> 
> It seems impossible to get this driver to work on most 32-bit
> hardware, so it's better to add an explicit dependency, in
> order to let us keep building 'allmodconfig' kernels on
> all architectures.
> 
> As the driver is meant for the internal hardware on an arm64 SoC, this
> is not a problem for usability. Allowing the build on all 64-bit
> architectures rather than just CONFIG_ARM64 on the other hand means that
> we get the benefit of build testing on x86.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Applied, thanks Arnd.

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

end of thread, other threads:[~2015-05-31  6:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-28 14:00 [PATCH] net: thunderx: add 64-bit dependency Arnd Bergmann
2015-05-28 15:49 ` David Daney
2015-05-31  6:39 ` David Miller

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).