| #!/bin/sh |
| |
| set -x |
| |
| cd / |
| export CLISH_PATH=/etc/xml_commands |
| |
| # We now only support gpon, but the previous pon types were as follows: |
| # epon=0, gpon=1, p2p=2, none=3 |
| |
| # sycl starts omci binary which uses fw_printenv, and |
| # fw_printenv needs a valid fw_env.config. |
| # Setup the fw_config file. |
| mtd=$(grep env /proc/mtd) |
| if [ -z "$mtd" ]; then |
| echo "Error: no uboot environment mapping." |
| else |
| device=$(echo $mtd | cut -f 1 -d ':') |
| erase_size=$(echo $mtd | cut -f 3 -d ' ') |
| echo "/dev/$device 0x00000 0x1000 0x$erase_size" >/tmp/fw_env.config |
| fi |
| |
| sycl & |