1
0

lantiq 787 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #!/bin/sh
  2. #
  3. # Copyright (C) 2012 OpenWrt.org
  4. #
  5. [ -e /etc/config/ubootenv ] && exit 0
  6. touch /etc/config/ubootenv
  7. . /lib/functions/lantiq.sh
  8. . /lib/uboot-envtools.sh
  9. . /lib/functions.sh
  10. board=$(lantiq_board_name)
  11. case "$board" in
  12. GIGASX76X)
  13. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x10000" "0x10000" "1"
  14. ;;
  15. BTHOMEHUBV2B)
  16. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x10000" "0x10000" "1"
  17. ;;
  18. BTHOMEHUBV3A)
  19. ubootenv_add_uci_config "/dev/mtd2" "0x0" "0x4000" "0x4000" "1"
  20. ;;
  21. P2812HNUF1)
  22. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x2000" "0x20000" "1"
  23. ;;
  24. WBMR300)
  25. idx="$(find_mtd_index ubootconfig)"
  26. [ -n "$idx" ] && \
  27. ubootenv_add_uci_config "/dev/mtd$idx" "0x0" "0x2000" "0x1000" "2"
  28. ;;
  29. esac
  30. config_load ubootenv
  31. config_foreach ubootenv_add_app_config ubootenv
  32. exit 0