diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2019-07-18 14:53:26 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2019-08-06 13:55:03 +0200 |
commit | afc8ed054de6e8839a745fd5520828c50711629f (patch) | |
tree | 1249d28d31fdc36936f639fc0c914152f82b9c97 /include | |
parent | 61b0b210a81fef51eeca861b5886837beb2e7cd6 (diff) | |
download | barebox-afc8ed054de6e8839a745fd5520828c50711629f.tar.gz barebox-afc8ed054de6e8839a745fd5520828c50711629f.tar.xz |
mtd: nand-mxs: change API between NAND driver and fcb code
The imx-bbu-nand-fcb update handler code calls into the NAND driver
to get the ecc strength and bad block marker position. Change the
API so that only a single function is necessary and not three functions.
Also in future the ecc strength will be configurable via device tree.
This means static parameters like page size / oob size are no longer
enough to calculate the ecc strength and so we store a pointer to our
mtd_info struct in a static global variable.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/mtd/nand_mxs.h | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/include/linux/mtd/nand_mxs.h b/include/linux/mtd/nand_mxs.h index eca31777f5..7eda0b8e63 100644 --- a/include/linux/mtd/nand_mxs.h +++ b/include/linux/mtd/nand_mxs.h @@ -27,11 +27,6 @@ * update handler code, the generic calculation from the driver code is used. */ -uint32_t mxs_nand_get_ecc_strength(uint32_t page_data_size, - uint32_t page_oob_size); - -uint32_t mxs_nand_mark_byte_offset(struct mtd_info *mtd); - -uint32_t mxs_nand_mark_bit_offset(struct mtd_info *mtd); +int mxs_nand_get_geo(int *ecc_strength, int *bb_mark_bit_offset); #endif /* __NAND_MXS_H */ |