diff options
author | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-06-11 15:54:31 -0700 |
---|---|---|
committer | Stephen Hemminger <shemminger@lenny.localdomain> | 2009-10-01 13:51:20 -0700 |
commit | ba4170471de90b2a32abeff6b48ec13461e7f9b1 (patch) | |
tree | fab0ad2360e09304401819295cf1318a9e5da36a | |
parent | c0f3b93ee22d5885a5fbe1027ccab2e95313884a (diff) | |
download | vyatta-cfg-qos-ba4170471de90b2a32abeff6b48ec13461e7f9b1.tar.gz vyatta-cfg-qos-ba4170471de90b2a32abeff6b48ec13461e7f9b1.zip |
IPV6 match fix
Bug 4548
The tc u32 filter command wants "ipv6" in protocol field but "ip6"
in the match field. Make up your mind Alexey!
(cherry picked from commit e7d228450c037ce16923dee385e127e7028d3358)
-rw-r--r-- | lib/Vyatta/Qos/Match.pm | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Vyatta/Qos/Match.pm b/lib/Vyatta/Qos/Match.pm index 8dda94d..dbcd3f1 100644 --- a/lib/Vyatta/Qos/Match.pm +++ b/lib/Vyatta/Qos/Match.pm @@ -88,6 +88,7 @@ sub filter { printf "filter add dev %s parent %x:", $dev, $parent; printf " prio %d", $prio if ($prio); + if ($proto ne 'ether') { print " protocol $proto u32"; print " match $proto dsfield $$p{dsfield} 0xff" if $$p{dsfield}; @@ -98,6 +99,10 @@ sub filter { print " protocol $type u32"; } + + # workaround inconsistent usage in tc u32 match + $proto = 'ip6' if ($proto eq 'ipv6'); + print " match $proto src $$p{src}" if $$p{src}; print " match $proto sport $$p{sport} 0xffff" if $$p{sport}; print " match $proto dst $$p{dst}" if $$p{dst}; |