NAND: Add flags to the probe calls to control scan behaviour
Ben Dooks
ben at simtec.co.uk
Mon Oct 19 06:36:39 EDT 2009
Artem Bityutskiy wrote:
> On Tue, 2009-10-13 at 10:00 +0100, Ben Dooks wrote:
>> plain text document attachment (nand-update-probe2.patch)
>> Add a flags field to the two scan calls to control the behaviour of the
>> scan process. Currently the only flag we define is NAND_PROBE_SPECULATIVE
>> to stop the user-worrying messages 'No NAND device found!!!'. This message
>> often worries users (was three exclamation marks really necessary?) and is
>> even worse in systems such as the Simtec Osiris where there may be optional
>> NAND devices which are not known until probe time.
>>
>> The approach is to change nand_scan_ident and nand_scan to have a new flags
>> field, and add wrapper functions to the header files so that we do not have
>> to get around all the drivers doing a search and replace. If we where to
>> change all the call sites for nand_scan() and nand_scan_ident() we would
>> touch about 40 drivers.
>>
>> Signed-off-by: Ben Dooks <ben at simtec.co.uk>
>> Signed-off-by: Simtec Linux Team <linux at simtec.co.uk>
>
> So you are introducing this new flag just to make generic NAND layer be
> silent if it cannot identify device type, right?
I'd rather it be silent if it cannot find a device, as a number of our boards
have slots where NAND devices may be fitted by the customer and as such all
possibilities are registered with the NAND driver.
> Could you please elaborate why more why is this needed a bit more? What
> is the driver?
Because customers get scared when errors with '!!!' turn up.
> Why not to just remove that print at all?
Possible, but what about the case where there is a legitimate problem with
the device that is supposed to be there.
--
Ben Dooks, Software Engineer, Simtec Electronics
http://www.simtec.co.uk/
More information about the linux-mtd
mailing list