Commit 65e5cb54d017d60ec9d5de394715e5c95765f836

Authored by Heiko Schocher
1 parent f196044dfd

mtd, cfi, ubi: add missing writebufsize initialization

ff94bc40af3481d47546595ba73c136de6af6929 "mtd, ubi, ubifs: resync with Linux-3.14"
introduced the writebufsize field in struct mtd_info, which
is not initialized in the cfi_flash driver, which leads in
not working ubi on cfi flashes. Fix it

Signed-off-by: Heiko Schocher <hs@denx.de>
Reported-by: Andrew Ruder <andrew.ruder@elecsyscorp.com>
Acked-by: Stefan Roese <sr@denx.de>
Acked-by: Andrew Ruder <andrew.ruder@elecsyscorp.com>

Showing 1 changed file with 1 additions and 0 deletions Side-by-side Diff

drivers/mtd/cfi_mtd.c
... ... @@ -226,6 +226,7 @@
226 226 mtd->flags = MTD_CAP_NORFLASH;
227 227 mtd->size = fi->size;
228 228 mtd->writesize = 1;
  229 + mtd->writebufsize = mtd->writesize;
229 230  
230 231 mtd->_erase = cfi_mtd_erase;
231 232 mtd->_read = cfi_mtd_read;