aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
authorBrian Norris <computersforpeace@gmail.com>2012-05-02 13:15:00 -0400
committerDavid Woodhouse <David.Woodhouse@intel.com>2012-05-14 00:21:39 -0400
commitd112dc7fa65882279434622a40cbe7677a780c46 (patch)
treead8a5625e0057cf87606006094c685a81834d7c0 /drivers/mtd
parente47f3db4587c5486d3d5838fd4bef4f9c3b12205 (diff)
mtd: eLBC NAND: utilize oob_required parameter
Don't read OOB if the caller doesn't require it. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Reviewed-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/nand/fsl_elbc_nand.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/mtd/nand/fsl_elbc_nand.c b/drivers/mtd/nand/fsl_elbc_nand.c
index 11e34010272f..784293806110 100644
--- a/drivers/mtd/nand/fsl_elbc_nand.c
+++ b/drivers/mtd/nand/fsl_elbc_nand.c
@@ -754,7 +754,8 @@ static int fsl_elbc_read_page(struct mtd_info *mtd, struct nand_chip *chip,
754 struct fsl_elbc_fcm_ctrl *elbc_fcm_ctrl = ctrl->nand; 754 struct fsl_elbc_fcm_ctrl *elbc_fcm_ctrl = ctrl->nand;
755 755
756 fsl_elbc_read_buf(mtd, buf, mtd->writesize); 756 fsl_elbc_read_buf(mtd, buf, mtd->writesize);
757 fsl_elbc_read_buf(mtd, chip->oob_poi, mtd->oobsize); 757 if (oob_required)
758 fsl_elbc_read_buf(mtd, chip->oob_poi, mtd->oobsize);
758 759
759 if (fsl_elbc_wait(mtd, chip) & NAND_STATUS_FAIL) 760 if (fsl_elbc_wait(mtd, chip) & NAND_STATUS_FAIL)
760 mtd->ecc_stats.failed++; 761 mtd->ecc_stats.failed++;