diff options
author | Felix Fietkau <nbd@openwrt.org> | 2016-03-07 11:03:38 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2016-03-07 11:03:38 +0000 |
commit | a51ab25d61f410eabaee92ac3b48f55aae1c8dbb (patch) | |
tree | a92962e004244d9b03eabb4bfa6a60c83fae410c | |
parent | 1c8bb564287542a7f0a2e86072dc4875bc1f954b (diff) | |
download | master-187ad058-a51ab25d61f410eabaee92ac3b48f55aae1c8dbb.tar.gz master-187ad058-a51ab25d61f410eabaee92ac3b48f55aae1c8dbb.tar.bz2 master-187ad058-a51ab25d61f410eabaee92ac3b48f55aae1c8dbb.zip |
ltq-vdsl-app: make it possible to configure ADSL/VDSL independently
There are some cases where ISPs are running ATM over VDSL or PTM over
ADSL, this is not the common case, but these cases exist. Make it
possible to configure OpenWrt for such cases by adding a new config
option line_mode.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@48947 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r-- | package/network/config/ltq-vdsl-app/files/dsl_control | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/package/network/config/ltq-vdsl-app/files/dsl_control b/package/network/config/ltq-vdsl-app/files/dsl_control index 48c0cbeac2..6d254da1e5 100644 --- a/package/network/config/ltq-vdsl-app/files/dsl_control +++ b/package/network/config/ltq-vdsl-app/files/dsl_control @@ -162,6 +162,8 @@ start_service() { local tone_adsl local tone_vdsl local xtse + local xfer_mode + local line_mode local mode local lowlevel @@ -170,6 +172,7 @@ start_service() { config_get annex dsl annex config_get firmware dsl firmware config_get xfer_mode dsl xfer_mode + config_get line_mode dsl line_mode eval "xtse=\"\${xtse_xdsl_$annex}\"" @@ -179,14 +182,27 @@ start_service() { atm) LOAD=ltq_atm_vr9 UNLOAD=ltq_ptm_vr9 + + # in most cases atm is used on top of adsl + [ -z "${line_mode}" ] && line_mode=adsl + ;; + *) + LOAD=ltq_ptm_vr9 + UNLOAD=ltq_atm_vr9 + + # in most cases ptm is used on top of vdsl + [ -z "${line_mode}" ] && line_mode=vdsl + ;; + esac + + case "${line_mode}" in + adsl) mode=1 # mask out VDSL bits when ATM is requested xtse="${xtse%_*}_00" ;; *) - LOAD=ltq_ptm_vr9 - UNLOAD=ltq_atm_vr9 mode=2 ;; esac |