
On Tuesday 08 August 2017 10:27 AM, Chris Packham wrote:
"jedec,spi-nor" is used by Linux for many boards with spi flash. In fact according to the binding documentation this must be included for any SPI NOR flash that can be identified by the JEDEC READ ID opcode (0x9F). Make device trees more portable between Linux an U-Boot by supporting "jedec,spi-nor" in addition to the U-Boot specific "spi-flash".
Signed-off-by: Chris Packham judge.packham@gmail.com
+1
Use of U-Boot specific compatible "spi-flash" has caused quite a bit of confusions and also problems while syncing U-Boot and kernel DTs. IMO, its better if we could probe JEDEC SPI NOR flashes based on generic "jedec,spi-nor" compatible as well like Linux.
This fixes my issues with the spi speed selection on db-88f6820-amc. I didn't find anything in the commit message from the initial implementation saying that "jedec,spi-nor" was omitted intentionally so I've settled on this instead of updating armada-385-amc.dts.
If there is a good reason not to make this change I'm happy to submit a patch that just updates armada-385-amc.dts.> drivers/mtd/spi/sf_probe.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/drivers/mtd/spi/sf_probe.c b/drivers/mtd/spi/sf_probe.c index 7b296378d2be..1953ec3cb748 100644 --- a/drivers/mtd/spi/sf_probe.c +++ b/drivers/mtd/spi/sf_probe.c @@ -164,6 +164,7 @@ static const struct dm_spi_flash_ops spi_flash_std_ops = {
static const struct udevice_id spi_flash_std_ids[] = { { .compatible = "spi-flash" },
- { .compatible = "jedec,spi-nor" }, { }
};