1 #!/bin/bash 2 # vim: ft=sh 3 4 source lib/generic.sh 5 6 ts_qdisc_available "dsmark" 7 if [ $? -eq 0 ]; then 8 ts_log "dsmark: Unsupported by $TC, skipping" 9 exit 127 10 fi 11 12 ts_tc "dsmark" "dsmark root qdisc creation" \ 13 qdisc add dev $DEV root handle 10:0 \ 14 dsmark indices 64 default_index 1 set_tc_index 15 16 ts_tc "dsmark" "dsmark class 1 creation" \ 17 class change dev $DEV parent 10:0 classid 10:12 \ 18 dsmark mask 0xff value 2 19 20 ts_tc "dsmark" "dsmark class 2 creation" \ 21 class change dev $DEV parent 10:0 classid 10:13 \ 22 dsmark mask 0xfc value 4 23 24 ts_tc "dsmark" "dsmark dump qdisc" \ 25 qdisc list dev $DEV 26 27 ts_tc "dsmark" "dsmark dump class" \ 28 class list dev $DEV parent 10:0 29 30 ts_tc "dsmark" "generic qdisc tree deletion" \ 31 qdisc del dev $DEV root 32