From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: davinci: only use NVMEM when available
Date: Thu, 17 Mar 2016 11:30:17 +0100 [thread overview]
Message-ID: <2137949.xUV6PQJbIO@wuerfel> (raw)
In-Reply-To: <56EA8654.5070100@linaro.org>
On Thursday 17 March 2016 10:26:28 Srinivas Kandagatla wrote:
> Thanks for the patch,
>
> On 15/03/16 21:34, Arnd Bergmann wrote:
> > The davinci platform contains code that calls into the nvmem
> > subsystem, but that might be a loadable module, causing a
> > link error:
> >
> > arch/arm/mach-davinci/built-in.o: In function `davinci_get_mac_addr':
> > :(.text+0x1088): undefined reference to `nvmem_device_read'
> > arch/arm/mach-davinci/built-in.o: In function `read_factory_config':
> > :(.text+0x214c): undefined reference to `nvmem_device_read'
> >
> This fix does not look correct to me.
>
> IMO, This is a issue with incorrect dependencies in the Kconfig, we
> should not attempt to fix it in the code, rather fix the kconfig
> dependencies in the mach-davnici or the EEPROM_AT24 kconfig itself. one
> of them should select the NVMEM.
Those 'select' statements are an endless source of trouble. The code
already builds fine if NVMEM is disabled (falling back to inline
stub calls), or if NVMEM is built-in and AT24 is not present (leading
to the call failing later), and that seems to be a reasonable fallback
for users that really don't want those drivers.
Arnd
next prev parent reply other threads:[~2016-03-17 10:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-15 21:34 [PATCH] ARM: davinci: only use NVMEM when available Arnd Bergmann
2016-03-17 10:26 ` Srinivas Kandagatla
2016-03-17 10:30 ` Arnd Bergmann [this message]
2016-04-12 6:59 ` Sekhar Nori
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=2137949.xUV6PQJbIO@wuerfel \
--to=arnd@arndb.de \
--cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox