All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: netdev@vger.kernel.org
Cc: Arnd Bergmann <arnd@arndb.de>,
	linux-pcmcia@lists.infradead.org, jeffrey.t.kirsher@intel.com,
	kas@fi.muni.cz, davem@davemloft.net,
	linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/4] net: cs89x0: always build platform code if !HAS_IOPORT_MAP
Date: Wed, 28 Jan 2015 15:15:01 +0100	[thread overview]
Message-ID: <1422454504-439085-2-git-send-email-arnd@arndb.de> (raw)
In-Reply-To: <1422454504-439085-1-git-send-email-arnd@arndb.de>

The cs89x0 driver can either be built as an ISA driver or a platform
driver, the choice is controlled by the CS89x0_PLATFORM Kconfig
symbol. Building the ISA driver on a system that does not have
a way to map I/O ports fails with this error:

drivers/built-in.o: In function `cs89x0_ioport_probe.constprop.1':
:(.init.text+0x4794): undefined reference to `ioport_map'
:(.init.text+0x4830): undefined reference to `ioport_unmap'

This changes the Kconfig logic to take that option away and
always force building the platform variant of this driver if
CONFIG_HAS_IOPORT_MAP is not set. This is the only correct
choice in this case, and it avoids the build error.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/net/ethernet/cirrus/Kconfig | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/cirrus/Kconfig b/drivers/net/ethernet/cirrus/Kconfig
index 7403dff8f14a..905ac5f5d9a6 100644
--- a/drivers/net/ethernet/cirrus/Kconfig
+++ b/drivers/net/ethernet/cirrus/Kconfig
@@ -32,7 +32,8 @@ config CS89x0
 	  will be called cs89x0.
 
 config CS89x0_PLATFORM
-	bool "CS89x0 platform driver support"
+	bool "CS89x0 platform driver support" if HAS_IOPORT_MAP
+	default !HAS_IOPORT_MAP
 	depends on CS89x0
 	help
 	  Say Y to compile the cs89x0 driver as a platform driver. This
-- 
2.1.0.rc2

WARNING: multiple messages have this Message-ID (diff)
From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/4] net: cs89x0: always build platform code if !HAS_IOPORT_MAP
Date: Wed, 28 Jan 2015 15:15:01 +0100	[thread overview]
Message-ID: <1422454504-439085-2-git-send-email-arnd@arndb.de> (raw)
In-Reply-To: <1422454504-439085-1-git-send-email-arnd@arndb.de>

The cs89x0 driver can either be built as an ISA driver or a platform
driver, the choice is controlled by the CS89x0_PLATFORM Kconfig
symbol. Building the ISA driver on a system that does not have
a way to map I/O ports fails with this error:

drivers/built-in.o: In function `cs89x0_ioport_probe.constprop.1':
:(.init.text+0x4794): undefined reference to `ioport_map'
:(.init.text+0x4830): undefined reference to `ioport_unmap'

This changes the Kconfig logic to take that option away and
always force building the platform variant of this driver if
CONFIG_HAS_IOPORT_MAP is not set. This is the only correct
choice in this case, and it avoids the build error.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/net/ethernet/cirrus/Kconfig | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/cirrus/Kconfig b/drivers/net/ethernet/cirrus/Kconfig
index 7403dff8f14a..905ac5f5d9a6 100644
--- a/drivers/net/ethernet/cirrus/Kconfig
+++ b/drivers/net/ethernet/cirrus/Kconfig
@@ -32,7 +32,8 @@ config CS89x0
 	  will be called cs89x0.
 
 config CS89x0_PLATFORM
-	bool "CS89x0 platform driver support"
+	bool "CS89x0 platform driver support" if HAS_IOPORT_MAP
+	default !HAS_IOPORT_MAP
 	depends on CS89x0
 	help
 	  Say Y to compile the cs89x0 driver as a platform driver. This
-- 
2.1.0.rc2

  reply	other threads:[~2015-01-28 14:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-28 14:15 [PATCH 0/4] net: driver fixes from arm randconfig builds Arnd Bergmann
2015-01-28 14:15 ` Arnd Bergmann
2015-01-28 14:15 ` Arnd Bergmann [this message]
2015-01-28 14:15   ` [PATCH 1/4] net: cs89x0: always build platform code if !HAS_IOPORT_MAP Arnd Bergmann
2015-01-28 14:15 ` [PATCH 2/4] net: wan: add missing virt_to_bus dependencies Arnd Bergmann
2015-01-28 14:15   ` Arnd Bergmann
2015-01-28 16:19   ` Jan Kasprzak
2015-01-28 16:19     ` Jan Kasprzak
2015-01-28 14:15 ` [PATCH 3/4] net: lance,ni64: don't build for ARM Arnd Bergmann
2015-01-28 14:15   ` Arnd Bergmann
2015-01-28 14:15 ` [PATCH 4/4] net: am2150: fix nmclan_cs.c shared interrupt handling Arnd Bergmann
2015-01-28 14:15   ` Arnd Bergmann
2015-01-29 23:08 ` [PATCH 0/4] net: driver fixes from arm randconfig builds David Miller
2015-01-29 23:08   ` David Miller

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=1422454504-439085-2-git-send-email-arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=jeffrey.t.kirsher@intel.com \
    --cc=kas@fi.muni.cz \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-pcmcia@lists.infradead.org \
    --cc=netdev@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.