mtd: nand: fix oob read pannic.
authorYonghui Yu <yonghui.yu@amlogic.com>
Thu, 8 Jun 2017 13:00:13 +0000 (21:00 +0800)
committerJianxin Pan <jianxin.pan@amlogic.com>
Fri, 16 Jun 2017 04:55:35 +0000 (21:55 -0700)
commit8b769d45af4db14ffc402197854c1625c74db472
treed088d203b485cb8ab174dcf0f20b1ef75233af8b
parent08fb3d0741fff02fa6486395244d0a029f63c284
mtd: nand: fix oob read pannic.

PD#145890: nand: fix oob read

When reading oob by nandread from toolbox of andriod,
the oob should be protected. so we read back the whole
page with ecc on, and copy out oob only.

Change-Id: I08f35396015316a35631727dfbfedb862567d913
Signed-off-by: Yonghui Yu <yonghui.yu@amlogic.com>
drivers/amlogic/mtd/aml_mtd.h
drivers/amlogic/mtd/aml_nand.c
drivers/amlogic/mtd/boot.c
drivers/amlogic/mtd/m3_nand.c