]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: call of_platform_populate() for MTD partitions
authorRafał Miłecki <rafal@milecki.pl>
Tue, 10 May 2022 13:12:59 +0000 (15:12 +0200)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Mon, 16 May 2022 16:37:48 +0000 (18:37 +0200)
commitfdc1bb252965d471991baa2c75bcaa451131811f
treef021207fad662a6ff6ddc70fd9c9d6cb3b268fc5
parent15854fb7eec98849910064616741cf8e0c98fe1b
mtd: call of_platform_populate() for MTD partitions

Until this change MTD subsystem supported handling partitions only with
MTD partitions parsers. That's a specific / limited API designed around
partitions.

Some MTD partitions may however require different handling. They may
contain specific data that needs to be parsed and somehow extracted. For
that purpose MTD subsystem should allow binding of standard platform
drivers.

An example can be U-Boot (sub)partition with environment variables.
There exist a "u-boot,env" DT binding for MTD (sub)partition that
requires an NVMEM driver.

Ref: c8fa40f874b0 ("dt-bindings: nvmem: add U-Boot environment variables binding")
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20220510131259.555-1-zajec5@gmail.com
drivers/mtd/mtdpart.c