BitOhenry
Committed by Gerrit Code Review

[ONOS-3373] Add arp_tha operation to provider of openflow

Change-Id: I04449a15d8e34fea4faba3729b9b6998ec9b0a5c
......@@ -707,10 +707,13 @@ public class FlowEntryBuilder {
long tunnelId = match.get(MatchField.TUNNEL_ID).getValue();
builder.matchTunnelId(tunnelId);
break;
case ARP_THA:
mac = MacAddress.valueOf(match.get(MatchField.ARP_THA).getLong());
builder.matchArpTha(mac);
break;
case ARP_OP:
case ARP_SHA:
case ARP_SPA:
case ARP_THA:
case ARP_TPA:
case MPLS_TC:
default:
......
......@@ -24,6 +24,7 @@ import org.onosproject.net.OchSignal;
import org.onosproject.net.driver.DriverService;
import org.onosproject.net.flow.FlowRule;
import org.onosproject.net.flow.TrafficSelector;
import org.onosproject.net.flow.criteria.ArpHaCriterion;
import org.onosproject.net.flow.criteria.Criterion;
import org.onosproject.net.flow.criteria.EthCriterion;
import org.onosproject.net.flow.criteria.EthTypeCriterion;
......@@ -178,6 +179,7 @@ public abstract class FlowModBuilder {
UdpPortCriterion udpPortCriterion;
SctpPortCriterion sctpPortCriterion;
IPv6NDLinkLayerAddressCriterion llAddressCriterion;
ArpHaCriterion arpHaCriterion;
for (Criterion c : selector.criteria()) {
switch (c.type()) {
......@@ -415,10 +417,14 @@ public abstract class FlowModBuilder {
mplsBos.mplsBos() ? OFBooleanValue.TRUE
: OFBooleanValue.FALSE);
break;
case ARP_THA:
arpHaCriterion = (ArpHaCriterion) c;
mBuilder.setExact(MatchField.ARP_THA,
MacAddress.of(arpHaCriterion.mac().toLong()));
break;
case ARP_OP:
case ARP_SHA:
case ARP_SPA:
case ARP_THA:
case ARP_TPA:
case MPLS_TC:
case PBB_ISID:
......