Netdev List
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Jakub Kicinski <jakub.kicinski@netronome.com>
Cc: Simon Horman <simon.horman@netronome.com>,
	Arnd Bergmann <arnd@arndb.de>,
	"David S. Miller" <davem@davemloft.net>,
	oss-drivers@netronome.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH net-next] nfp: add MAY_USE_DEVLINK dependency
Date: Wed, 31 May 2017 10:16:50 +0200	[thread overview]
Message-ID: <20170531081700.1948289-1-arnd@arndb.de> (raw)

When devlink is configured as a loadable module, a built-in nfp driver
causes a link error:

drivers/net/built-in.o: In function `nfp_devlink_port_register':
(.text+0xb8b05): undefined reference to `devlink_port_type_eth_set'
drivers/net/built-in.o: In function `nfp_devlink_port_register':
(.text+0xb8b16): undefined reference to `devlink_port_split_set'

This adds a special Kconfig dependency on CONFIG_MAY_USE_DEVLINK
to avoid that combination and force nfp to be a module when NET_DEVLINK=m.

Fixes: 1851f93fd2ee ("nfp: add devlink support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/net/ethernet/netronome/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/netronome/Kconfig b/drivers/net/ethernet/netronome/Kconfig
index 967d7ca8c28c..0d5a7b9203a4 100644
--- a/drivers/net/ethernet/netronome/Kconfig
+++ b/drivers/net/ethernet/netronome/Kconfig
@@ -19,6 +19,7 @@ config NFP
 	tristate "Netronome(R) NFP4000/NFP6000 NIC driver"
 	depends on PCI && PCI_MSI
 	depends on VXLAN || VXLAN=n
+	depends on MAY_USE_DEVLINK
 	---help---
 	  This driver supports the Netronome(R) NFP4000/NFP6000 based
 	  cards working as a advanced Ethernet NIC.  It works with both
-- 
2.9.0

             reply	other threads:[~2017-05-31  8:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-31  8:16 Arnd Bergmann [this message]
2017-05-31  8:57 ` [PATCH net-next] nfp: add MAY_USE_DEVLINK dependency Jakub Kicinski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170531081700.1948289-1-arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=jakub.kicinski@netronome.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=oss-drivers@netronome.com \
    --cc=simon.horman@netronome.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox