From: Boris Brezillon <boris.brezillon@bootlin.com>
To: Paul Cercueil <paul@crapouillou.net>
Cc: Mark Rutland <mark.rutland@arm.com>,
David Woodhouse <dwmw2@infradead.org>,
linux-mtd@lists.infradead.org, Rob Herring <robh+dt@kernel.org>,
linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
Brian Norris <computersforpeace@gmail.com>,
Richard Weinberger <richard@nod.at>,
Boris Brezillon <boris.brezillon@bolin.com>,
Marek Vasut <marek.vasut@gmail.com>
Subject: Re: [PATCH] mtd: nand: Add support for reading ooblayout from device tree
Date: Sat, 12 May 2018 15:42:23 +0200 [thread overview]
Message-ID: <20180512154223.3b81c7f7@bbrezillon> (raw)
In-Reply-To: <20180512115551.56C6E20787@mail.bootlin.com>
On Sat, 12 May 2018 08:55:40 -0300
Paul Cercueil <paul@crapouillou.net> wrote:
> Hi Boris,
>
> Le 12 mai 2018 02:55, Boris Brezillon <boris.brezillon@bootlin.com> a écrit :
> >
> > Hi Paul,
> >
> > On Fri, 11 May 2018 23:29:12 +0200
> > Paul Cercueil <paul@crapouillou.net> wrote:
> >
> > > By specifying the properties "mtd-oob-ecc" and "mtd-oob-free", it is
> > > now possible to specify from devicetree where the ECC data is located
> > > inside the OOB region.
> >
> > Why would we want to do that? I mean, ECC/free regions are ECC
> > controller dependent (and NAND chip dependent for the OOB size part),
> > so there's no reason to describe it in the DT. And more importantly,
> > people are likely to get it wrong.
> >
> > I'm curious, why do you need that?
>
> Good question.
>
> The reason is that some SoCs have no ECC controller.
> The various boards for these SoCs then all use a different layout.
Okay. Still think defining the layouts in the DT is a bad idea. We
can add a jz4740 specific property to define the layout id
(ingenic,nand-oob-layout = <layout-id>), but not a generic way to
define custom layouts for all kind of NAND controller.
>
> My motivation is to get rid of this (move it to devicetree):
> https://elixir.bootlin.com/linux/latest/source/arch/mips/jz4740/board-qi_lb60.c#L93
> And enable the support of other boards with custom OOB layouts.
Can you list the different layouts you have? I'm pretty sure there's a
pattern. Maybe we can even deduce the layout from the page size or OOB
size.
next parent reply other threads:[~2018-05-12 13:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20180512115551.56C6E20787@mail.bootlin.com>
2018-05-12 13:42 ` Boris Brezillon [this message]
2018-05-12 14:38 ` [PATCH] mtd: nand: Add support for reading ooblayout from device tree Paul Cercueil
2018-05-12 15:00 ` Boris Brezillon
2018-05-12 17:42 ` Paul Cercueil
2018-05-12 18:02 ` Boris Brezillon
2018-05-12 18:30 ` Paul Cercueil
2018-05-12 11:55 Paul Cercueil
-- strict thread matches above, loose matches on Subject: below --
2018-05-11 21:29 Paul Cercueil
2018-05-12 5:55 ` Boris Brezillon
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=20180512154223.3b81c7f7@bbrezillon \
--to=boris.brezillon@bootlin.com \
--cc=boris.brezillon@bolin.com \
--cc=computersforpeace@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=dwmw2@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=marek.vasut@gmail.com \
--cc=mark.rutland@arm.com \
--cc=paul@crapouillou.net \
--cc=richard@nod.at \
--cc=robh+dt@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 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).