mediatek: mtk-snand: check request size against chip info
authorChuanhong Guo <gch981213@gmail.com>
Mon, 23 Aug 2021 16:31:17 +0000 (00:31 +0800)
committerChuanhong Guo <gch981213@gmail.com>
Fri, 27 Aug 2021 02:26:25 +0000 (10:26 +0800)
commit388127abd139d3ebbe761392403d58d58f5957cd
treef8151c3845e946a2ea45410568c980475e57febd
parentb600aee3edbbf66e8cc714a7d5f69e4505a7445a
mediatek: mtk-snand: check request size against chip info

mtd->size will be overrided by BMT which makes all mtd requests made by
bmt fail in request size checking.
this commit changes the driver to check against actual chip size in chip
info as a workaround.

Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
target/linux/mediatek/files-5.10/drivers/mtd/mtk-snand/mtk-snand-mtd.c