netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] [net-next] net: systemport: add NET_DSA dependency
@ 2017-10-16 11:32 Arnd Bergmann
  2017-10-16 17:55 ` Florian Fainelli
  2017-10-16 20:21 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Arnd Bergmann @ 2017-10-16 11:32 UTC (permalink / raw)
  To: Florian Fainelli
  Cc: Arnd Bergmann, David S. Miller, Michael Chan, Sathya Perla,
	Nicolas Pitre, netdev, linux-kernel

The notifier cause a link error when NET_DSA is a loadable
module:

drivers/net/ethernet/broadcom/bcmsysport.o: In function `bcm_sysport_remove':
bcmsysport.c:(.text+0x1582): undefined reference to `unregister_dsa_notifier'
drivers/net/ethernet/broadcom/bcmsysport.o: In function `bcm_sysport_probe':
bcmsysport.c:(.text+0x278d): undefined reference to `register_dsa_notifier'

This adds a dependency that forces the systemport driver to be
a loadable module as well when that happens, but otherwise
allows it to be built normally when DSA is either built-in or
completely disabled.

Fixes: d156576362c0 ("net: systemport: Establish lower/upper queue mapping")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/net/ethernet/broadcom/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/broadcom/Kconfig b/drivers/net/ethernet/broadcom/Kconfig
index 67134ece1107..af75156919ed 100644
--- a/drivers/net/ethernet/broadcom/Kconfig
+++ b/drivers/net/ethernet/broadcom/Kconfig
@@ -184,6 +184,7 @@ config BGMAC_PLATFORM
 config SYSTEMPORT
 	tristate "Broadcom SYSTEMPORT internal MAC support"
 	depends on OF
+	depends on NET_DSA || !NET_DSA
 	select MII
 	select PHYLIB
 	select FIXED_PHY
-- 
2.9.0

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

* Re: [PATCH] [net-next] net: systemport: add NET_DSA dependency
  2017-10-16 11:32 [PATCH] [net-next] net: systemport: add NET_DSA dependency Arnd Bergmann
@ 2017-10-16 17:55 ` Florian Fainelli
  2017-10-16 20:21 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: Florian Fainelli @ 2017-10-16 17:55 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: David S. Miller, Michael Chan, Sathya Perla, Nicolas Pitre,
	netdev, linux-kernel

On 10/16/2017 04:32 AM, Arnd Bergmann wrote:
> The notifier cause a link error when NET_DSA is a loadable
> module:
> 
> drivers/net/ethernet/broadcom/bcmsysport.o: In function `bcm_sysport_remove':
> bcmsysport.c:(.text+0x1582): undefined reference to `unregister_dsa_notifier'
> drivers/net/ethernet/broadcom/bcmsysport.o: In function `bcm_sysport_probe':
> bcmsysport.c:(.text+0x278d): undefined reference to `register_dsa_notifier'
> 
> This adds a dependency that forces the systemport driver to be
> a loadable module as well when that happens, but otherwise
> allows it to be built normally when DSA is either built-in or
> completely disabled.
> 
> Fixes: d156576362c0 ("net: systemport: Establish lower/upper queue mapping")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>

Thanks Arnd.
-- 
Florian

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

* Re: [PATCH] [net-next] net: systemport: add NET_DSA dependency
  2017-10-16 11:32 [PATCH] [net-next] net: systemport: add NET_DSA dependency Arnd Bergmann
  2017-10-16 17:55 ` Florian Fainelli
@ 2017-10-16 20:21 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2017-10-16 20:21 UTC (permalink / raw)
  To: arnd
  Cc: f.fainelli, michael.chan, sathya.perla, nicolas.pitre, netdev,
	linux-kernel

From: Arnd Bergmann <arnd@arndb.de>
Date: Mon, 16 Oct 2017 13:32:36 +0200

> The notifier cause a link error when NET_DSA is a loadable
> module:
> 
> drivers/net/ethernet/broadcom/bcmsysport.o: In function `bcm_sysport_remove':
> bcmsysport.c:(.text+0x1582): undefined reference to `unregister_dsa_notifier'
> drivers/net/ethernet/broadcom/bcmsysport.o: In function `bcm_sysport_probe':
> bcmsysport.c:(.text+0x278d): undefined reference to `register_dsa_notifier'
> 
> This adds a dependency that forces the systemport driver to be
> a loadable module as well when that happens, but otherwise
> allows it to be built normally when DSA is either built-in or
> completely disabled.
> 
> Fixes: d156576362c0 ("net: systemport: Establish lower/upper queue mapping")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Applied, thank you.

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

end of thread, other threads:[~2017-10-16 20:21 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-16 11:32 [PATCH] [net-next] net: systemport: add NET_DSA dependency Arnd Bergmann
2017-10-16 17:55 ` Florian Fainelli
2017-10-16 20:21 ` 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).