Re: fsl-espi, m25p80 and max_transfer_size / max_message_size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 2016-11-14 20:06, schrieb Heiner Kallweit:
Am 14.11.2016 um 15:22 schrieb Michael Walle:
Hi,

since commit 02a595d5d6e4 (spi: fsl-espi: eliminate spi nor flash read loop) the fsl-espi is (partly?) broken. Reading 64k from the flash results in the following error:
  fsl_espi ffe110000.spi: message too long, size is 65540 bytes
  spi_master spi32766: failed to transfer one message from queue

We are using the m25p80 driver which checks the max_transfer_size. The fsl-espi driver sets the max_message_size to 64k. As far as I understand it, a message can contain multiple transfers. The m25p80 uses two transfers (one 4 byte and one with max_transfer_size, that is 64k) and thus the message has a total length of 65540 bytes which is too long for the driver.

I didn't find where the max_message_size is checked and I also don't know which part is resposible to handle the correct sizes. The m25p80 driver? Should it use spi_max_message_size() instead of spi_max_transfer_size() ?

Your mail actually doesn't come as a surprise. The patch addressing
this scenario is waiting to be applied.
See here: https://www.spinics.net/lists/linux-spi/msg08844.html

Rgds, Heiner

Thanks.

-michael
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux