kobs-ng: update dependencies after 'imx6' -> 'imx' rename
[openwrt/staging/chunkeey.git] / package / boot / uboot-envtools / files / imx6
1 #
2 # Copyright (C) 2013-2014 OpenWrt.org
3 #
4
5 [ -e /etc/config/ubootenv ] && exit 0
6
7 touch /etc/config/ubootenv
8
9 . /lib/imx6.sh
10 . /lib/uboot-envtools.sh
11 . /lib/functions.sh
12
13 board=$(board_name)
14
15 case "$board" in
16 gw,imx6dl-gw51xx|\
17 gw,imx6dl-gw52xx|\
18 gw,imx6dl-gw53xx|\
19 gw,imx6dl-gw54xx|\
20 gw,imx6dl-gw551x|\
21 gw,imx6dl-gw552x|\
22 gw,imx6dl-gw553x|\
23 gw,imx6dl-gw5904|\
24 gw,imx6dl-gw5907|\
25 gw,imx6dl-gw5910|\
26 gw,imx6dl-gw5912|\
27 gw,imx6dl-gw5913|\
28 gw,imx6q-gw51xx|\
29 gw,imx6q-gw52xx|\
30 gw,imx6q-gw53xx|\
31 gw,imx6q-gw5400-a|\
32 gw,imx6q-gw54xx|\
33 gw,imx6q-gw551x|\
34 gw,imx6q-gw552x|\
35 gw,imx6q-gw553x|\
36 gw,imx6q-gw5904|\
37 gw,imx6q-gw5907|\
38 gw,imx6q-gw5910|\
39 gw,imx6q-gw5912|\
40 gw,imx6q-gw5913)
41 if [ -c /dev/mtd1 ]; then
42 # board boots from NAND
43 ubootenv_add_uci_config /dev/mtd1 0x0 0x20000 0x40000
44 ubootenv_add_uci_config /dev/mtd1 0x80000 0x20000 0x40000
45 else
46 # board boots from microSD
47 ubootenv_add_uci_config /dev/mmcblk0 0xb1400 0x20000
48 ubootenv_add_uci_config /dev/mmcblk0 0xd1400 0x20000
49 fi
50 ;;
51 toradex,apalis_imx6q-eval|\
52 toradex,apalis_imx6q-ixora|\
53 toradex,apalis_imx6q-ixora-v1.1)
54 ubootenv_add_uci_config $(bootdev_from_uuid)boot0 -0x2200 0x2000 0x200 10
55 ;;
56 wand,imx6dl-wandboard)
57 ubootenv_add_uci_config "/dev/mmcblk0" "0x60000" "0x2000" "0x2000"
58 ;;
59 esac
60
61 config_load ubootenv
62 config_foreach ubootenv_add_app_config ubootenv
63
64 exit 0