RE: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-04 Thread Gupta, Pekon
> 
> On 7/3/2013 11:34 PM, Gupta, Pekon wrote:
> >> On Wednesday 03 July 2013, Artem Bityutskiy wrote:
> >>> On Wed, 2013-07-03 at 13:16 +, Gupta, Pekon wrote:
>  [Pekon]: Yes, I'm not seeing these build issues, as I'm cleanly
>  returning from probe with pr_err(), if the required libraries 
>  (/lib/bch.c)
>  are not build-in the system.
>  ---
>  [Patch v4 1/4]: mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW
> ECC..
>  @@static int omap_nand_probe(struct platform_device *pdev)
>  +default:
>  +pr_err("selected ECC scheme not supported or not
> >> enabled\n");
>  +err = -EINVAL;
>  +goto out_release_mem_region;
>  +}
>  ---
>  However, if you are still seeing this, could you please send me your
> >> config?
> >>> I compile tested your patches too, and did not see any issues with my
> >>> omap2_defconfig.
> >>
> >> To clarify: I'm getting this error with randconfig on today's linux-next.
> >> I think it only happens with MTD_NAND_ECC_BCH enabled, which is not
> >> the default in omap2_defconfig.
> >>
> >>Arnd
> > Hi Arnd, Artem, Stephen,
> >
> > I see the issue in linux-next/master tree..
> > linux-next/master has only the first [Patch v4 1/4] from the series.
> > Other patches [Patch v4 2/4.. 4/4] of this series were dropped,
> > as 'Olof Johansson' had some apprehensions about DT bindings.
> > http://permalink.gmane.org/gmane.linux.ports.arm.kernel/249662
> >
> > As these patches are inter-dependent, so please drop the whole series
> > including the commit below.
> > fb1585b  [Patch v4 1/4] mtd: nand: omap2: clean-up BCHx_HW and
> BCHx_SW
> >
> > I'm awaiting feedbacks from 'Olof Johansson' or other DT maintainers,
> > once approved, I'll resend the whole series.
> >
> > "[PATCH v4 2/4] ARM: OMAP2+: cleaned-up DT support " had the
> > declarations which were required for above build errors.
> > ---
> > include/linux/platform_data/mtd-nand-omap2.h
> > enum omap_ecc {
> > +   /* 4-bit  ECC calculation by GPMC, Error detection by Software */
> > +   OMAP_ECC_BCH4_CODE_HW_DETECTION_SW,
> > ...
> > +   /* 8-bit  ECC calculation by GPMC, Error detection by Software */
> > +   OMAP_ECC_BCH8_CODE_HW_DETECTION_SW
> > ---
> >
> But patches should not have inter dependency for compilation. It will affect
> the bisect process.
> 
[Pekon]: They don't, If you read through the email, this issue was hit
with randconfig, and not with omap2plus_defconfig. So you would not see
build issue if you are bisecting using correct config (omap2plus_defconfig).
Also if I merge all the relevant changes in single patch, then if would
become difficult for review, and it would be conflict your earlier feedback
of breaking the patch sets.

However, I leave it to Arnd and Artem if they want me to re-shuffle 
changes and re-submit.


with regards, pekon


Re: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-04 Thread Mugunthan V N

On 7/3/2013 11:34 PM, Gupta, Pekon wrote:

On Wednesday 03 July 2013, Artem Bityutskiy wrote:

On Wed, 2013-07-03 at 13:16 +, Gupta, Pekon wrote:

[Pekon]: Yes, I'm not seeing these build issues, as I'm cleanly
returning from probe with pr_err(), if the required libraries (/lib/bch.c)
are not build-in the system.
---
[Patch v4 1/4]: mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC..
@@static int omap_nand_probe(struct platform_device *pdev)
+   default:
+   pr_err("selected ECC scheme not supported or not

enabled\n");

+   err = -EINVAL;
+   goto out_release_mem_region;
+   }
---
However, if you are still seeing this, could you please send me your

config?

I compile tested your patches too, and did not see any issues with my
omap2_defconfig.


To clarify: I'm getting this error with randconfig on today's linux-next.
I think it only happens with MTD_NAND_ECC_BCH enabled, which is not
the default in omap2_defconfig.

Arnd

Hi Arnd, Artem, Stephen,

I see the issue in linux-next/master tree..
linux-next/master has only the first [Patch v4 1/4] from the series.
Other patches [Patch v4 2/4.. 4/4] of this series were dropped,
as 'Olof Johansson' had some apprehensions about DT bindings.
http://permalink.gmane.org/gmane.linux.ports.arm.kernel/249662

As these patches are inter-dependent, so please drop the whole series
including the commit below.
fb1585b  [Patch v4 1/4] mtd: nand: omap2: clean-up BCHx_HW and BCHx_SW

I'm awaiting feedbacks from 'Olof Johansson' or other DT maintainers,
once approved, I'll resend the whole series.

"[PATCH v4 2/4] ARM: OMAP2+: cleaned-up DT support " had the
declarations which were required for above build errors.
---
include/linux/platform_data/mtd-nand-omap2.h
enum omap_ecc {
+   /* 4-bit  ECC calculation by GPMC, Error detection by Software */
+   OMAP_ECC_BCH4_CODE_HW_DETECTION_SW,
...
+   /* 8-bit  ECC calculation by GPMC, Error detection by Software */
+   OMAP_ECC_BCH8_CODE_HW_DETECTION_SW
---


But patches should not have inter dependency for compilation. It will affect
the bisect process.

Regards
Mugunthan V N

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-03 Thread Gupta, Pekon
> 
> On Wednesday 03 July 2013, Artem Bityutskiy wrote:
> > On Wed, 2013-07-03 at 13:16 +, Gupta, Pekon wrote:
> > > [Pekon]: Yes, I'm not seeing these build issues, as I'm cleanly
> > > returning from probe with pr_err(), if the required libraries (/lib/bch.c)
> > > are not build-in the system.
> > > ---
> > > [Patch v4 1/4]: mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC..
> > > @@static int omap_nand_probe(struct platform_device *pdev)
> > > + default:
> > > + pr_err("selected ECC scheme not supported or not
> enabled\n");
> > > + err = -EINVAL;
> > > + goto out_release_mem_region;
> > > + }
> > > ---
> > > However, if you are still seeing this, could you please send me your
> config?
> >
> > I compile tested your patches too, and did not see any issues with my
> > omap2_defconfig.
> 
> 
> To clarify: I'm getting this error with randconfig on today's linux-next.
> I think it only happens with MTD_NAND_ECC_BCH enabled, which is not
> the default in omap2_defconfig.
> 
>   Arnd

Hi Arnd, Artem, Stephen,

I see the issue in linux-next/master tree..
linux-next/master has only the first [Patch v4 1/4] from the series.
Other patches [Patch v4 2/4.. 4/4] of this series were dropped,
as 'Olof Johansson' had some apprehensions about DT bindings.
http://permalink.gmane.org/gmane.linux.ports.arm.kernel/249662

As these patches are inter-dependent, so please drop the whole series
including the commit below.
fb1585b  [Patch v4 1/4] mtd: nand: omap2: clean-up BCHx_HW and BCHx_SW

I'm awaiting feedbacks from 'Olof Johansson' or other DT maintainers,
once approved, I'll resend the whole series.

"[PATCH v4 2/4] ARM: OMAP2+: cleaned-up DT support " had the
declarations which were required for above build errors.
---
include/linux/platform_data/mtd-nand-omap2.h
enum omap_ecc {
+   /* 4-bit  ECC calculation by GPMC, Error detection by Software */
+   OMAP_ECC_BCH4_CODE_HW_DETECTION_SW,
...
+   /* 8-bit  ECC calculation by GPMC, Error detection by Software */
+   OMAP_ECC_BCH8_CODE_HW_DETECTION_SW
---


with regards, pekon



Re: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-03 Thread Arnd Bergmann
On Wednesday 03 July 2013, Artem Bityutskiy wrote:
> On Wed, 2013-07-03 at 13:16 +, Gupta, Pekon wrote:
> > [Pekon]: Yes, I'm not seeing these build issues, as I'm cleanly
> > returning from probe with pr_err(), if the required libraries (/lib/bch.c) 
> > are not build-in the system.
> > ---
> > [Patch v4 1/4]: mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC..
> > @@static int omap_nand_probe(struct platform_device *pdev)
> > +   default:
> > +   pr_err("selected ECC scheme not supported or not enabled\n");
> > +   err = -EINVAL;
> > +   goto out_release_mem_region;
> > +   }
> > ---
> > However, if you are still seeing this, could you please send me your config?
> 
> I compile tested your patches too, and did not see any issues with my
> omap2_defconfig.


To clarify: I'm getting this error with randconfig on today's linux-next.
I think it only happens with MTD_NAND_ECC_BCH enabled, which is not
the default in omap2_defconfig.

Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-03 Thread Artem Bityutskiy
On Wed, 2013-07-03 at 13:16 +, Gupta, Pekon wrote:
> [Pekon]: Yes, I'm not seeing these build issues, as I'm cleanly
> returning from probe with pr_err(), if the required libraries (/lib/bch.c) 
> are not build-in the system.
> ---
> [Patch v4 1/4]: mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC..
> @@static int omap_nand_probe(struct platform_device *pdev)
> + default:
> + pr_err("selected ECC scheme not supported or not enabled\n");
> + err = -EINVAL;
> + goto out_release_mem_region;
> + }
> ---
> However, if you are still seeing this, could you please send me your config?

I compile tested your patches too, and did not see any issues with my
omap2_defconfig.

-- 
Best Regards,
Artem Bityutskiy

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-03 Thread Gupta, Pekon
> 
> On Tuesday 02 July 2013, Pekon Gupta wrote:
> > (+ CC: devicetree-disc...@lists.ozlabs.org)
> >
> > Changes v3 -> v4
> > - [Patch 1/3] removed MTD_NAND_OMAP_BCH8 &
> MTD_NAND_OMAP_BCH4 from nand/Kconfig
> > ECC scheme selectable via nand DT (nand-ecc-opt).
> > - [*] rebased for l2-mtd.git
> 
> Do you also fix these build error?
> 
> /git/arm-soc/drivers/mtd/nand/omap2.c: In function 'omap_nand_probe':
> /git/arm-soc/drivers/mtd/nand/omap2.c:1964:7: error:
> 'OMAP_ECC_BCH8_CODE_HW_DETECTION_SW' undeclared (first use in this
> function)
>   case OMAP_ECC_BCH8_CODE_HW_DETECTION_SW:
>^
> /git/arm-soc/drivers/mtd/nand/omap2.c:1964:7: note: each undeclared
> identifier is reported only once for each function it appears in
> /git/arm-soc/drivers/mtd/nand/omap2.c:1991:7: error:
> 'OMAP_ECC_BCH4_CODE_HW_DETECTION_SW' undeclared (first use in this
> function)
>   case OMAP_ECC_BCH4_CODE_HW_DETECTION_SW:
>^
> 
> 
>   Arnd

[Pekon]: Yes, I'm not seeing these build issues, as I'm cleanly
returning from probe with pr_err(), if the required libraries (/lib/bch.c) 
are not build-in the system.
---
[Patch v4 1/4]: mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC..
@@static int omap_nand_probe(struct platform_device *pdev)
+   default:
+   pr_err("selected ECC scheme not supported or not enabled\n");
+   err = -EINVAL;
+   goto out_release_mem_region;
+   }
---
However, if you are still seeing this, could you please send me your config?


with regards, pekon
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-03 Thread Arnd Bergmann
On Tuesday 02 July 2013, Pekon Gupta wrote:
> (+ CC: devicetree-disc...@lists.ozlabs.org)
> 
> Changes v3 -> v4
> - [Patch 1/3] removed MTD_NAND_OMAP_BCH8 & MTD_NAND_OMAP_BCH4 from 
> nand/Kconfig
>   ECC scheme selectable via nand DT (nand-ecc-opt).
> - [*] rebased for l2-mtd.git

Do you also fix these build error?

/git/arm-soc/drivers/mtd/nand/omap2.c: In function 'omap_nand_probe':
/git/arm-soc/drivers/mtd/nand/omap2.c:1964:7: error: 
'OMAP_ECC_BCH8_CODE_HW_DETECTION_SW' undeclared (first use in this function)
  case OMAP_ECC_BCH8_CODE_HW_DETECTION_SW:
   ^
/git/arm-soc/drivers/mtd/nand/omap2.c:1964:7: note: each undeclared identifier 
is reported only once for each function it appears in
/git/arm-soc/drivers/mtd/nand/omap2.c:1991:7: error: 
'OMAP_ECC_BCH4_CODE_HW_DETECTION_SW' undeclared (first use in this function)
  case OMAP_ECC_BCH4_CODE_HW_DETECTION_SW:
   ^


Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-02 Thread Pekon Gupta
(+ CC: devicetree-disc...@lists.ozlabs.org)

