0011-mtd-m25p80-set-SPI-transfer-type.patch 849 B

1234567891011121314151617181920212223242526272829
  1. From 531989d989855f673af76ef85300769a8a167405 Mon Sep 17 00:00:00 2001
  2. From: Phil Sutter <phil@nwl.cc>
  3. Date: Tue, 13 May 2014 00:25:59 +0200
  4. Subject: [PATCH] mtd: m25p80: set SPI transfer type
  5. ---
  6. drivers/mtd/devices/m25p80.c | 2 ++
  7. 1 file changed, 2 insertions(+)
  8. diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
  9. index ad19139..cdabcc0 100644
  10. --- a/drivers/mtd/devices/m25p80.c
  11. +++ b/drivers/mtd/devices/m25p80.c
  12. @@ -524,10 +524,12 @@ static int m25p80_read(struct mtd_info *mtd, loff_t from, size_t len,
  13. return -EINVAL;
  14. }
  15. + t[0].type = SPI_TRANSFER_FLASH_READ_CMD;
  16. t[0].tx_buf = flash->command;
  17. t[0].len = m25p_cmdsz(flash) + dummy;
  18. spi_message_add_tail(&t[0], &m);
  19. + t[1].type = SPI_TRANSFER_FLASH_READ_DATA;
  20. t[1].rx_buf = buf;
  21. t[1].rx_nbits = m25p80_rx_nbits(flash);
  22. t[1].len = len;
  23. --
  24. 1.8.5.3