mtd: nand: omap: optimize and clean-up of OMAP NAND driver
Get series with b4
b4 am [email protected]Versions newest first
- v8 Latest0 of 5 patches 0 repliesNew
Patches in v8 No applies recorded yet
None of the 5 patches the cover letter announces are in this archive.
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v8 yet.
Cover letter [U-Boot] [PATCH v8 0/5] mtd: nand: omap: optimize and clean-up of OMAP NAND driver
Hi Pekon,
should I consider the U-Boot and Linux am335x NAND implementation to be compatible? So are the ECC schemes in a way identical that I can nandwrite a kernel image from Linux and "nand read" it from U-Boot? I tested with the 3.8.13 beaglebone kernel (which is of course not very representative) and it does not work. If it should work, do you know it that was already the case before your patches and with which Linux kernel?
Regards,
Matthias
Quoted 111 lines · Pekon Gupta
*changes in v8*
[PATCH 1/5] incorporated following feedbacks from Scott Wood <[email protected]>
- using symbolic names (enums) as values ofCONFIG_NAND_OMAP_ECCSCHEME
- updatedomap_select_ecc_scheme(): perform ecc-scheme compatibility checks before updating nand_chip.ecc fields. This avoids corrupting of existing ecc-scheme in case of switching failures.
- code clean-up (removed fall-back onomap_select_ecc_scheme()failures)
[PATCH 2/5], [PATCH 3/5], [PATCH 4/5] minor code clean-up
[PATCH 5/5] <no update>*changes in v7*
[PATCH 1/5]
-omap_gpmc.c: fix: free bytes in OOB (ecclayout->oobfree[0].length)
-omap_gpmc.c: cleanup: redundant code added in previous patch versions
-am335x_evm.h: cleanup: redundant code added in previous patch versions
-tricorder.h: fix:CONFIG_NAND_OMAP_ECCSCHEME
[PATCH 2/5] removed: re-configuration of gpmc.config1[dev_width] added in
previous version of patch
[PATCH 3/5] <no update>
[PATCH 4/5] <no update>
[PATCH 5/5] minor fix: missing '$' in ${loadaddr}*changes in v6*
[PATCH 1/5] incorporated feedbacks from Scott Wood <[email protected]>
- renamedCONFIG_SYS_NAND_ECCSCHEMEtoCONFIG_NAND_OMAP_ECCSCHEME
- updatedomap_select_ecc_scheme()to handle error conditions without depending on caller.
- renamedOMAP_ECC_HAM1_CODE_HW_ROMCODEtoOMAP_ECC_HAM1_CODE_HWto keep it naming compatible to linux kernel
- updated doc/README.nand and doc/README.omap3
[PATCH 2/5] minor code clean-up
[PATCH 3/5] minor code clean-up
[PATCH 4/5] <no update>
[PATCH 5/5] <movedCONFIG_NAND_OMAP_ECCSCHEMEdescription to README.nand>*changes in v5*
This version of patch is tested on am335x-evm with x8 NAND device, and boots SPL and u-boot from NAND
[PATCH 1/5]
- re-addedomap_read_page_bch(): needed proper sequence of while reading DATA and ECC from NAND page, so thatcalc_eccgenerated from GPMC is understood by ELM.
- added check to see if NAND OOB can accomodate ECC for entire page
[PATCH 2/5] fixed device-width inGPMC_CONFIG1_Xto support x16 devices [PATCH 3/5] code clean-up forOMAP_ECC_BCH8_CODE_HW_DETECTION_SWmode [PATCH 4/5]
- fixedomap_correct_data_bch()for correcting bit-flips using ELM
- code-cleanup + addedomap_reverse_list()
[PATCH 5/5] incorporated feedbacks from Peter Korsgaard <[email protected]>*changes in v4*
[PATCH 1/5]
- removedomap_read_page_bch():chip->ecc.read_pageuses default APInand_read_page_hwecc()innand_base.c
- updatedtricorder.h: added new CONFIGS for ECCSCHEME &ONFI_DETECTION
- convertedprintf("ECC-SCHEME")todebug("ECC-SCHEME")
[PATCH 2/5] minor code clean-up
[PATCH 3/5] <no update>
[PATCH 4/5] <no update>
[PATCH 5/5] updated README as per feedbacks from trini at ti.com*changes in v3*
[PATCH 1/5] (complete change)
- ecc-scheme is selection is controller by s/w, notCONFIG_NAND_xx
- addedomap_select_ecc_scheme(), as common function to handle all ecc-scheme related configurations for bothboard_nand_init()&omap_nand_switch_ecc().
- removed un-used defines fromasm/arch-am33xx/omap_gpmc.h
- updated doc/REAME.nand
[PATCH 2/5] removed un-used defines fromasm/omap_gpmc.h[PATCH 3/5] removedomap_calculate_ecc_bch_sw()andomap_calculate_ecc()
and merged their logic intoomap_calculate_ecc_bch()
[PATCH 4/5] updated return error-code in-case of invalid conditions [PATCH 5/5] (new) for board/ti/am335x/README*changes in v2*
- added documentation forCONFIG_NAND_OMAP_xxin doc/README.nand
- addedCONFIG_BCHalong withCONFIG_NAND_OMAP_ECC_BCH8_CODE_HW_DETECTION_SWto include software librarylib/bch.c
- fixedboard_nand_init()andomap_enable_hwecc()*original v1*
This patch series updatesBCH8_ECCschemes inmtd/nand/omap_gpmc.cdriver
- adds scalability for higher ECC schemes in future.
- removesCONFIG_AM335xand it makes it generic for all platforms.
- optimizesread_datapathsPekon Gupta (5):
[PATCH 1/5] mtd: nand: omap: enable BCH ECC scheme using ELM for generic platform [PATCH 2/5] mtd: nand: omap: optimizechip->ecc.hwctl()for H/W ECC schemes [PATCH 3/5] mtd: nand: omap: optimizechip->ecc.calculate()for H/W ECC schemes [PATCH 4/5] mtd: nand: omap: optimizedchip->ecc.correct()for H/W ECC schemes [PATCH 5/5] board/ti/am335x/README: update for NAND bootarch/arm/include/asm/arch-am33xx/omap_gpmc.h | 52 +- arch/arm/include/asm/omap_gpmc.h | 7 - board/ti/am335x/README | 53 +- doc/README.nand | 38 ++ doc/README.omap3 | 4 +- drivers/mtd/nand/omap_gpmc.c | 843 +++++++++++---------------- include/configs/am335x_evm.h | 11 +- include/configs/tricorder.h | 3 +- 8 files changed, 446 insertions(+), 565 deletions(-)