Hi Andrew,

I may be mistaken here, but this here references the driver that is to be used, or not?

            compatible = "st,m25p16";

For me that does not work with CONFIG_MTD_M25P80. As far as I can see there is also no
reference whatsoever to the kernel selectable m25p80 in the current DT for kirkwood-b3,
so I'm not sure why you'd find this consistent with it.

In the kernels I tried, m25p80 driver is simply not happy with m25p16 being defined in DT.

Regards,
Gordon Bos

On 07/02/2015 18:36, Andrew Lunn wrote:
On Sat, Feb 07, 2015 at 06:15:12PM +0100, Gordon Bos wrote:
Hi Andrew,

Unsure how it can work for you, but this is the corresponding entry
from the Excito release:

---
|/*****************************************************************************
 * 2048KB SPI Flash on Boot Device (Numonyx MP25P16)
 ****************************************************************************/

static struct mtd_partition bubba3_flash_parts[] = {
 {
 .name = "u-boot",
 .size = SZ_512K+SZ_256K,
 .offset = 0,
 },
 {
 .name = "env",
 .size = SZ_128K,
 .offset = MTDPART_OFS_NXTBLK,
 },
 {
 .name = "data",
 .size = MTDPART_SIZ_FULL,
 .offset = MTDPART_OFS_NXTBLK,
 },
};

static const struct flash_platform_data bubba3_flash = {
 .type = "m25p16",
So the device is a m25p16. 

 .name = "spi_flash",
 .parts = bubba3_flash_parts,
 .nr_parts = ARRAY_SIZE(bubba3_flash_parts),
};

static struct spi_board_info __initdata bubba3_spi_slave_info[] = {
 {
 .modalias = "m25p80",
And the driver is m25p80.

This is consistent with the current device tree description. 

So what actually happens when you use the mainline DT on your device?

I'm not going to accept any changes until we understand what problems
you have and why it works for me.

Thanks
    Andrew