2015年12月31日 星期四

[Linux Command] blockdev - call block device ioctls from the command line

# blockdev --getsize64 /dev/mtdblock0
131072

# blockdev --getsz /dev/mtdblock0
256
256 (sector) * 512 (bytes/sector) = 131072 bytes

Restore uboot.bin to mtdblock0

Restore uboot.
# blockdev --setrw /dev/mtdblock0
# dd if=/var/tmp/uboot.bin of=/dev/mtdblock0
# blockdev --setro /dev/mtdblock0


Reference:

0 意見:

張貼留言