summaryrefslogtreecommitdiff
path: root/drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c
diff options
context:
space:
mode:
authorMiquel Raynal <miquel.raynal@bootlin.com>2018-03-19 16:47:20 +0300
committerBoris Brezillon <boris.brezillon@bootlin.com>2018-03-20 11:46:02 +0300
commit97baea1e6b74c73973fa0922252f880ab15450ea (patch)
tree45bf059e4fcf9ba28672b9c175d0a9417de7230e /drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c
parentb958758e686aebe84672acc8871aca87d04f13a3 (diff)
downloadlinux-97baea1e6b74c73973fa0922252f880ab15450ea.tar.xz
mtd: rawnand: use wrappers to call onfi GET/SET_FEATURES
Prepare the fact that some features managed by GET/SET_FEATURES could be overloaded by vendor code. To handle this logic, use new wrappers instead of directly call the ->get/set_features() hooks. Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Diffstat (limited to 'drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c')
-rw-r--r--drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c b/drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c
index f78d907ca61e..039f2795617f 100644
--- a/drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c
+++ b/drivers/mtd/nand/raw/gpmi-nand/gpmi-lib.c
@@ -934,15 +934,13 @@ static int enable_edo_mode(struct gpmi_nand_data *this, int mode)
/* [1] send SET FEATURE command to NAND */
feature[0] = mode;
- ret = nand->set_features(mtd, nand,
- ONFI_FEATURE_ADDR_TIMING_MODE, feature);
+ ret = nand_set_features(nand, ONFI_FEATURE_ADDR_TIMING_MODE, feature);
if (ret)
goto err_out;
/* [2] send GET FEATURE command to double-check the timing mode */
memset(feature, 0, ONFI_SUBFEATURE_PARAM_LEN);
- ret = nand->get_features(mtd, nand,
- ONFI_FEATURE_ADDR_TIMING_MODE, feature);
+ ret = nand_get_features(nand, ONFI_FEATURE_ADDR_TIMING_MODE, feature);
if (ret || feature[0] != mode)
goto err_out;