本文轉載自:http://blog.csdn.net/kris_fei/article/details/77318410
Platform: Rockchip
OS: Android 6.0
Kernel: 3.10.92
有時候需要知道mmcblk對應的分割槽是哪一個,其實驅動已經完成這個功能了,如下:
root@rk3288:/dev/block/platform/ff0f0000.rksdmmc/by-name # ls -l
lrwxrwxrwx root root 2017-01-01 13:41 backup -> /dev/block/mmcblk0p7
lrwxrwxrwx root root 2017-01-01 13:41 boot -> /dev/block/mmcblk0p5
lrwxrwxrwx root root 2017-01-01 13:41 cache -> /dev/block/mmcblk0p8
lrwxrwxrwx root root 2017-01-01 13:41 kernel -> /dev/block/mmcblk0p4
lrwxrwxrwx root root 2017-01-01 13:41 kpanic -> /dev/block/mmcblk0p9
lrwxrwxrwx root root 2017-01-01 13:41 metadata -> /dev/block/mmcblk0p11
lrwxrwxrwx root root 2017-01-01 13:41 misc -> /dev/block/mmcblk0p2
lrwxrwxrwx root root 2017-01-01 13:41 radical_update -> /dev/block/mmcblk0p12
lrwxrwxrwx root root 2017-01-01 13:41 recovery -> /dev/block/mmcblk0p6
lrwxrwxrwx root root 2017-01-01 13:41 resource -> /dev/block/mmcblk0p3
lrwxrwxrwx root root 2017-01-01 13:41 system -> /dev/block/mmcblk0p10
lrwxrwxrwx root root 2017-01-01 13:41 uboot -> /dev/block/mmcblk0p1
lrwxrwxrwx root root 2017-01-01 13:41 userdata -> /dev/block/mmcblk0p13