Re: [PATCH v3 4/4] ARM: OMAP: gpmc: add DT bindings for GPMC timings and NAND

2012-12-06 Thread Ivan Djelic
On Wed, Dec 05, 2012 at 05:15:52AM +, Philip, Avinash wrote: (...) > > First a short reminder of pros and cons of the "constant polynomial > > addition" > > (let's just call it "CPA") feature: > > > > pros: > > - it elegantly solves all problems related to reading an erased page (no > > clum

Re: [PATCH v3 4/4] ARM: OMAP: gpmc: add DT bindings for GPMC timings and NAND

2012-12-01 Thread Ivan Djelic
On Wed, Nov 28, 2012 at 05:01:30AM +, Philip, Avinash wrote: (...) > > Daniel, > > So can you start supporting "bch8-am335xrbl-compatible" and remove usage of > is_elm_used in dt. This should come in ecc_opt field. > > In omap2 NAND driver, AM335x RBL compatibility is achieved depending on

Re: [PATCH v3] mtd: omap: nand: Remove 0xFF's that prefixed 16bit NAND addresses

2012-11-15 Thread Ivan Djelic
On Thu, Nov 15, 2012 at 03:18:44PM +, Artem Bityutskiy wrote: > On Thu, 2012-11-15 at 09:48 -0500, Christopher Harvey wrote: > > On Thu, Nov 15, 2012 at 01:02:09PM +0200, Artem Bityutskiy wrote: > > > On Mon, 2012-10-29 at 15:51 -0400, Christopher Harvey wrote: > > > > In 16bit NAND mode the GP

Re: [PATCH v2] mtd: omap: nand: Remove 0xFF's that prefixed 16bit NAND commands

2012-10-29 Thread Ivan Djelic
On Fri, Oct 26, 2012 at 08:36:43PM +0100, Christopher Harvey wrote: > In 16bit NAND mode the GPMC would send the command 0xNN as 0xFFNN > instead of 0x00NN on the bus. The 0xFFs were actually uninitialized > bits that were left unset in the GPMC command output register. The > reason they weren't in

Re: [PATCH 4/4] mtd: nand: omap2: Add data correction support

2012-10-11 Thread Ivan Djelic
On Thu, Oct 11, 2012 at 06:27:13AM +0100, Philip, Avinash wrote: (...) > > Another simple strategy could use the fact that you add a 14th zero byte to > > the 13 BCH bytes for RBL compatibility: > > RBL compatibility (14th byte) is applicable only for BCH8 ecc scheme. > > So I am planning adding

Re: [PATCH 4/4] mtd: nand: omap2: Add data correction support

2012-10-10 Thread Ivan Djelic
On Tue, Oct 09, 2012 at 01:36:50PM +0100, Philip, Avinash wrote: (...) > > There are at least 2 potential problems when reading an erased page with > > bitflips: > > > > 1. bitflip in data area and no bitflip in spare area (all 0xff) > > Your code will not perform any ECC correction. > > UBIFS do

Re: [PATCH v2 00/14] OMAP-GPMC related cleanup for common zImage

2012-10-10 Thread Ivan Djelic
On Mon, Oct 08, 2012 at 07:08:08AM +0100, Mohammed, Afzal wrote: > Hi Ivan, > > On Mon, Oct 08, 2012 at 11:05:56, Mohammed, Afzal wrote: > > > This series cleans up omap-gpmc related code so that omap can > > be a part of common zImage. > > > This series moves gpmc.h from plat-omap/include/plat

Re: [PATCH 4/4] mtd: nand: omap2: Add data correction support

2012-10-05 Thread Ivan Djelic
On Fri, Oct 05, 2012 at 09:51:50AM +0100, Philip, Avinash wrote: > On Thu, Oct 04, 2012 at 15:51:03, Philip, Avinash wrote: > > On Thu, Oct 04, 2012 at 00:50:45, Ivan Djelic wrote: > > > On Wed, Oct 03, 2012 at 03:29:49PM +0100, Philip, Avinash wrote: > > > > EL

Re: [PATCH 3/4] ARM: OMAP2: gpmc: Add support for BCH ECC scheme

2012-10-04 Thread Ivan Djelic
On Thu, Oct 04, 2012 at 09:03:42AM +0100, Philip, Avinash wrote: (...) > > > +int gpmc_calculate_ecc_bch(int cs, const u_char *dat, u_char *ecc) > > > +{ > > > + int i, eccbchtsel; > > > + u32 nsectors, reg, bch_val1, bch_val2, bch_val3, bch_val4; > > > + > > > + if (gpmc_ecc_used != cs) > > > +

Re: [PATCH 4/4] mtd: nand: omap2: Add data correction support

2012-10-03 Thread Ivan Djelic
On Wed, Oct 03, 2012 at 03:29:49PM +0100, Philip, Avinash wrote: > ELM module can be used for error correction of BCH 4 & 8 bit. Also > support read & write page in one shot by adding custom read_page & > write_page methods. This helps in optimizing code. > > New structure member "is_elm_used" is

Re: [PATCH 3/4] ARM: OMAP2: gpmc: Add support for BCH ECC scheme

2012-10-03 Thread Ivan Djelic
On Wed, Oct 03, 2012 at 03:29:48PM +0100, Philip, Avinash wrote: > Add support for BCH ECC scheme to gpmc driver and also enabling multi > sector read/write. This helps in doing single shot NAND page read and > write. > > ECC engine configurations > BCH 4 bit support > 1. write => ECC engine confi

Re: [PATCH 0/3] GPMC NAND isr using standard API

2012-05-19 Thread Ivan Djelic
On Tue, May 15, 2012 at 03:38:09PM +0100, Afzal Mohammed wrote: > Hi Tony, Artem, > > This series creates a fictitious GPMC interrupt chip and provide the > clients with interrupts that could be handled using standard APIs. > This helps in removing the requirement of driver of peripheral > connect

Re: [PATCH 1/3] ARM: OMAP2+: gpmc: update nand register helper

2012-05-15 Thread Ivan Djelic
gpmc_prefetch_config2; > > + void __iomem*gpmc_prefetch_control; > > + void __iomem*gpmc_prefetch_status; > > + void __iomem*gpmc_ecc_config; > > + void __iomem*gpmc_ecc_control; > > + void __iomem*gpmc_

Re: [PATCH v3] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-05-10 Thread Ivan Djelic
On Thu, May 10, 2012 at 04:52:18PM +0100, Artem Bityutskiy wrote: > On Thu, 2012-05-10 at 17:17 +0200, Ivan Djelic wrote: > > But in order to do so, I need the changes that Afzal has submitted > > (in particular [3]). Those changes (and as a consequence, my new patch) &g

Re: [PATCH v3] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-05-10 Thread Ivan Djelic
On Thu, May 10, 2012 at 02:07:37PM +0100, Artem Bityutskiy wrote: > On Wed, 2012-05-09 at 08:31 -0700, Tony Lindgren wrote: > > > Note that I could prepare a new MTD patch with BCH ecc code included, > > > allowing to drop the GPMC BCH ecc api. > > > > OK, let's do that then. I'll drop this patch

Re: [PATCH v3] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-05-09 Thread Ivan Djelic
On Wed, May 09, 2012 at 01:29:28AM +0100, Tony Lindgren wrote: > * Ivan Djelic [120426 05:23]: > > Hello, > > > > Here is version 3 of this patch after review from Tony Lindgren. > > This version adds a separate initialization function mostly to check CPU > > co

Re: [PATCH v3] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-05-09 Thread Ivan Djelic
On Wed, May 09, 2012 at 01:29:28AM +0100, Tony Lindgren wrote: > * Ivan Djelic [120426 05:23]: > > Hello, > > > > Here is version 3 of this patch after review from Tony Lindgren. > > This version adds a separate initialization function mostly to check CPU > > co

[PATCH v2] mtd: nand: omap: add support for hardware BCH ecc

2012-04-30 Thread Ivan Djelic
selected at runtime by setting platform data parameter 'ecc_opt' to value OMAP_ECC_BCH4_CODE_HW or OMAP_ECC_BCH8_CODE_HW. This code has been tested with mtd test modules, UBI and UBIFS on a BeagleBoard revC3 (OMAP3530 ES3.0 + Micron NAND 256MiB 1,8V 16-bit). Signed-off-by: Ivan Djelic

[PATCH v3] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-04-26 Thread Ivan Djelic
useful to support filesystems such as UBIFS, which expect erased pages to contain only 0xFFs. This api has been tested on an OMAP3630 board. Signed-off-by: Ivan Djelic --- v3 changelog: added init function to check CPU compatibility v2 changelog: added missing control register configuration arch

Re: [PATCH v2] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-04-25 Thread Ivan Djelic
Hi Tony, Thanks for the review, On Wed, Apr 25, 2012 at 06:03:14PM +0100, Tony Lindgren wrote: (...) > > #define GPMC_ECC1_RESULT0x200 > > +#define GPMC_ECC_BCH_RESULT_0 0x240 > > Can you please add a comment here saying something like: > > #define GPMC_ECC_BCH_RESULT_0 0x240 /* Not

Re: [PATCH] mtd: nand: omap: add support for hardware BCH ecc

2012-04-20 Thread Ivan Djelic
On Fri, Apr 20, 2012 at 12:12:27PM +0100, Grazvydas Ignotas wrote: > On Fri, Apr 20, 2012 at 12:48 PM, Ivan Djelic wrote: > > Hello, > > This patch provides hardware NAND BCH ecc support for OMAP3 boards. > > It depends on the following patches: > > > > new GP

[PATCH] mtd: nand: omap: add support for hardware BCH ecc

2012-04-20 Thread Ivan Djelic
eagleBoard revC3 (OMAP3530 ES3.0 + Micron NAND 256MiB 1,8V 16-bit). Signed-off-by: Ivan Djelic --- drivers/mtd/nand/Kconfig | 40 +++ drivers/mtd/nand/omap2.c | 262 ++ 2 files changed, 302 insertions(+) diff --git a/drivers/mtd/nand/Kconfig b/d

[PATCH v2] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-04-19 Thread Ivan Djelic
computed ecc. It allows to correct bitflips in blank pages and is extremely useful to support filesystems such as UBIFS, which expect erased pages to contain only 0xFFs. This api has been tested on an OMAP3630 board. Signed-off-by: Ivan Djelic --- v2 changelog: added missing control register

[PATCH] ARM: OMAP3: gpmc: add BCH ecc api and modes

2012-04-17 Thread Ivan Djelic
0xFFs. This api has been tested on an OMAP3630 board. Signed-off-by: Ivan Djelic --- arch/arm/mach-omap2/gpmc.c | 148 arch/arm/plat-omap/include/plat/gpmc.h | 10 +++ 2 files changed, 158 insertions(+) diff --git a/arch/arm/mach-omap2/gpmc.c b/arch