mtd: rawnand: Give the possibility to verify a read operation is supported

This can be used to discriminate between two path in the parameter
page detection: use data_in cycles (like before) if supported, use the
CHANGE READ COLUMN command otherwise.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Link: https://lore.kernel.org/linux-mtd/20200507105241.14299-9-miquel.raynal@bootlin.com
This commit is contained in:
Miquel Raynal
2020-05-07 12:52:36 +02:00
parent 930370253e
commit b451f5beec
8 changed files with 44 additions and 31 deletions

View File

@@ -167,7 +167,8 @@ int nand_onfi_detect(struct nand_chip *chip)
}
for (i = 0; i < ONFI_PARAM_PAGES; i++) {
ret = nand_read_data_op(chip, &pbuf[i], sizeof(*pbuf), true);
ret = nand_read_data_op(chip, &pbuf[i], sizeof(*pbuf), true,
false);
if (ret) {
ret = 0;
goto free_onfi_param_page;