2
0

09_fix-seama-header 364 B

1234567891011121314151617181920212223
  1. #!/bin/sh
  2. #
  3. # Copyright (C) 2012 OpenWrt.org
  4. #
  5. . /lib/ramips.sh
  6. fix_seama_header() {
  7. local kernel_size=$(sed -n 's/mtd[0-9]*: \([0-9a-f]*\).*"kernel".*/\1/p' /proc/mtd)
  8. [ "$kernel_size" ] && mtd -c 0x$kernel_size fixseama firmware
  9. }
  10. board=$(ramips_board_name)
  11. case "$board" in
  12. cy-swr1100 | \
  13. dch-m225 | \
  14. dir-645 | \
  15. dir-860l-b1)
  16. fix_seama_header
  17. ;;
  18. esac