Move the code to check if the current system is a system with vdsl
support to a dedicate function to make it reusable.
Signed-off-by: Mathias Kresin <dev@kresin.me>
ucidef_add_atm_bridge "$vpi" "$vci" "$encaps" "$payload"
fi
ucidef_add_atm_bridge "$vpi" "$vci" "$encaps" "$payload"
fi
-if grep -qE "system type.*: (VR9|xRX200)" /proc/cpuinfo; then
+if lantiq_is_vdsl_system; then
interface_wan="ptm0"
ucidef_add_vdsl_modem "$annex" "av" "ptm"
else
interface_wan="ptm0"
ucidef_add_vdsl_modem "$annex" "av" "ptm"
else
+
+lantiq_is_vdsl_system() {
+ grep -qE "system type.*: (VR9|xRX200)" /proc/cpuinfo
+}