Skip to content

Commit

Permalink
Minor visual refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
hkbakke committed Feb 2, 2018
1 parent 8ed4fba commit 100b441
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions src/tc-gen
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,8 @@ add_prio_classes () {
$(get_fq_codel_quantum ${CEIL_RATE}) \
$(get_ecn ${CEIL_RATE} ${ECN_MINRATE})

${TC} filter add dev ${IF_NAME} parent 1: protocol all \
handle ${FWMARK} fw classid 1:${CLASS_ID}
${TC} filter add dev ${IF_NAME} parent 1: protocol all handle ${FWMARK} \
fw classid 1:${CLASS_ID}
done
fi

Expand Down Expand Up @@ -362,7 +362,8 @@ apply_ingress_shaping () {

# Redirect all ingress traffic to IFB egress. Use prio 99 to make it
# possible to insert filters earlier in the chain.
${TC} filter add dev ${IF_NAME} parent ffff: protocol all prio 99 u32 \
${TC} filter add dev ${IF_NAME} parent ffff: protocol all prio 99 \
u32 \
match u32 0 0 \
action mirred egress redirect dev ${IFB_IF_NAME}
}
Expand All @@ -386,11 +387,11 @@ apply_ingress_policing () {

# Police all ingress traffic. Use prio 99 to make it possible to insert
# filters earlier in the chain.
${TC} filter add dev ${IF_NAME} parent ffff: protocol all prio 99 u32 \
${TC} filter add dev ${IF_NAME} parent ffff: protocol all prio 99 \
u32 \
match u32 0 0 \
police rate ${DOWN_RATE}kbit \
burst ${BURST_SIZE} \
mtu ${MTU} drop flowid :1
police rate ${DOWN_RATE}kbit burst ${BURST_SIZE} mtu ${MTU} drop \
flowid :1
}

convert_rate () {
Expand Down

0 comments on commit 100b441

Please sign in to comment.