All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marek Vasut <marek.vasut@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] MXS-NAND: Backport ecc.size from linux kernel
Date: Mon, 19 Dec 2011 21:23:26 +0100	[thread overview]
Message-ID: <201112192123.26747.marek.vasut@gmail.com> (raw)
In-Reply-To: <4EEF9C45.4090306@freescale.com>

> On 12/18/2011 11:50 AM, Marek Vasut wrote:
> > The ecc.size for mxs NAND driver is set to 1 in Linux kernel and to 512
> > in U-Boot, which causes "ubi part" command malfunction due to wrong
> > subpage size.
> > 
> > Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
> > Cc: Wolfgang Denk <wd@denx.de>
> > Cc: Detlev Zundel <dzu@denx.de>
> > Cc: Stefan Roese <sr@denx.de>
> > Cc: Scott Wood <scottwood@freescale.com>
> > Cc: Veli-Pekka Peltola <veli-pekka.peltola@bluegiga.com>
> > ---
> > 
> >  drivers/mtd/nand/mxs_nand.c |    2 +-
> >  1 files changed, 1 insertions(+), 1 deletions(-)
> > 
> > diff --git a/drivers/mtd/nand/mxs_nand.c b/drivers/mtd/nand/mxs_nand.c
> > index ce2a326..26778ac 100644
> > --- a/drivers/mtd/nand/mxs_nand.c
> > +++ b/drivers/mtd/nand/mxs_nand.c
> > @@ -1105,7 +1105,7 @@ int board_nand_init(struct nand_chip *nand)
> > 
> >  	nand->ecc.layout	= &fake_ecc_layout;
> >  	nand->ecc.mode		= NAND_ECC_HW;
> >  	nand->ecc.bytes		= 9;
> > 
> > -	nand->ecc.size		= 512;
> > +	nand->ecc.size		= 1;
> > 
> >  	return 0;
> 
> ecc.size = 1 doesn't make sense -- this is the block size over which ecc
> is calculated.

And in a way it forces the subpage shift to be 0 ... we need to fix it in both 
later, but for this release, let's make it this way (in sync with linux).
> 
> Where is this Linux driver?  I don't see mxs_nand.c in Linux.

drivers/mtd/nand/gpmi-nand/*
> 
> What specifically is happening in "ubi part" with ecc.size = 512?

The driver doesn\t support subpage writes.
> 
> -Scott

M

  reply	other threads:[~2011-12-19 20:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-18 17:50 [U-Boot] [PATCH] MXS-NAND: Backport ecc.size from linux kernel Marek Vasut
2011-12-19 14:33 ` Veli-Pekka Peltola
2011-12-19 15:05   ` Marek Vasut
2011-12-19 15:30     ` Veli-Pekka Peltola
2011-12-19 20:19 ` Scott Wood
2011-12-19 20:23   ` Marek Vasut [this message]
2011-12-19 20:34     ` Scott Wood
2011-12-19 20:56       ` Marek Vasut
2012-01-03 21:20       ` Marek Vasut
2012-01-03 21:30         ` Scott Wood
2012-01-04  0:39           ` Marek Vasut

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=201112192123.26747.marek.vasut@gmail.com \
    --to=marek.vasut@gmail.com \
    --cc=u-boot@lists.denx.de \
    /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.