12345678910111213141516171819202122232425262728293031323334 |
- #!/bin/sh
- umount /var/tmp/mnt 2> /dev/null
- rm -rf /var/tmp/mnt 2> /dev/null
- from=/var/tmp/mnt/Display002_7_rs485_bitbang.dtb
- to=/var/tmp/mnt/Display001.dtb
- such="root=/dev/mmcblk1"
- grep -q $such /proc/cmdline
- if [ $? == 0 ]
- then
- bootpart="/dev/mmcblk1p1"
- else
- bootpart="/dev/mmcblk0p1"
- fi
- echo "Bootpart == $bootpart"
-
- mkdir /var/tmp/mnt
- mount $bootpart /var/tmp/mnt
- if [ -e $from ]
- then
- echo "copy $from --> $to"
- cp $from $to
- sync
- echo "pls. reboot !!"
- else
- echo " no such file $from"
- fi
- umount /var/tmp/mnt 2> /dev/null
- rm -rf /var/tmp/mnt 2> /dev/null
|