* [PATCH 0/8] mtd: nand: set ECC algorithm explicitly
@ 2016-04-08 10:23 Rafał Miłecki
2016-04-08 10:23 ` [PATCH 1/8] mtd: nand: ams-delta: " Rafał Miłecki
` (8 more replies)
0 siblings, 9 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon; +Cc: Richard Weinberger, linux-mtd, Rafał Miłecki
As part of nand_ecc_modes_t cleaning process we introduced enum
nand_ecc_algo. Before we start using it (mostly in nand_core.c) we have
to modify all driver to set it properly.
This is the first patchset modifying existing drivers. All patches were
compile-tested. More patches will follow in the future, but I was hoping
to have this first series accepted meanwhile.
This work is based on the nand/next branch.
Rafał Miłecki (8):
mtd: nand: ams-delta: set ECC algorithm explicitly
mtd: nand: gpio: set ECC algorithm explicitly
mtd: nand: mxc: set ECC algorithm explicitly
mtd: nand: nuc900: set ECC algorithm explicitly
mtd: nand: orion: set ECC algorithm explicitly
mtd: nand: pasemi: set ECC algorithm explicitly
mtd: nand: plat: set ECC algorithm explicitly
mtd: nand: socrates: set ECC algorithm explicitly
drivers/mtd/nand/ams-delta.c | 1 +
drivers/mtd/nand/gpio.c | 1 +
drivers/mtd/nand/mxc_nand.c | 1 +
drivers/mtd/nand/nuc900_nand.c | 1 +
drivers/mtd/nand/orion_nand.c | 1 +
drivers/mtd/nand/pasemi_nand.c | 1 +
drivers/mtd/nand/plat_nand.c | 1 +
drivers/mtd/nand/socrates_nand.c | 1 +
8 files changed, 8 insertions(+)
--
1.8.4.5
^ permalink raw reply [flat|nested] 11+ messages in thread
* [PATCH 1/8] mtd: nand: ams-delta: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 2/8] mtd: nand: gpio: " Rafał Miłecki
` (7 subsequent siblings)
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
David Woodhouse, Brian Norris, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/ams-delta.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/ams-delta.c b/drivers/mtd/nand/ams-delta.c
index 68b58c8..78e12cc 100644
--- a/drivers/mtd/nand/ams-delta.c
+++ b/drivers/mtd/nand/ams-delta.c
@@ -224,6 +224,7 @@ static int ams_delta_init(struct platform_device *pdev)
/* 25 us command delay time */
this->chip_delay = 30;
this->ecc.mode = NAND_ECC_SOFT;
+ this->ecc.algo = NAND_ECC_HAMMING;
platform_set_drvdata(pdev, io_base);
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 2/8] mtd: nand: gpio: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
2016-04-08 10:23 ` [PATCH 1/8] mtd: nand: ams-delta: " Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 3/8] mtd: nand: mxc: " Rafał Miłecki
` (6 subsequent siblings)
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
David Woodhouse, Brian Norris, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/gpio.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/gpio.c b/drivers/mtd/nand/gpio.c
index ded658f..6317f68 100644
--- a/drivers/mtd/nand/gpio.c
+++ b/drivers/mtd/nand/gpio.c
@@ -273,6 +273,7 @@ static int gpio_nand_probe(struct platform_device *pdev)
nand_set_flash_node(chip, pdev->dev.of_node);
chip->IO_ADDR_W = chip->IO_ADDR_R;
chip->ecc.mode = NAND_ECC_SOFT;
+ chip->ecc.algo = NAND_ECC_HAMMING;
chip->options = gpiomtd->plat.options;
chip->chip_delay = gpiomtd->plat.chip_delay;
chip->cmd_ctrl = gpio_nand_cmd_ctrl;
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 3/8] mtd: nand: mxc: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
2016-04-08 10:23 ` [PATCH 1/8] mtd: nand: ams-delta: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 2/8] mtd: nand: gpio: " Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` Rafał Miłecki
` (5 subsequent siblings)
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
David Woodhouse, Brian Norris, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/mxc_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/mxc_nand.c b/drivers/mtd/nand/mxc_nand.c
index 854c832..57b1b74 100644
--- a/drivers/mtd/nand/mxc_nand.c
+++ b/drivers/mtd/nand/mxc_nand.c
@@ -1585,6 +1585,7 @@ static int mxcnd_probe(struct platform_device *pdev)
this->ecc.mode = NAND_ECC_HW;
} else {
this->ecc.mode = NAND_ECC_SOFT;
+ this->ecc.algo = NAND_ECC_HAMMING;
}
/* NAND bus width determines access functions used by upper layer */
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 4/8] mtd: nand: nuc900: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 2/8] mtd: nand: gpio: " Rafał Miłecki
` (7 subsequent siblings)
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
Wan ZongShun, David Woodhouse, Brian Norris,
moderated list:ARM/NUVOTON W90X900 ARM ARCHITECTURE, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/nuc900_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/nuc900_nand.c b/drivers/mtd/nand/nuc900_nand.c
index dbc5b57..8f64011 100644
--- a/drivers/mtd/nand/nuc900_nand.c
+++ b/drivers/mtd/nand/nuc900_nand.c
@@ -261,6 +261,7 @@ static int nuc900_nand_probe(struct platform_device *pdev)
chip->chip_delay = 50;
chip->options = 0;
chip->ecc.mode = NAND_ECC_SOFT;
+ chip->ecc.algo = NAND_ECC_HAMMING;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
nuc900_nand->reg = devm_ioremap_resource(&pdev->dev, res);
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 4/8] mtd: nand: nuc900: set ECC algorithm explicitly
@ 2016-04-08 10:23 ` Rafał Miłecki
0 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: linux-arm-kernel
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafa? Mi?ecki <zajec5@gmail.com>
---
drivers/mtd/nand/nuc900_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/nuc900_nand.c b/drivers/mtd/nand/nuc900_nand.c
index dbc5b57..8f64011 100644
--- a/drivers/mtd/nand/nuc900_nand.c
+++ b/drivers/mtd/nand/nuc900_nand.c
@@ -261,6 +261,7 @@ static int nuc900_nand_probe(struct platform_device *pdev)
chip->chip_delay = 50;
chip->options = 0;
chip->ecc.mode = NAND_ECC_SOFT;
+ chip->ecc.algo = NAND_ECC_HAMMING;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
nuc900_nand->reg = devm_ioremap_resource(&pdev->dev, res);
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 5/8] mtd: nand: orion: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
` (3 preceding siblings ...)
2016-04-08 10:23 ` Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 6/8] mtd: nand: pasemi: " Rafał Miłecki
` (3 subsequent siblings)
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
David Woodhouse, Brian Norris, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/orion_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/orion_nand.c b/drivers/mtd/nand/orion_nand.c
index d4614bf..40a7c4a 100644
--- a/drivers/mtd/nand/orion_nand.c
+++ b/drivers/mtd/nand/orion_nand.c
@@ -130,6 +130,7 @@ static int __init orion_nand_probe(struct platform_device *pdev)
nc->cmd_ctrl = orion_nand_cmd_ctrl;
nc->read_buf = orion_nand_read_buf;
nc->ecc.mode = NAND_ECC_SOFT;
+ nc->ecc.algo = NAND_ECC_HAMMING;
if (board->chip_delay)
nc->chip_delay = board->chip_delay;
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 6/8] mtd: nand: pasemi: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
` (4 preceding siblings ...)
2016-04-08 10:23 ` [PATCH 5/8] mtd: nand: orion: " Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 7/8] mtd: nand: plat: " Rafał Miłecki
` (2 subsequent siblings)
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
Olof Johansson, David Woodhouse, Brian Norris,
open list:LINUX FOR POWERPC PA SEMI PWRFICIENT, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/pasemi_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/pasemi_nand.c b/drivers/mtd/nand/pasemi_nand.c
index 3ab53ca..63fcb8c 100644
--- a/drivers/mtd/nand/pasemi_nand.c
+++ b/drivers/mtd/nand/pasemi_nand.c
@@ -151,6 +151,7 @@ static int pasemi_nand_probe(struct platform_device *ofdev)
chip->write_buf = pasemi_write_buf;
chip->chip_delay = 0;
chip->ecc.mode = NAND_ECC_SOFT;
+ chip->ecc.algo = NAND_ECC_HAMMING;
/* Enable the following for a flash based bad block table */
chip->bbt_options = NAND_BBT_USE_FLASH;
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 7/8] mtd: nand: plat: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
` (5 preceding siblings ...)
2016-04-08 10:23 ` [PATCH 6/8] mtd: nand: pasemi: " Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 8/8] mtd: nand: socrates: " Rafał Miłecki
2016-04-13 7:45 ` [PATCH 0/8] mtd: nand: " Boris Brezillon
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
David Woodhouse, Brian Norris, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/plat_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/plat_nand.c b/drivers/mtd/nand/plat_nand.c
index e4e50da..415a53a 100644
--- a/drivers/mtd/nand/plat_nand.c
+++ b/drivers/mtd/nand/plat_nand.c
@@ -74,6 +74,7 @@ static int plat_nand_probe(struct platform_device *pdev)
data->chip.ecc.hwctl = pdata->ctrl.hwcontrol;
data->chip.ecc.mode = NAND_ECC_SOFT;
+ data->chip.ecc.algo = NAND_ECC_HAMMING;
platform_set_drvdata(pdev, data);
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 8/8] mtd: nand: socrates: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
` (6 preceding siblings ...)
2016-04-08 10:23 ` [PATCH 7/8] mtd: nand: plat: " Rafał Miłecki
@ 2016-04-08 10:23 ` Rafał Miłecki
2016-04-13 7:45 ` [PATCH 0/8] mtd: nand: " Boris Brezillon
8 siblings, 0 replies; 11+ messages in thread
From: Rafał Miłecki @ 2016-04-08 10:23 UTC (permalink / raw)
To: Boris Brezillon
Cc: Richard Weinberger, linux-mtd, Rafał Miłecki,
David Woodhouse, Brian Norris, open list
This is part of process deprecating NAND_ECC_SOFT_BCH (and switching to
enum nand_ecc_algo).
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
drivers/mtd/nand/socrates_nand.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/nand/socrates_nand.c b/drivers/mtd/nand/socrates_nand.c
index e3305f9..888fd31 100644
--- a/drivers/mtd/nand/socrates_nand.c
+++ b/drivers/mtd/nand/socrates_nand.c
@@ -180,6 +180,7 @@ static int socrates_nand_probe(struct platform_device *ofdev)
nand_chip->dev_ready = socrates_nand_device_ready;
nand_chip->ecc.mode = NAND_ECC_SOFT; /* enable ECC */
+ nand_chip->ecc.algo = NAND_ECC_HAMMING;
/* TODO: I have no idea what real delay is. */
nand_chip->chip_delay = 20; /* 20us command delay time */
--
1.8.4.5
^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: [PATCH 0/8] mtd: nand: set ECC algorithm explicitly
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
` (7 preceding siblings ...)
2016-04-08 10:23 ` [PATCH 8/8] mtd: nand: socrates: " Rafał Miłecki
@ 2016-04-13 7:45 ` Boris Brezillon
8 siblings, 0 replies; 11+ messages in thread
From: Boris Brezillon @ 2016-04-13 7:45 UTC (permalink / raw)
To: Rafał Miłecki; +Cc: Richard Weinberger, linux-mtd
Hi Rafal,
On Fri, 8 Apr 2016 12:23:43 +0200
Rafał Miłecki <zajec5@gmail.com> wrote:
> As part of nand_ecc_modes_t cleaning process we introduced enum
> nand_ecc_algo. Before we start using it (mostly in nand_core.c) we have
> to modify all driver to set it properly.
>
> This is the first patchset modifying existing drivers. All patches were
> compile-tested. More patches will follow in the future, but I was hoping
> to have this first series accepted meanwhile.
>
> This work is based on the nand/next branch.
Whole series applied.
Thanks,
Boris
>
> Rafał Miłecki (8):
> mtd: nand: ams-delta: set ECC algorithm explicitly
> mtd: nand: gpio: set ECC algorithm explicitly
> mtd: nand: mxc: set ECC algorithm explicitly
> mtd: nand: nuc900: set ECC algorithm explicitly
> mtd: nand: orion: set ECC algorithm explicitly
> mtd: nand: pasemi: set ECC algorithm explicitly
> mtd: nand: plat: set ECC algorithm explicitly
> mtd: nand: socrates: set ECC algorithm explicitly
>
> drivers/mtd/nand/ams-delta.c | 1 +
> drivers/mtd/nand/gpio.c | 1 +
> drivers/mtd/nand/mxc_nand.c | 1 +
> drivers/mtd/nand/nuc900_nand.c | 1 +
> drivers/mtd/nand/orion_nand.c | 1 +
> drivers/mtd/nand/pasemi_nand.c | 1 +
> drivers/mtd/nand/plat_nand.c | 1 +
> drivers/mtd/nand/socrates_nand.c | 1 +
> 8 files changed, 8 insertions(+)
>
--
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2016-04-13 7:45 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-08 10:23 [PATCH 0/8] mtd: nand: set ECC algorithm explicitly Rafał Miłecki
2016-04-08 10:23 ` [PATCH 1/8] mtd: nand: ams-delta: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 2/8] mtd: nand: gpio: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 3/8] mtd: nand: mxc: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 4/8] mtd: nand: nuc900: " Rafał Miłecki
2016-04-08 10:23 ` Rafał Miłecki
2016-04-08 10:23 ` [PATCH 5/8] mtd: nand: orion: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 6/8] mtd: nand: pasemi: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 7/8] mtd: nand: plat: " Rafał Miłecki
2016-04-08 10:23 ` [PATCH 8/8] mtd: nand: socrates: " Rafał Miłecki
2016-04-13 7:45 ` [PATCH 0/8] mtd: nand: " Boris Brezillon
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.