Merge tag 'efi-2020-07-rc3' of https://gitlab.denx.de/u-boot/custodians/u-boot-efi
[oweals/u-boot.git] / drivers / mtd / cfi_mtd.c
index ac805ff1e9c7b91f87097d97c8f4e578a06fec3d..a5bb0962e556937781013210da098aed43e19b8c 100644 (file)
@@ -1,16 +1,15 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * (C) Copyright 2008 Semihalf
  *
  * Written by: Piotr Ziecik <kosmo@semihalf.com>
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
 #include <flash.h>
 #include <malloc.h>
 
-#include <asm/errno.h>
+#include <linux/errno.h>
 #include <linux/mtd/mtd.h>
 #include <linux/mtd/concat.h>
 #include <mtd/cfi_flash.h>
@@ -226,6 +225,7 @@ int cfi_mtd_init(void)
                mtd->flags              = MTD_CAP_NORFLASH;
                mtd->size               = fi->size;
                mtd->writesize          = 1;
+               mtd->writebufsize       = mtd->writesize;
 
                mtd->_erase             = cfi_mtd_erase;
                mtd->_read              = cfi_mtd_read;