[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2137949.xUV6PQJbIO@wuerfel>
Date: Thu, 17 Mar 2016 11:30:17 +0100
From: Arnd Bergmann <arnd@...db.de>
To: Srinivas Kandagatla <srinivas.kandagatla@...aro.org>
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Sekhar Nori <nsekhar@...com>,
Kevin Hilman <khilman@...nel.org>,
Andrew Lunn <andrew@...n.ch>, Wolfram Sang <wsa@...-dreams.de>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] ARM: davinci: only use NVMEM when available
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
Powered by blists - more mailing lists