mirror of
https://github.com/opennetworkinglab/onos.git
synced 2025-10-16 09:51:38 +02:00
support mcast based filtering objective CORD-673,review comments addressed for patch-3
Change-Id: Id18e51826fe2355b1a7fcdba46af94b8577dac60
This commit is contained in:
parent
80244e5424
commit
adc9004725
@ -250,7 +250,8 @@ public class SoftRouterPipeline extends AbstractHandlerBehaviour implements Pipe
|
|||||||
// convert filtering conditions for switch-intfs into flowrules
|
// convert filtering conditions for switch-intfs into flowrules
|
||||||
FlowRuleOperations.Builder ops = FlowRuleOperations.builder();
|
FlowRuleOperations.Builder ops = FlowRuleOperations.builder();
|
||||||
for (Criterion c : filt.conditions()) {
|
for (Criterion c : filt.conditions()) {
|
||||||
if (c.type() == Criterion.Type.ETH_DST) {
|
if (c.type() == Criterion.Type.ETH_DST ||
|
||||||
|
c.type() == Criterion.Type.ETH_DST_MASKED) {
|
||||||
e = (EthCriterion) c;
|
e = (EthCriterion) c;
|
||||||
} else if (c.type() == Criterion.Type.VLAN_VID) {
|
} else if (c.type() == Criterion.Type.VLAN_VID) {
|
||||||
v = (VlanIdCriterion) c;
|
v = (VlanIdCriterion) c;
|
||||||
@ -267,7 +268,12 @@ public class SoftRouterPipeline extends AbstractHandlerBehaviour implements Pipe
|
|||||||
TrafficTreatment.Builder treatment = DefaultTrafficTreatment.builder();
|
TrafficTreatment.Builder treatment = DefaultTrafficTreatment.builder();
|
||||||
selector.matchInPort(p.port());
|
selector.matchInPort(p.port());
|
||||||
|
|
||||||
selector.matchEthDst(e.mac());
|
//Multicast MAC
|
||||||
|
if (e.mask() != null) {
|
||||||
|
selector.matchEthDstMasked(e.mac(), e.mask());
|
||||||
|
} else {
|
||||||
|
selector.matchEthDst(e.mac());
|
||||||
|
}
|
||||||
selector.matchVlanId(v.vlanId());
|
selector.matchVlanId(v.vlanId());
|
||||||
selector.matchEthType(Ethernet.TYPE_IPV4);
|
selector.matchEthType(Ethernet.TYPE_IPV4);
|
||||||
if (!v.vlanId().equals(VlanId.NONE)) {
|
if (!v.vlanId().equals(VlanId.NONE)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user