Merge tag 'fuse-update-4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/mszered...
[sfrench/cifs-2.6.git] / Documentation / block / cmdline-partition.txt
1 Embedded device command line partition parsing
2 =====================================================================
3
4 The "blkdevparts" command line option adds support for reading the
5 block device partition table from the kernel command line.
6
7 It is typically used for fixed block (eMMC) embedded devices.
8 It has no MBR, so saves storage space. Bootloader can be easily accessed
9 by absolute address of data on the block device.
10 Users can easily change the partition.
11
12 The format for the command line is just like mtdparts:
13
14 blkdevparts=<blkdev-def>[;<blkdev-def>]
15   <blkdev-def> := <blkdev-id>:<partdef>[,<partdef>]
16     <partdef> := <size>[@<offset>](part-name)
17
18 <blkdev-id>
19     block device disk name. Embedded device uses fixed block device.
20     Its disk name is also fixed, such as: mmcblk0, mmcblk1, mmcblk0boot0.
21
22 <size>
23     partition size, in bytes, such as: 512, 1m, 1G.
24     size may contain an optional suffix of (upper or lower case):
25       K, M, G, T, P, E.
26     "-" is used to denote all remaining space.
27
28 <offset>
29     partition start address, in bytes.
30     offset may contain an optional suffix of (upper or lower case):
31       K, M, G, T, P, E.
32
33 (part-name)
34     partition name. Kernel sends uevent with "PARTNAME". Application can
35     create a link to block device partition with the name "PARTNAME".
36     User space application can access partition by partition name.
37
38 Example:
39     eMMC disk names are "mmcblk0" and "mmcblk0boot0".
40
41   bootargs:
42     'blkdevparts=mmcblk0:1G(data0),1G(data1),-;mmcblk0boot0:1m(boot),-(kernel)'
43
44   dmesg:
45     mmcblk0: p1(data0) p2(data1) p3()
46     mmcblk0boot0: p1(boot) p2(kernel)