Skip to content

Commit 1e06dbf

Browse files
andreascianmiquelraynal
authored andcommitted
mtd: rawnand: pl353: Add message about ECC mode
This just add some information on kernel log about the selected ECC Signed-off-by: Andrea Scian <andrea.scian@dave.eu> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
1 parent 89b831e commit 1e06dbf

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

drivers/mtd/nand/raw/pl35x-nand-controller.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -970,15 +970,18 @@ static int pl35x_nand_attach_chip(struct nand_chip *chip)
970970

971971
switch (chip->ecc.engine_type) {
972972
case NAND_ECC_ENGINE_TYPE_ON_DIE:
973+
dev_dbg(nfc->dev, "Using on-die ECC\n");
973974
/* Keep these legacy BBT descriptors for ON_DIE situations */
974975
chip->bbt_td = &bbt_main_descr;
975976
chip->bbt_md = &bbt_mirror_descr;
976977
fallthrough;
977978
case NAND_ECC_ENGINE_TYPE_NONE:
978979
case NAND_ECC_ENGINE_TYPE_SOFT:
980+
dev_dbg(nfc->dev, "Using software ECC (Hamming 1-bit/512B)\n");
979981
chip->ecc.write_page_raw = nand_monolithic_write_page_raw;
980982
break;
981983
case NAND_ECC_ENGINE_TYPE_ON_HOST:
984+
dev_dbg(nfc->dev, "Using hardware ECC\n");
982985
ret = pl35x_nand_init_hw_ecc_controller(nfc, chip);
983986
if (ret)
984987
return ret;

0 commit comments

Comments
 (0)