From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail.bootlin.com ([62.4.15.54]) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fOlAK-0007Mf-VE for linux-mtd@lists.infradead.org; Fri, 01 Jun 2018 14:36:30 +0000 From: Boris Brezillon To: David Woodhouse , Brian Norris , Boris Brezillon , Marek Vasut , Richard Weinberger , linux-mtd@lists.infradead.org, Mark Brown , linux-spi@vger.kernel.org Cc: Vignesh R , Cyrille Pitchen , Thomas Petazzoni Subject: [RFC PATCH 0/2] spi: spi-mem: Add a direct mapping API Date: Fri, 1 Jun 2018 16:36:01 +0200 Message-Id: <20180601143603.4047-1-boris.brezillon@bootlin.com> List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Hello, I know this topic has come up several times during the development of the spi-mem layer, so I'm finally proposing something to expose this feature to SPI mem drivers. Right now it's a rather simple implementation where only on spi_mem_op operation can be attached to a direct mapping, meaning that write access to SPI NOR devices will still require manually sending the WR_EN operation before using the direct mapping, but it should still improve perfs overall, and should match how most SPI controller drivers describe direct mappings (a SPI memory operation attached to the range of memory that you want to directly map in the CPU address space). Feel free to comment on this implementation. Thanks, Boris Boris Brezillon (2): spi: spi-mem: Add a new API to support direct mapping mtd: m25p80: Use the SPI mem direct API to possibly improve performances drivers/mtd/devices/m25p80.c | 149 ++++++++++++++---------- drivers/spi/spi-mem.c | 267 +++++++++++++++++++++++++++++++++++++++---- include/linux/spi/spi-mem.h | 72 ++++++++++++ 3 files changed, 407 insertions(+), 81 deletions(-) -- 2.14.1