Changes v3 -> v4
- [Patch 1/3] removed MTD_NAND_OMAP_BCH8 & MTD_NAND_OMAP_BCH4 from nand/Kconfig
ECC scheme selectable via nand DT (nand-ecc-opt).
- [*] rebased for l2-mtd.git

(with Author Name fixed)
Changes v2 -> v3
- PATCH-1: re-arranged code to remove redundancy, added NAND_BUSWIDTH_AUTO
- PATCH-2: updated nand-ecc-opt DT mapping and Documentation
- PATCH-3: code-cleaning + changes to match PATCH-1
- PATCH-4  update DT attribute for ti,nand-ecc-opt 
- received feedback to keep DT mapping independent of linuxism
- PATCH-4: : ARM: dts: AM33xx: updated default ECC scheme in nand-ecc-opt
- independent patch for AM335x-evm.dts update based on PATCH-2

Changes v1 -> v2
added   [PATCH 3/4] and [PATCH 4/4]

Patches in this series:
[PATCH 1/4]: clean-up and optimization for supported ECC schemes.
[PATCH 2/4]: add separate DT options each supported ECC scheme.
[PATCH 3/4]: update BCH4 ECC implementation (using ELM or using lib/bch.h)
[PATCH 4/4]: ARM: dts: AM33xx: updated default ECC scheme in nand-ecc-opt

