[SQM/luci-app-sqm] Wire up link layer dandling for cake

The cake traffic-shaper qdisc omne stop solution knows how to handle
link layer adjustments for ATM and can account for per packet overhead.
This commit adds cake as link layer adjustment mechanism in the GUI and
passes numerically specified overhead as well as the ATM linklayer
keywords on to cake. This change also passes the "advanced option strings"
from the Queue Discipline tab to cake. But as before no error checking.
This needs testing, as I have no working cake qdisc available so
caveat emptor...

Signed-off-by: Sebastian Moeller <moeller0@gmx.de>
This commit is contained in:
Sebastian Moeller
2015-06-18 21:08:01 +02:00
committed by Toke Høiland-Jørgensen
parent e7bab97599
commit 2ba6a3f9ab
6 changed files with 93 additions and 64 deletions

View File

@@ -139,6 +139,23 @@ get_stab_string() {
echo ${STABSTRING}
}
#sm: cake knows how to handle ATM and per packet overhead, so expose and use this...
get_cake_lla_string() {
STABSTRING=""
if [ "${LLAM}" = "cake" -a "${LINKLAYER}" != "none" ];
then
if [ "${LINKLAYER}" = "atm" ];
then
STABSTRING="atm"
fi
STABSTRING="${STABSTRING} overhead ${OVERHEAD}"
sqm_logger "cake link layer adjustments: ${STABSTRING}"
fi
echo ${STABSTRING}
}
sqm_stop() {
$TC qdisc del dev $IFACE ingress
$TC qdisc del dev $IFACE root