]> git.sur5r.net Git - u-boot/commitdiff
sf: Do not force the DT memory map size to exactly match the device
authorPhil Edworthy <PHIL.EDWORTHY@renesas.com>
Fri, 9 Dec 2016 15:03:39 +0000 (15:03 +0000)
committerJagan Teki <jagan@amarulasolutions.com>
Thu, 15 Dec 2016 15:57:28 +0000 (16:57 +0100)
As long as the memory mapped size specifeid in the DT is the same or
bigger than the device size, it will work. So do not force the sizes
to be identical.

Signed-off-by: Phil Edworthy <phil.edworthy@renesas.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
drivers/mtd/spi/spi_flash.c

index 41fc0a6a2446da0fa96de47efe93939d4dc0aed7..b902540e4f636a7b1344ba4ed162d2a0c9ec0fcd 100644 (file)
@@ -985,7 +985,7 @@ int spi_flash_decode_fdt(const void *blob, struct spi_flash *flash)
                return 0;
        }
 
-       if (flash->size != size) {
+       if (flash->size > size) {
                debug("%s: Memory map must cover entire device\n", __func__);
                return -1;
        }