public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* [RFT PATCH 0/4] mtd: spi-nor: code refactoring and layering
@ 2015-08-13 22:46 Brian Norris
  2015-08-13 22:46 ` [RFT PATCH 1/4] mtd: fsl-quadspi: use automatic spi-nor detection Brian Norris
                   ` (3 more replies)
  0 siblings, 4 replies; 18+ messages in thread
From: Brian Norris @ 2015-08-13 22:46 UTC (permalink / raw)
  To: linux-mtd
  Cc: Rafał Miłecki, Joachim Eastwood, Ezequiel Garcia,
	Marek Vasut, Han Xu, Brian Norris

Hi,

I found a few areas where code should probably be refactored in the spi-nor
driver layering while reviewing drivers recently. I don't have hardware for
some of this, hence the Request For Test.

Potential future patch: push the MTD registration into a spi_nor_*() API. I
would have just merged it into spi_nor_scan() now, but there are occasionally a
few things that drivers want to do before exposing the MTD but after the SPI
NOR probing. Perhaps a bottom-half API, and an optional all-in-one API that
does both, similar to nand_base's nand_scan_ident(), nand_scan_tail(), and
nand_scan()?

Anyway, enough random musings. Happy reviewing/testing.

Brian

Brian Norris (4):
  mtd: fsl-quadspi: use automatic spi-nor detection
  mtd: spi-nor: assign mtd->priv in spi_nor_scan()
  mtd: spi-nor: add forward declaration for mtd_info
  mtd: spi-nor: embed struct mtd_info within struct spi_nor

 drivers/mtd/devices/m25p80.c      | 11 ++++-------
 drivers/mtd/spi-nor/fsl-quadspi.c | 19 +++++--------------
 drivers/mtd/spi-nor/nxp-spifi.c   |  7 ++-----
 drivers/mtd/spi-nor/spi-nor.c     |  9 +++++----
 include/linux/mtd/spi-nor.h       |  4 +++-
 5 files changed, 19 insertions(+), 31 deletions(-)

-- 
2.5.0.276.gf5e568e

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2015-09-01 23:55 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-13 22:46 [RFT PATCH 0/4] mtd: spi-nor: code refactoring and layering Brian Norris
2015-08-13 22:46 ` [RFT PATCH 1/4] mtd: fsl-quadspi: use automatic spi-nor detection Brian Norris
2015-08-13 23:09   ` Marek Vasut
2015-08-13 23:24     ` Brian Norris
2015-08-13 23:54       ` Marek Vasut
2015-08-14  5:40       ` Michal Suchanek
2015-08-18  2:56         ` Brian Norris
2015-08-18  3:15           ` Han Xu
2015-08-18  8:09             ` Huang Shijie
2015-09-01 18:41               ` Brian Norris
2015-09-01 23:40   ` Han Xu
2015-09-01 23:54     ` Brian Norris
2015-08-13 22:46 ` [RFT PATCH 2/4] mtd: spi-nor: assign mtd->priv in spi_nor_scan() Brian Norris
2015-08-14 14:48   ` Joachim Eastwood
2015-08-13 22:46 ` [RFT PATCH 3/4] mtd: spi-nor: add forward declaration for mtd_info Brian Norris
2015-08-14 14:49   ` Joachim Eastwood
2015-08-13 22:46 ` [RFT PATCH 4/4] mtd: spi-nor: embed struct mtd_info within struct spi_nor Brian Norris
2015-08-14 14:52   ` Joachim Eastwood

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox