04568bd0 | 17-Jan-2019 |
Adam Ford <aford173@gmail.com> |
MTD: nand: mxs_nand: Allow driver to auto setup ECC in SPL
The initialization of the NAND in SPL hard-coded ecc.bytes, ecc.size, and ecc.strength which may work for some NAND parts, but it not appro
MTD: nand: mxs_nand: Allow driver to auto setup ECC in SPL
The initialization of the NAND in SPL hard-coded ecc.bytes, ecc.size, and ecc.strength which may work for some NAND parts, but it not appropriate for others. With the pending patch "mxs_nand: Fix BCH read timeout error on boards requiring ECC" the driver can auto configure the ECC when these entries are blank. This patch has been tested in NAND flash with oob 64 and oob 128.
Signed-off-by: Adam Ford <aford173@gmail.com> Tested-by: Jörg Krause <joerg.krause@embedded.rocks> Acked-by: Tim Harvey <tharvey@gateworks.com> Tested-by: Tim Harvey <tharvey@gateworks.com>
show more ...
|
5645df9e | 12-Jan-2019 |
Adam Ford <aford173@gmail.com> |
MTD: NAND: mxs_nand_init_dma: Make mxs_nand_init_dma static
mxs_nand_init_dma is only referenced from mxs_nand.c. It's not referenced in any headers or outside code, so this patch defines it as sta
MTD: NAND: mxs_nand_init_dma: Make mxs_nand_init_dma static
mxs_nand_init_dma is only referenced from mxs_nand.c. It's not referenced in any headers or outside code, so this patch defines it as static.
Signed-off-by: Adam Ford <aford173@gmail.com>
show more ...
|
acdf10e1 | 03-Dec-2018 |
Lukasz Majewski <lukma@denx.de> |
nand: vybrid: Extend the vf610 NFC NAND driver to support device tree (and DM)
This commit adds support for device tree and enumeration via device model for the Vybrid's NFC NAND driver.
Signed-off
nand: vybrid: Extend the vf610 NFC NAND driver to support device tree (and DM)
This commit adds support for device tree and enumeration via device model for the Vybrid's NFC NAND driver.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
show more ...
|
8a12d127 | 03-Dec-2018 |
Lukasz Majewski <lukma@denx.de> |
Kconfig: Add entry for VF610 NAND NFC device tree aware driver
This commit provides code to add proper entry to Kconfig to enable support for VF610 device tree aware driver.
Signed-off-by: Lukasz M
Kconfig: Add entry for VF610 NAND NFC device tree aware driver
This commit provides code to add proper entry to Kconfig to enable support for VF610 device tree aware driver.
Signed-off-by: Lukasz Majewski <lukma@denx.de>
show more ...
|
9d43649a | 19-Dec-2018 |
Masahiro Yamada <yamada.masahiro@socionext.com> |
mtd: rawnand: denali: fix a race condition when DMA is kicked
Based on Linux commit cf51e4b9c34407bf0c3d9b582b7837e047e1df47
Add the register read-back, commenting why this is necessary.
Signed-of
mtd: rawnand: denali: fix a race condition when DMA is kicked
Based on Linux commit cf51e4b9c34407bf0c3d9b582b7837e047e1df47
Add the register read-back, commenting why this is necessary.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
show more ...
|
8ccfbfb3 | 19-Dec-2018 |
Masahiro Yamada <yamada.masahiro@socionext.com> |
mtd: rawnand: denali: optimize timing parameters for data interface
Based on Linux commit 1dfac31a5a63ac04a9b5fbc3f5105a586560f191
This commit improves the ->setup_data_interface() hook.
The denal
mtd: rawnand: denali: optimize timing parameters for data interface
Based on Linux commit 1dfac31a5a63ac04a9b5fbc3f5105a586560f191
This commit improves the ->setup_data_interface() hook.
The denali_setup_data_interface() needs the frequency of clk_x and the ratio of clk_x / clk.
The latter is currently hardcoded in the driver, like this:
#define DENALI_CLK_X_MULT 6
The IP datasheet requires that clk_x / clk be 4, 5, or 6. I just chose 6 because it is the most defensive value, but it is not optimal. By getting the clock rate of both "clk" and "clk_x", the driver can compute the timing values more precisely.
To not break the existing platforms, the fallback value, 50 MHz is provided. It is true for all upstreamed platforms.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
show more ...
|
c907464a | 11-Oct-2018 |
Miquel Raynal <miquel.raynal@bootlin.com> |
mtd: rawnand: pxa3xx: fix 2kiB pages with 8b strength chips layout
The initial layout for such NAND chips was the following:
+-----------------------------------------------------------------------
mtd: rawnand: pxa3xx: fix 2kiB pages with 8b strength chips layout
The initial layout for such NAND chips was the following:
+----------------------------------------------------------------------------+ | 1024 (data) | 30 (ECC) | 1024 (data) | 30 (ECC) | 32 (free OOB) | 30 (ECC) | +----------------------------------------------------------------------------+
This layout has a weakness: reading empty pages trigger ECC errors (this is expected), but the hardware ECC engine tries to correct the data anyway and creates itself bitflips, hence bitflips are detected in erased pages while actually there are none in the NAND chip.
Two solutions have been found at the same time. One was to enlarge the free OOB area to 64 bytes, changing the layout to be:
+----------------------------------------------------------------------------+ | 1024 (data) | 30 (ECC) | 1024 (data) | 30 (ECC) | 64 (free OOB) | 30 (ECC) | +----------------------------------------------------------------------------+ ^^
The very big drawbacks of this solution are: 1/ It prevents booting from NAND. 2/ The current Linux driver (marvell_nand) does not have such problem because it already re-reads possible empty pages in raw mode before checking for bitflips. Using different layouts in U-Boot and Linux would simply not work.
As this driver does support raw reads now and uses it to check for empty pages, let's forget about this broken hack and return to the initial layout with only 32 free OOB bytes.
Fixes: ac56a3b30c ("mtd: nand: pxa3xx: add support for 2KB 8-bit flash") Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Acked-by: Jagan Teki <jagan@openedev.com>
show more ...
|
af61ea27 | 11-Oct-2018 |
Miquel Raynal <miquel.raynal@bootlin.com> |
mtd: nand: pxa3xx: re-read a page in raw mode on uncorrectable error
This only applies on BCH path.
When an empty page is read, it triggers an uncorrectable error. While this is expected, the ECC e
mtd: nand: pxa3xx: re-read a page in raw mode on uncorrectable error
This only applies on BCH path.
When an empty page is read, it triggers an uncorrectable error. While this is expected, the ECC engine might produce itself bitflips in the read data under certain layouts. To overcome this situation, always re-read the entire page in raw mode and check for the whole page to be empty.
Also report the right number of bitflips if there are any.
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Acked-by: Jagan Teki <jagan@openedev.com>
show more ...
|
44cdfc0e | 18-Oct-2018 |
Vladimir Zapolskiy <vz@mleia.com> |
mtd: nand: lpc32xx slc: disable DMA support in SPL builds
Testing and analysis shows that at the moment LPC32xx NAND SLC driver can not get PL080 DMA backbone support in SPL build, because SPL NAND
mtd: nand: lpc32xx slc: disable DMA support in SPL builds
Testing and analysis shows that at the moment LPC32xx NAND SLC driver can not get PL080 DMA backbone support in SPL build, because SPL NAND loaders operate with subpage (ECC step to be precisely) reads, and this is not supported in the NAND SLC + DMA + hardware ECC calculation bundle.
The change removes a cautious build time warning and explicitly disables DMA flavour of the driver for SPL builds, to reduce the amound of #ifdef sections the code blocks are minimally reorganized.
Signed-off-by: Vladimir Zapolskiy <vz@mleia.com>
show more ...
|