From: Maxime Ripard <maxime.ripard@free-electrons.com>
To: Andrey Smirnov <andrew.smirnov@gmail.com>
Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
linux-kernel@vger.kernel.org,
Sascha Hauer <s.hauer@pengutronix.de>,
Trent Piepho <tpiepho@kymetacorp.com>
Subject: Re: [RESEND RFC 2/3] nvmem: Add 'nvmem-blob' driver
Date: Mon, 7 Mar 2016 09:18:42 +0100 [thread overview]
Message-ID: <20160307081842.GA8418@lukather> (raw)
In-Reply-To: <CAHQ1cqF5aaf2LUtLxychn8gD=mG7M4CLP2ahRtgNPS34dJao0g@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 2224 bytes --]
Hi,
On Wed, Mar 02, 2016 at 09:21:01AM -0800, Andrey Smirnov wrote:
> On Wed, Mar 2, 2016 at 5:58 AM, Srinivas Kandagatla
> <srinivas.kandagatla@linaro.org> wrote:
> >
> >
> > On 01/03/16 16:59, Andrey Smirnov wrote:
> >>
> >> Add 'nvmem-blob' driver, which allows to access device tree embedded
> >> data via NVMEM subsystem API.
> >
> >
> > Patch itself looks simple. Before we review it further could you provide
> > more details on the exact usecase or some background of this.
>
> The discussion on this topic originated on mailing list of Barebox
> project(which borrows very heavily from Linux designs). Barebox
> operates on two device tree blobs, one is used for its internal
> initialization, whereas second one is passed to Linux kernel when
> booting it. The problem I was trying to solve was to make possible to
> specify in the first DT blob what data would be used for MAC address
> fixup of the second DT blob(the one passed to Linux).
>
> My first approach was to implement a very limited DT code, however in
> discussing it the consensus was that porting 'nvmem' subsystem from
> the kernel and using for the same purpose would be a better approach.
> First pass adoption of that subsystem revealed that there were two
> use-cases that current design didn't allow us to handle:
>
> - Depending on the version i.MX SoC MAC address data stored in ROM
> would have different layout so as a possible solution to that I
> implemented "composite" driver(patch #3)
>
> - On i.MX28, part of the MAC address is hard-coded in
> arch/arm/mach-mxs/mach-mxs.c and only a portion of it is read from
> ROM, this patch in combination with the aforementioned one should
> allow us to encode all needed info in DT.
>
> Ideally, since all of the above is as applicable to Linux as it is to
> Barebox it would be good for BB not to invent its own custom 'nvmem'
> flavor, so hence me trying to start a conversation about adding this
> upstream.
If the only use-case is to store the MAC address, why not using the
local-mac-address property directly?
Maxime
--
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2016-03-07 8:18 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-01 16:59 [RESEND RFC 0/3] Proposed extensions for NVMEM Andrey Smirnov
2016-03-01 16:59 ` [RESEND RFC 1/3] nvmem: Add 'of_nvmem_cell_from_device_node()' Andrey Smirnov
2016-03-02 13:58 ` Srinivas Kandagatla
2016-03-02 18:11 ` Andrey Smirnov
2016-03-01 16:59 ` [RESEND RFC 2/3] nvmem: Add 'nvmem-blob' driver Andrey Smirnov
2016-03-02 13:58 ` Srinivas Kandagatla
2016-03-02 17:21 ` Andrey Smirnov
2016-03-07 8:18 ` Maxime Ripard [this message]
2016-03-08 4:07 ` Andrey Smirnov
2016-03-08 22:28 ` Maxime Ripard
2016-03-08 22:46 ` Andrey Smirnov
2016-03-08 23:24 ` Trent Piepho
2016-03-09 10:13 ` Maxime Ripard
2016-03-09 19:50 ` Trent Piepho
2016-03-09 9:58 ` Maxime Ripard
2016-03-09 17:04 ` Andrey Smirnov
2016-03-09 7:59 ` Sascha Hauer
2016-03-01 16:59 ` [RESEND RFC 3/3] nvmem: Add 'nvmem-composite' driver Andrey Smirnov
2016-03-02 13:59 ` Srinivas Kandagatla
2016-03-02 18:33 ` Andrey Smirnov
2016-03-17 11:26 ` Srinivas Kandagatla
2016-03-21 16:12 ` Andrey Smirnov
2016-03-21 16:56 ` Srinivas Kandagatla
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=20160307081842.GA8418@lukather \
--to=maxime.ripard@free-electrons.com \
--cc=andrew.smirnov@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=s.hauer@pengutronix.de \
--cc=srinivas.kandagatla@linaro.org \
--cc=tpiepho@kymetacorp.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;
as well as URLs for NNTP newsgroup(s).