gaurav
Committed by Gerrit Code Review

support mcast based filtering objective CORD-673,review comments addressed for patch-3

Change-Id: Id18e51826fe2355b1a7fcdba46af94b8577dac60
......@@ -250,7 +250,8 @@ public class SoftRouterPipeline extends AbstractHandlerBehaviour implements Pipe
// convert filtering conditions for switch-intfs into flowrules
FlowRuleOperations.Builder ops = FlowRuleOperations.builder();
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;
} else if (c.type() == Criterion.Type.VLAN_VID) {
v = (VlanIdCriterion) c;
......@@ -267,7 +268,12 @@ public class SoftRouterPipeline extends AbstractHandlerBehaviour implements Pipe
TrafficTreatment.Builder treatment = DefaultTrafficTreatment.builder();
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.matchEthType(Ethernet.TYPE_IPV4);
if (!v.vlanId().equals(VlanId.NONE)) {
......