mtd: point() for cfi_cmdset_0002, on simple maps only
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest4 patches 3 repliesIn review
- v33 patches 0 repliesSuperseded
- v23 patches 0 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 3 patches | 0 replies | Superseded |
Changes in v4 from the cover letter
- 1/4 also gates lpddr, map_ram and map_rom (compile-tested only).
- New 3/4: the per-device map sashiko asked for on v2 and v3.
- Rebased onto v7.4-rc1; Assisted-by dropped (an LLM helped write this series).
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | mtd: maps: only point() maps read through the simple accessorsdrivers/ drivers/ drivers/ +3 more | +22 | 0 replies | |
| 2/4 | mtd: cfi_cmdset_0002: implement point() for simple linear mapsDocumentation/ drivers/ | +168 | 1 reply | |
| 3/4 | MIPS: Octeon: flash: allocate the map per devicearch/ | +30 | 1 reply | |
| 4/4 | MIPS: Octeon: flash: use the simple map accessors without a shared eMMCarch/ | +31 | 1 reply |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.
Cover letter [PATCH v4 0/4] mtd: point() for cfi_cmdset_0002, on simple maps only
jffs2 scans a flash in place through mtd_point() when the chip driver offers it, and copies every used eraseblock otherwise. cfi_cmdset_0002 has no point(), so an Octeon CN6635 board with a 100 MB jffs2 partition on an 8-bit M29EW spends 15-30 s mounting it at every boot.
1/4 lets point() through only for maps read through the simple accessors; cfi_cmdset_0001, lpddr, map_ram and map_rom point today at maps whose own accessors swap bytes, switch pins or lock the bus. 2/4 adds point() to cfi_cmdset_0002 behind that gate.
3/4 gives each Octeon flash device its own map.
4/4 lets that map use the simple accessors when no eMMC shares the boot bus. 3/4 and 4/4 build alone, but 4/4 only pays off with 1/4 and 2/4, so taking all four through mtd with an ack from Thomas seems simplest.
Tested on that board with 7.3.4: the mount drops to 0.55-0.6 s, and an 8 MB file written to the jffs2 partition keeps its md5 across a reboot. v3 held its md5s across ten 8 MB write/delete rounds on 7.2.9. The series applies to v7.4-rc1.
One question: a cramfs on AMD flash falls back to the block device today. After 2/4 it keeps its image pointed while mounted, as it does on Intel flash, so jffs2 writes to the same chip wait until cramfs is unmounted. Is that acceptable, or should point() in cfi_cmdset_0002 be opt-in?
Changes in v4:
- 1/4 also gates lpddr, map_ram and map_rom (compile-tested only).
- New 3/4: the per-device map sashiko asked for on v2 and v3.
- Rebased onto v7.4-rc1; Assisted-by dropped (an LLM helped write this series).
Earlier changes, in v4 numbering:
- v3: in 2/4, an XIP erase no longer lets a point through either.
- v2: in 2/4, a point no longer suspends an erase in progress; 4/4 checks the bank width before ioremap().
v3: https://lore.kernel.org/all/[email protected]/
v2: https://lore.kernel.org/all/[email protected]/
v1: https://lore.kernel.org/all/[email protected]/
Orgad Shaneh (4):
mtd: maps: only point() maps read through the simple accessors
mtd: cfi_cmdset_0002: implement point() for simple linear maps
MIPS: Octeon: flash: allocate the map per device
MIPS: Octeon: flash: use the simple map accessors without a shared eMMC
Documentation/filesystems/cramfs.rst | 11 ++- arch/mips/cavium-octeon/flash_setup.c | 73 +++++++++++---- drivers/mtd/chips/cfi_cmdset_0001.c | 2 +- drivers/mtd/chips/cfi_cmdset_0002.c | 167 +++++++++++++++++++++++++++++++++- drivers/mtd/chips/map_ram.c | 4 +- drivers/mtd/chips/map_rom.c | 6 +- drivers/mtd/lpddr/lpddr_cmds.c | 2 +- drivers/mtd/maps/map_funcs.c | 12 +++ include/linux/mtd/map.h | 2 + 9 files changed, 245 insertions(+), 34 deletions(-)
Signature · 1 line
2.53.0