After this patch series, omap2-nand driver will supports following ECC schemes:
+---+---+---+
| ECC scheme|ECC calculation|Error detection|
+---+---+---+
|OMAP_ECC_HAMMING_CODE_DEFAULT  |S/W|S/W|
|OMAP_ECC_HAMMING_CODE_HW   |H/W (GPMC) |S/W|
|OMAP_ECC_HAMMING_CODE_HW_ROMCODE   |H/W (GPMC) |S/W|
+---+---+---+
|OMAP_ECC_BCH4_CODE_HW_DETECTION_SW |H/W (GPMC) |S/W (lib/bch.h)|
|OMAP_ECC_BCH4_CODE_HW  |H/W (GPMC) |H/W (ELM)  |
+---+---+---+
|OMAP_ECC_BCH8_CODE_HW_DETECTION_SW |H/W (GPMC) |S/W (lib/bch.h)|
|OMAP_ECC_BCH8_CODE_HW  |H/W (GPMC) |H/W (ELM)  |
+---+---+---+
- Selection of OMAP_ECC_BCHx_CODE_HW_DETECTION_SW requires,
Kconfig: CONFIG_MTD_NAND_ECC_BCH: enables S/W based BCH ECC algorithm.

- Selection of OMAP_ECC_BCHx_CODE_HW requires,
Kconfig: CONFIG_MTD_NAND_OMAP_BCH: enables ELM H/W module.


Pekon Gupta (4):
  mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC configurations in
device_probe
  ARM: OMAP2+: cleaned-up DT support of various ECC schemes
  mtd:nand:omap2: updated support for BCH4 ECC scheme
  ARM: dts: AM33xx: updated default ECC scheme in nand-ecc-opt

 .../devicetree/bindings/mtd/gpmc-nand.txt  |  65 ++-
 arch/arm/boot/dts/am335x-evm.dts   |   2 +-
 arch/arm/mach-omap2/gpmc.c |  14 +-
 drivers/mtd/nand/Kconfig   |  30 +-
 drivers/mtd/nand/omap2.c   | 481 ++---
 include/linux/platform_data/elm.h  |   4 +
 include/linux/platform_data/mtd-nand-omap2.h   |  22 +-
 7 files changed, 308 insertions(+), 310 deletions(-)

-- 
1.8.1

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-01 Thread Artem Bityutskiy
On Mon, 2013-07-01 at 15:21 +0530, Pekon Gupta wrote:
> +---+---+---+
> | ECC scheme  |ECC calculation|Error detection|
> +---+---+---+
> |OMAP_ECC_HAMMING_CODE_DEFAULT|S/W|S/W
> |
> |OMAP_ECC_HAMMING_CODE_HW |H/W (GPMC) |S/W|
> |OMAP_ECC_HAMMING_CODE_HW_ROMCODE |H/W (GPMC) |S/W|
> +---+---+---+
> |OMAP_ECC_BCH4_CODE_HW_DETECTION_SW   |H/W (GPMC) |S/W (lib/bch.h)|
> |OMAP_ECC_BCH4_CODE_HW|H/W (GPMC) |H/W (ELM)  
> |
> +---+---+---+
> |OMAP_ECC_BCH8_CODE_HW_DETECTION_SW   |H/W (GPMC) |S/W (lib/bch.h)|
> |OMAP_ECC_BCH8_CODE_HW|H/W (GPMC) |H/W (ELM)  
> |
> +---+---+---+

