From 076ed09e9eaeeb751ce87bac67ae0becc7b2417b Mon Sep 17 00:00:00 2001 From: Marek Gradzki Date: Mon, 11 Jun 2018 16:45:47 +0200 Subject: HC2VPP-354: use hw_interface_set_mtu for Ethernet interfaces The API was renamed by https://gerrit.fd.io/r/#/c/12930/ The VPP change spearates setting of hardware interface and software interface MTU. More details: https://git.fd.io/vpp/tree/src/vnet/MTU.md HC supports only hardware interface MTU configuration for Ethernet interfaces. MTU for software interfaces (per protocol MTU) is not supported (HC2VPP-355). Change-Id: I7eb1cb035a7b0f428a7bc7a9bb1c73819b52f0fa Signed-off-by: Marek Gradzki --- v3po/api/src/main/yang/v3po@2017-06-07.yang | 4 +++- .../io/fd/hc2vpp/v3po/interfaces/EthernetCustomizer.java | 12 +++++++++--- .../hc2vpp/v3po/interfacesstate/EthernetCustomizer.java | 5 +++++ .../hc2vpp/v3po/interfaces/EthernetCustomizerTest.java | 16 ++++++++-------- 4 files changed, 25 insertions(+), 12 deletions(-) (limited to 'v3po') diff --git a/v3po/api/src/main/yang/v3po@2017-06-07.yang b/v3po/api/src/main/yang/v3po@2017-06-07.yang index 50b823385..6a1eb3809 100644 --- a/v3po/api/src/main/yang/v3po@2017-06-07.yang +++ b/v3po/api/src/main/yang/v3po@2017-06-07.yang @@ -337,7 +337,9 @@ module v3po { default 9216; description "The size, in octets, of the largest packet that the - hardware interface will send and receive."; + hardware interface will send and receive. + + Mapped to hw_interface_set_mtu VPP API message which programs the NIC."; } } diff --git a/v3po/v3po2vpp/src/main/java/io/fd/hc2vpp/v3po/interfaces/EthernetCustomizer.java b/v3po/v3po2vpp/src/main/java/io/fd/hc2vpp/v3po/interfaces/EthernetCustomizer.java index 6945f45e7..dfac5b99d 100644 --- a/v3po/v3po2vpp/src/main/java/io/fd/hc2vpp/v3po/interfaces/EthernetCustomizer.java +++ b/v3po/v3po2vpp/src/main/java/io/fd/hc2vpp/v3po/interfaces/EthernetCustomizer.java @@ -21,7 +21,7 @@ import io.fd.hc2vpp.common.translate.util.JvppReplyConsumer; import io.fd.hc2vpp.common.translate.util.NamingContext; import io.fd.honeycomb.translate.write.WriteContext; import io.fd.honeycomb.translate.write.WriteFailedException; -import io.fd.vpp.jvpp.core.dto.SwInterfaceSetMtu; +import io.fd.vpp.jvpp.core.dto.HwInterfaceSetMtu; import io.fd.vpp.jvpp.core.future.FutureJVppCore; import javax.annotation.Nonnull; import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.iana._if.type.rev140508.EthernetCsmacd; @@ -75,10 +75,16 @@ public class EthernetCustomizer extends AbstractInterfaceTypeCustomizer