ar71xx 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. #!/bin/sh
  2. #
  3. # Copyright (C) 2011-2014 OpenWrt.org
  4. #
  5. [ -e /etc/config/ubootenv ] && exit 0
  6. touch /etc/config/ubootenv
  7. . /lib/uboot-envtools.sh
  8. . /lib/functions.sh
  9. board=$(board_name)
  10. case "$board" in
  11. a40|\
  12. a60|\
  13. alfa-ap120c|\
  14. all0258n|\
  15. ap121f|\
  16. ap90q|\
  17. ap91-5g|\
  18. arduino-yun|\
  19. cap324|\
  20. cap4200ag|\
  21. carambola2|\
  22. cpe830|\
  23. cpe870|\
  24. cr3000|\
  25. cr5000|\
  26. e1700ac-v2|\
  27. e600g-v2|\
  28. e600gac-v2|\
  29. eap300v2|\
  30. ens202ext|\
  31. gl-ar300m|\
  32. gl-ar750|\
  33. hornet-ub|\
  34. hornet-ub-x2|\
  35. jwap230|\
  36. koala|\
  37. mr1750|\
  38. mr1750v2|\
  39. mr600|\
  40. mr600v2|\
  41. mr900|\
  42. mr900v2|\
  43. n5q|\
  44. nbg6716|\
  45. om5p|\
  46. om5p-ac|\
  47. om5p-acv2|\
  48. om5p-an|\
  49. r36a|\
  50. rme-eg200|\
  51. sr3200|\
  52. t830|\
  53. tube2h|\
  54. wam250|\
  55. wndr3700|\
  56. xd3200)
  57. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x10000" "0x10000"
  58. ;;
  59. alfa-ap96|\
  60. all0315n|\
  61. om2p|\
  62. om2p-hs|\
  63. om2p-hsv2|\
  64. om2p-hsv3|\
  65. om2p-hsv4|\
  66. om2p-lc|\
  67. om2pv2|\
  68. om2pv4)
  69. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x40000" "0x40000"
  70. ;;
  71. dap-2695-a1|\
  72. wzr-hp-ag300h)
  73. ubootenv_add_uci_config "/dev/mtd3" "0x0" "0x10000" "0x10000"
  74. ;;
  75. dr342|\
  76. dr531)
  77. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0xf800" "0x10000"
  78. ;;
  79. rambutan)
  80. ubootenv_add_uci_config "/dev/mtd1" "0x0" "0x20000" "0x20000"
  81. ubootenv_add_uci_config "/dev/mtd1" "0x100000" "0x20000" "0x20000"
  82. ;;
  83. qihoo-c301)
  84. ubootenv_add_uci_config "/dev/mtd9" "0x0" "0x10000" "0x10000"
  85. ;;
  86. wi2a-ac200i)
  87. ubootenv_add_uci_config "/dev/mtd4" "0x0" "0x8000" "0x10000"
  88. ;;
  89. esac
  90. config_load ubootenv
  91. config_foreach ubootenv_add_app_config ubootenv
  92. exit 0