diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2016-10-12 01:30:33 -0300 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2016-10-12 01:30:33 -0300 |
commit | e914f8eb445e8f74b00303c19c2ffceaedd16a05 (patch) | |
tree | 86b60bdecb3cf6abe8546f30803b673892a40335 /drivers/mtd/nand | |
parent | 1c29f4306f557ef5d9ed515ec8881f4d1735b058 (diff) |
Linux-libre 4.7.6-gnupck-4.7.6-gnu
Diffstat (limited to 'drivers/mtd/nand')
-rw-r--r-- | drivers/mtd/nand/mxc_nand.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/nand/mxc_nand.c b/drivers/mtd/nand/mxc_nand.c index 5173fadc9..57cbe2b83 100644 --- a/drivers/mtd/nand/mxc_nand.c +++ b/drivers/mtd/nand/mxc_nand.c @@ -943,7 +943,7 @@ static int mxc_v2_ooblayout_free(struct mtd_info *mtd, int section, struct nand_chip *nand_chip = mtd_to_nand(mtd); int stepsize = nand_chip->ecc.bytes == 9 ? 16 : 26; - if (section > nand_chip->ecc.steps) + if (section >= nand_chip->ecc.steps) return -ERANGE; if (!section) { |