Pushed patches 1-3 to l2-mtd.git, thanks. I had to fix the table because
you use tabs there, and git log makes the table look messy. Please, use
spaces instead next time.

Thanks!

-- 
Best Regards,
Artem Bityutskiy

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH v4 0/4] mtd:nand:omap2: clean-up of supported ECC schemes

2013-07-01 Thread Pekon Gupta
Changes v3 -> v4
- [Patch 1/3] removed MTD_NAND_OMAP_BCH8 & MTD_NAND_OMAP_BCH4 from nand/Kconfig
ECC scheme selectable via nand DT (nand-ecc-opt).
= [*] rebased for l2-mtd.git

(with Author Name fixed)
Changes v2 -> v3
- PATCH-1: re-arranged code to remove redundancy, added NAND_BUSWIDTH_AUTO
- PATCH-2: updated nand-ecc-opt DT mapping and Documentation
- PATCH-3: code-cleaning + changes to match PATCH-1
- PATCH-4  update DT attribute for ti,nand-ecc-opt 
- received feedback to keep DT mapping independent of linuxism
- PATCH-4: : ARM: dts: AM33xx: updated default ECC scheme in nand-ecc-opt
- independent patch for AM335x-evm.dts update based on PATCH-2

Changes v1 -> v2
added   [PATCH 3/4] and [PATCH 4/4]

Patches in this series:
[PATCH 1/4]: clean-up and optimization for supported ECC schemes.
[PATCH 2/4]: add separate DT options each supported ECC scheme.
[PATCH 3/4]: update BCH4 ECC implementation (using ELM or using lib/bch.h)
[PATCH 4/4]: ARM: dts: AM33xx: updated default ECC scheme in nand-ecc-opt

After this patch series, omap2-nand driver will supports following ECC schemes:
+---+---+---+
| ECC scheme|ECC calculation|Error detection|
+---+---+---+
|OMAP_ECC_HAMMING_CODE_DEFAULT  |S/W|S/W|
|OMAP_ECC_HAMMING_CODE_HW   |H/W (GPMC) |S/W|
|OMAP_ECC_HAMMING_CODE_HW_ROMCODE   |H/W (GPMC) |S/W|
+---+---+---+
|OMAP_ECC_BCH4_CODE_HW_DETECTION_SW |H/W (GPMC) |S/W (lib/bch.h)|
|OMAP_ECC_BCH4_CODE_HW  |H/W (GPMC) |H/W (ELM)  |
+---+---+---+
|OMAP_ECC_BCH8_CODE_HW_DETECTION_SW |H/W (GPMC) |S/W (lib/bch.h)|
|OMAP_ECC_BCH8_CODE_HW  |H/W (GPMC) |H/W (ELM)  |
+---+---+---+
- Selection of OMAP_ECC_BCHx_CODE_HW_DETECTION_SW requires,
Kconfig: CONFIG_MTD_NAND_ECC_BCH: enables S/W based BCH ECC algorithm.

- Selection of OMAP_ECC_BCHx_CODE_HW requires,
Kconfig: CONFIG_MTD_NAND_OMAP_BCH: enables ELM H/W module.


Pekon Gupta (4):
  mtd:nand:omap2: clean-up BCHx_HW and BCHx_SW ECC configurations in
device_probe
  ARM: OMAP2+: cleaned-up DT support of various ECC schemes
  mtd:nand:omap2: updated support for BCH4 ECC scheme
  ARM: dts: AM33xx: updated default ECC scheme in nand-ecc-opt

 .../devicetree/bindings/mtd/gpmc-nand.txt  |  65 ++-
 arch/arm/boot/dts/am335x-evm.dts   |   2 +-
 arch/arm/mach-omap2/gpmc.c |  14 +-
 drivers/mtd/nand/Kconfig   |  30 +-
 drivers/mtd/nand/omap2.c   | 481 ++---
 include/linux/platform_data/elm.h  |   4 +
 include/linux/platform_data/mtd-nand-omap2.h   |  22 +-
 7 files changed, 308 insertions(+), 310 deletions(-)

-- 
1.8.1

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html