mmc extcsd read <device>
Print extcsd data from <device>.
意思是读取EMMC的信息。看信息当然非常有用了。
mmc enh_area set <-y|-n|-c> <start KiB> <length KiB> <device>
Enable the enhanced user area for the <device>.
Dry-run only unless -y or -c is passed.
Use -c if more partitioning settings are still to come.
NOTE! This is a one-time programmable (unreversible) change.
Max Enhanced Area Size [MAX_ENH_SIZE_MULT]: 0x0001d2
i.e. 3817472 KiB
意思是加强区最大大小是3817472 KiB(就是我想做全盘SLC的大小)
先试一试,不真实写入,输入
mmc enh_area set -n 0 3817472 /dev/mmcblk0
输出没有报错
再来:
root@OpenWrt:~# mmc enh_area set -y 0 3817472 /dev/mmcblk0
命令输出:
Enhanced User Data Area Size [ENH_SIZE_MULT]: 0x0001d2
i.e. 3817472 KiB
Max Enhanced Area Size [MAX_ENH_SIZE_MULT]: 0x0001d2
i.e. 3817472 KiB
Done setting ENH_USR area on /dev/mmcblk0
setting OTP PARTITION_SETTING_COMPLETED!
Setting OTP PARTITION_SETTING_COMPLETED on /dev/mmcblk0 SUCCESS
Device power cycle needed for settings to take effect.
Confirm that PARTITION_SETTING_COMPLETED bit is set using 'extcsd read' after power cycle