linux-stable/drivers/mtd/devices
Joachim Wiberg 7b09acdcb9 mtd: block2mtd: add support for an optional custom MTD label
This patch adds support for an optional MTD label for mtd2block emulated
MTD devices.  Useful when, e.g., testing device images using Qemu.

The following line in /etc/fstab can then be used to mount a file system
regardless if running on an embedded system, or emulated with block2mtd:

    mtd:Config  /mnt    jffs2   noatime,nodiratime      0    0

Kernel command line syntax in the emulated case:

    block2mtd.block2mtd=/dev/sda,,Config

Notice the ',,' it is the optional erase_size, which like before this
patch, defaults to PAGE_SIZE when omitted.  Hence the strlen() check.

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20211009060955.552636-3-troglobit@gmail.com
2021-10-15 12:30:35 +02:00
..
Kconfig mtd: devices: add support for microchip 48l640 EERAM 2021-06-11 20:43:12 +02:00
Makefile mtd: devices: add support for microchip 48l640 EERAM 2021-06-11 20:43:12 +02:00
bcm47xxsflash.c remove ioremap_nocache and devm_ioremap_nocache 2020-01-06 09:45:59 +01:00
bcm47xxsflash.h
block2mtd.c mtd: block2mtd: add support for an optional custom MTD label 2021-10-15 12:30:35 +02:00
docg3.c mtd: devices: docg3: Fix kernel-doc 'bad line' and 'excessive doc' issues 2020-11-20 12:37:30 +01:00
docg3.h
lart.c mtd: Avoid comma separated statements 2020-08-27 14:16:31 +02:00
mchp23k256.c mtd: devices: fix mchp23k256 read and write 2019-11-14 10:58:03 +01:00
mchp48l640.c mtd: devices: mchp48l640: Fix memory leak on cmd 2021-08-06 21:44:09 +02:00
ms02-nv.c mtd: devices: Remove superfluous "break" 2021-05-26 10:58:26 +02:00
ms02-nv.h
mtd_dataflash.c mtd: core: Constify buf in mtd_write_user_prot_reg() 2021-04-16 20:30:54 +02:00
mtdram.c
phram.c mtd: phram: Fix error return code in phram_setup() 2021-05-10 10:44:34 +02:00
pmc551.c
powernv_flash.c mtd: devices: powernv_flash: Add function names to headers and fix 'dev' 2020-11-20 12:37:33 +01:00
serial_flash_cmds.h
slram.c
spear_smi.c mtd: spear_smi: use for_each_child_of_node() macro 2020-09-15 10:14:36 +02:00
sst25l.c
st_spi_fsm.c mtd: st_spi_fsm: convert comma to semicolon 2021-02-01 18:58:38 +01:00