From: David Brownell <david-b@pacbell.net>
To: Troy Kisky <troy.kisky@boundarydevices.com>
Cc: Nicolas Ferre <nicolas.ferre@rfo.atmel.com>,
linux-mtd@lists.infradead.org,
Haavard Skinnemoen <hskinnemoen@atmel.com>
Subject: Re: [PATCH 3/5] mtd: nand: atmel: use default ecc layout
Date: Wed, 13 May 2009 22:12:11 -0700 [thread overview]
Message-ID: <200905132212.11923.david-b@pacbell.net> (raw)
In-Reply-To: <1242270008-1552-3-git-send-email-troy.kisky@boundarydevices.com>
On Wednesday 13 May 2009, Troy Kisky wrote:
> atmel should not need to override default
Doesn't this break compatibility with every system now
in the field? As in, "install a new kernel, trash all
the data now in your NAND flash"??
> Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
> ---
> drivers/mtd/nand/atmel_nand.c | 34 ----------------------------------
> 1 files changed, 0 insertions(+), 34 deletions(-)
>
> diff --git a/drivers/mtd/nand/atmel_nand.c b/drivers/mtd/nand/atmel_nand.c
> index 7b52637..8537e86 100644
> --- a/drivers/mtd/nand/atmel_nand.c
> +++ b/drivers/mtd/nand/atmel_nand.c
> @@ -55,32 +55,6 @@
>
> #include "atmel_nand_ecc.h" /* Hardware ECC registers */
>
> -/* oob layout for large page size
> - * bad block info is on bytes 0 and 1
> - * the bytes have to be consecutives to avoid
> - * several NAND_CMD_RNDOUT during read
> - */
> -static const struct nand_ecclayout atmel_oobinfo_large __initdata = {
> - .eccbytes = 4,
> - .eccpos = {60, 61, 62, 63},
> - .oobfree = {
> - {2, 58}
> - },
> -};
> -
> -/* oob layout for small page size
> - * bad block info is on bytes 4 and 5
> - * the bytes have to be consecutives to avoid
> - * several NAND_CMD_RNDOUT during read
> - */
> -static const struct nand_ecclayout atmel_oobinfo_small __initdata = {
> - .eccbytes = 4,
> - .eccpos = {0, 1, 2, 3},
> - .oobfree = {
> - {6, 10}
> - },
> -};
> -
> struct atmel_nand_host {
> struct nand_chip nand_chip;
> struct mtd_info mtd;
> @@ -477,23 +451,15 @@ static int __init atmel_nand_probe(struct platform_device *pdev)
> /* set ECC page size and oob layout */
> switch (mtd->writesize) {
> case 512:
> - memcpy(&nand_chip->ecc.layout, &atmel_oobinfo_small,
> - sizeof(nand_chip->ecc.layout));
> ecc_writel(host->ecc, MR, ATMEL_ECC_PAGESIZE_528);
> break;
> case 1024:
> - memcpy(&nand_chip->ecc.layout, &atmel_oobinfo_large,
> - sizeof(nand_chip->ecc.layout));
> ecc_writel(host->ecc, MR, ATMEL_ECC_PAGESIZE_1056);
> break;
> case 2048:
> - memcpy(&nand_chip->ecc.layout, &atmel_oobinfo_large,
> - sizeof(nand_chip->ecc.layout));
> ecc_writel(host->ecc, MR, ATMEL_ECC_PAGESIZE_2112);
> break;
> case 4096:
> - memcpy(&nand_chip->ecc.layout, &atmel_oobinfo_large,
> - sizeof(nand_chip->ecc.layout));
> ecc_writel(host->ecc, MR, ATMEL_ECC_PAGESIZE_4224);
> break;
> default:
> --
> 1.5.4.3
>
>
next prev parent reply other threads:[~2009-05-14 5:12 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1242270008-1552-1-git-send-email-troy.kisky@boundarydevices.com>
2009-05-14 4:42 ` [PATCH 1/5] mtd: nand: move layout structure into nand_ecc_ctrl David Brownell
2009-05-14 17:53 ` Troy Kisky
2009-05-14 18:08 ` David Brownell
[not found] ` <1242270008-1552-2-git-send-email-troy.kisky@boundarydevices.com>
2009-05-14 5:10 ` [PATCH 2/5] mtd: nand: Calculate better default ecc layout David Brownell
2009-05-14 17:59 ` Troy Kisky
[not found] ` <1242270008-1552-3-git-send-email-troy.kisky@boundarydevices.com>
2009-05-14 5:12 ` David Brownell [this message]
2009-05-14 8:23 ` [PATCH 3/5] mtd: nand: atmel: use " Haavard Skinnemoen
2009-05-14 18:08 ` Troy Kisky
2009-05-15 7:26 ` Richard Genoud
2009-05-15 19:57 ` Richard Genoud
2009-05-15 22:15 ` Troy Kisky
2009-05-15 22:38 ` Richard Genoud
2009-05-15 23:04 ` Troy Kisky
2009-05-14 18:04 ` Troy Kisky
2009-05-20 15:19 ` Nicolas Ferre
2009-05-20 18:28 ` Troy Kisky
[not found] ` <1242270008-1552-4-git-send-email-troy.kisky@boundarydevices.com>
2009-05-14 5:18 ` [PATCH 4/5] mtd: nand: cafe_nand: " David Brownell
2009-05-14 21:18 ` Troy Kisky
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=200905132212.11923.david-b@pacbell.net \
--to=david-b@pacbell.net \
--cc=hskinnemoen@atmel.com \
--cc=linux-mtd@lists.infradead.org \
--cc=nicolas.ferre@rfo.atmel.com \
--cc=troy.kisky@boundarydevices.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 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.