public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* [RFC/PATCH] pxa3xx-nand: Removing a stupid customized device detection
@ 2013-09-06 14:40 Ezequiel Garcia
  2013-09-06 14:40 ` [RFC/PATCH] mtd: nand: pxa3xx: Remove redundant device probing Ezequiel Garcia
  0 siblings, 1 reply; 4+ messages in thread
From: Ezequiel Garcia @ 2013-09-06 14:40 UTC (permalink / raw)
  To: linux-mtd
  Cc: Thomas Petazzoni, Lior Amsalem, Tawfik Bayouk, haojian.zhuang,
	Daniel Mack, b32955, Ezequiel Garcia, Gregory Clement,
	Brian Norris

The current pxa3xx-nand driver implements its own device detection, duplicating
a funcionality that the NAND base code provides, through nand_scan_ident() plus
nand_scan_tail().

This is not only ugly, but also wrong for it implements a deprecated (non-ONFI)
device probing method and force the driver to keep its own list of known devices.
In addition, it settles a very bad example for future NAND drivers.

My suggestion is to simply kill the device detection and instead rely fully
on the findings of nand_scan_ident(). After the first nand_scan_iden() the driver
can configure the controller according to the detected device.

However, I'm concerned about the impact of this patch on already deployed systems,
and by the fact that we're removing the built-in "timing parameter" table.
So, I'm wondering:

 * What's others opinion on this?

 * Can I try this cleanup (or a similar one, maybe being more careful)

 * ... or should I just forget about it completely and learn to live it?

I've noticed that the PXA maintainers have remain largely silent on the recent
patches for this pxa3xx-nand driver, but I would definitely appreciate their
point of view this time.

A warning note: this doesn't build on latest l2-mtd, and I'm posting it just
to show the idea and trigger the discussion.

Thanks!

Ezequiel Garcia (1):
  mtd: nand: pxa3xx: Remove redundant device probing

 drivers/mtd/nand/pxa3xx_nand.c | 134 ++---------------------------------------
 1 file changed, 4 insertions(+), 130 deletions(-)

-- 
1.8.1.5

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

end of thread, other threads:[~2013-09-09  9:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-06 14:40 [RFC/PATCH] pxa3xx-nand: Removing a stupid customized device detection Ezequiel Garcia
2013-09-06 14:40 ` [RFC/PATCH] mtd: nand: pxa3xx: Remove redundant device probing Ezequiel Garcia
2013-09-09  8:51   ` Daniel Mack
2013-09-09  9:53     ` Ezequiel Garcia

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