All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/6] Improve timings handling in the NAND framework
@ 2018-02-03  9:55 Miquel Raynal
  2018-02-03  9:55 ` [PATCH 1/6] mtd: nand: Avoid setting again the timings to mode 0 after a reset Miquel Raynal
                   ` (5 more replies)
  0 siblings, 6 replies; 15+ messages in thread
From: Miquel Raynal @ 2018-02-03  9:55 UTC (permalink / raw)
  To: Boris Brezillon, Richard Weinberger, David Woodhouse,
	Brian Norris, Marek Vasut, Cyrille Pitchen
  Cc: linux-mtd, Miquel Raynal

Hello,

This series evolves how GET/SET_FEATURES operations are handled by the
NAND core by adding two helpers that should be called instead of calling
directly the ->onfi_get/set_feature() hooks.

Then, the parameter page that was always allocated no matter if the NAND
core could make use of it is dropped. Instead, a much smaller structure
is embedded in the nand_chip structure and just stores the information
that will be useful for the core. Future enhancements of the core that
will need more information will just have to add a new entry in this
structure and fill it during the detection phase. A bitmap is used to
know which optional feature is actually supported.

This give the possibility in vendor code to overload this bitmap and
force the addition/removal of supported features in the list, depending
for instance on the NAND chip currently being used.

This new possibility is effectively used for Macronix NAND chip
MX30LF2G18AC. This chip supports natively the timing mode 5, and its
parameter page indicates that it supports GET/SET_FEATURES on timing
modes, while in reality it does not. Removing this feature from the
supported bitmap makes it usable at high speed instead of unnecessarily
limiting it to timing mode 0.

Thank you,
Miquèl

Miquel Raynal (6):
  mtd: nand: Avoid setting again the timings to mode 0 after a reset
  mtd: nand: Use wrappers to call onfi GET/SET_FEATURES
  mtd: nand: mxc: Remove useless checks in GET/SET_FEATURES functions
  mtd: nand: Stop using a static parameter page for all chips
  mtd: nand: Allow vendors to declare (un)supported features
  mtd: nand: macronix: Unflag the support of changing timings for
    MX30LF2G18AC

 drivers/mtd/nand/mxc_nand.c      |  10 --
 drivers/mtd/nand/nand_base.c     | 259 ++++++++++++++++++++++++++-------------
 drivers/mtd/nand/nand_macronix.c |  12 ++
 drivers/mtd/nand/nand_micron.c   |  35 +++---
 drivers/mtd/nand/nand_timings.c  |  10 +-
 include/linux/mtd/rawnand.h      |  53 ++++----
 6 files changed, 231 insertions(+), 148 deletions(-)

-- 
2.14.1

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

end of thread, other threads:[~2018-03-01 23:21 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-03  9:55 [PATCH 0/6] Improve timings handling in the NAND framework Miquel Raynal
2018-02-03  9:55 ` [PATCH 1/6] mtd: nand: Avoid setting again the timings to mode 0 after a reset Miquel Raynal
2018-02-03  9:55 ` [PATCH 2/6] mtd: nand: Use wrappers to call onfi GET/SET_FEATURES Miquel Raynal
2018-02-06 14:55   ` Boris Brezillon
2018-02-20 11:12     ` Miquel Raynal
2018-02-03  9:55 ` [PATCH 3/6] mtd: nand: mxc: Remove useless checks in GET/SET_FEATURES functions Miquel Raynal
2018-02-03  9:55 ` [PATCH 4/6] mtd: nand: Stop using a static parameter page for all chips Miquel Raynal
2018-02-14  8:41   ` Boris Brezillon
2018-03-01 23:21     ` Miquel Raynal
2018-02-14  8:53   ` Boris Brezillon
2018-02-03  9:55 ` [PATCH 5/6] mtd: nand: Allow vendors to declare (un)supported features Miquel Raynal
2018-02-14  8:51   ` Boris Brezillon
2018-03-01 23:21     ` Miquel Raynal
2018-02-03  9:55 ` [PATCH 6/6] mtd: nand: macronix: Unflag the support of changing timings for MX30LF2G18AC Miquel Raynal
2018-02-14  9:14   ` Boris Brezillon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.