mtd: add new API for handling MTD registration
authorDmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Fri, 25 Mar 2011 19:26:25 +0000 (22:26 +0300)
committerArtem Bityutskiy <artem.bityutskiy@intel.com>
Sun, 11 Sep 2011 12:02:05 +0000 (15:02 +0300)
commit1c4c215cbdcbfd08183d82b2953591cd00564422
treebb43365c3e16e3634a6f53dab61c2e8e6145563b
parent3761a6ddacc83e5a6b4482d98fbf212805381486
mtd: add new API for handling MTD registration

Lots (nearly all) mtd drivers contain nearly the similar code that
calls parse_mtd_partitions, provides some platform-default values, if
parsing fails, and registers  mtd device.

This is an aim to provide single implementation of this scenario:
mtd_device_parse_register() which will handle all this parsing and
defaults.

Artem: amended comments

Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
drivers/mtd/mtdcore.c
include/linux/mtd/mtd.h