From 0e4e5a8222089d6e8f70ad74afcfd4e2854a00da Mon Sep 17 00:00:00 2001 From: Benoît Ganne Date: Wed, 19 Jan 2022 18:26:43 +0100 Subject: dpdk: fix compilation for DPDK < 21.11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Type: fix Change-Id: Ic5b74fb7a8e479e8cdccbb6a564ff3fdd299455c Signed-off-by: Benoît Ganne --- src/plugins/dpdk/device/common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/plugins/dpdk/device/common.c') diff --git a/src/plugins/dpdk/device/common.c b/src/plugins/dpdk/device/common.c index 0f54a616773..df80a85872d 100644 --- a/src/plugins/dpdk/device/common.c +++ b/src/plugins/dpdk/device/common.c @@ -169,8 +169,8 @@ dpdk_device_setup (dpdk_device_t * xd) } else { - mtu = 1500; - xd->max_supported_frame_size = mtu + xd->driver_frame_overhead; + xd->max_supported_frame_size = + clib_min (1500 + xd->driver_frame_overhead, buf_sz); } #else if (xd->conf.disable_multi_seg) -- cgit 1.2.3-korg