projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7cd37e7
)
mtd: nand: ecc-hamming: Populate the public nsteps field
author
Miquel Raynal
<miquel.raynal@bootlin.com>
Wed, 27 Jan 2021 20:30:14 +0000
(21:30 +0100)
committer
Miquel Raynal
<miquel.raynal@bootlin.com>
Thu, 11 Mar 2021 08:37:28 +0000
(09:37 +0100)
Advertize the actual number of steps that will actually be used by the
driver by populating the public field.
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Tested-by: Adam Ford <aford173@gmail.com> #logicpd Torpedo
Link:
https://lore.kernel.org/linux-mtd/20210127203020.9574-4-miquel.raynal@bootlin.com
drivers/mtd/nand/ecc-sw-hamming.c
patch
|
blob
|
history
diff --git
a/drivers/mtd/nand/ecc-sw-hamming.c
b/drivers/mtd/nand/ecc-sw-hamming.c
index 6334d1d7735d564223edccff287de32d94214360..5144775e5a591e978b966f772de6b8892e4e124d 100644
(file)
--- a/
drivers/mtd/nand/ecc-sw-hamming.c
+++ b/
drivers/mtd/nand/ecc-sw-hamming.c
@@
-513,6
+513,7
@@
int nand_ecc_sw_hamming_init_ctx(struct nand_device *nand)
}
nand->ecc.ctx.priv = engine_conf;
+ nand->ecc.ctx.nsteps = mtd->writesize / conf->step_size;
nand->ecc.ctx.total = engine_conf->nsteps * engine_conf->code_size;
return 0;