From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DC4C545B6A; Fri, 18 Oct 2024 18:49:50 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8EDC74027C; Fri, 18 Oct 2024 18:49:50 +0200 (CEST) Received: from mail-pf1-f170.google.com (mail-pf1-f170.google.com [209.85.210.170]) by mails.dpdk.org (Postfix) with ESMTP id AE9AF40268 for ; Fri, 18 Oct 2024 18:49:48 +0200 (CEST) Received: by mail-pf1-f170.google.com with SMTP id d2e1a72fcca58-71e585ef0b3so1899242b3a.1 for ; Fri, 18 Oct 2024 09:49:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1729270188; x=1729874988; darn=dpdk.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=aazVyQ/MPZfGE9+fROmWSX1a3jZ6bcFfLKaz133s+eo=; b=HIGJniZ1wJWyVQ8KZJzuTVgtJVvS30DgOV+P2ExQqG7+Oe2SPohsCKpGGpM+nlM/ZC LpVIArrOU+qumLupKkx600wUqZQfPlP6Cw5NPL+FK7at6gqlUboQur9QiGC6v2KySZV5 J6QhWkaMyac/2hDT1kJXqae2JoYpfdrn01c7J/kIkXt94j5wdxuecU9iFK/8idaMC8T6 QxnkdWfdfLwDq9D5CyNx47Fn26sD5gjbvMl9z/eH458KMt7XVQOv4MAQk4i1yYxaT/Lv 0soaEake+YI6velwt92GRbC28Kqbf51Ikr4X6DpVCp7S13O+NN4gy79IeB60iHkSie21 eNrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729270188; x=1729874988; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=aazVyQ/MPZfGE9+fROmWSX1a3jZ6bcFfLKaz133s+eo=; b=qgKKggQui8Tov9cHn41C+TKFBkEQj2gMecNq8OZsctLmteFCHm79kjgRhzBTkL3O/N HcFMktdnxfn+rg9eIEJot66fNHw8uyH3pHfZpP4NhoO7PD86hmYi4m3AT4wJsN4fI2un wf211b5fzyGTlQPGTdilME5Q3kjg2GqmZKzNc80rMVr2wI/5np24edE/QpJujaIr1yMy krGk8VZnlZNrMQUY1kAXDf+Sp5/4eAyVRjYMHiAiOZzNs2bOU7DrRvAPLjHcNZ6Rj4nS lVQVblp8mrlbTJJBpHWogcrg5LH+EyZGtaR5CbGw/EBsJpvAM38GM3KBgZgdG784lrdJ lDJQ== X-Gm-Message-State: AOJu0Yyl5mMgaSUjNd+9cSQzuPrUgmGCOO6juShv3HudhsfEjf2wcQO8 fGhTqDVUUtWxl/U4aAlRaKNadi+O5VTg2/4JAi1VY6rYafPadyDYpPtWL+TcOo090mc6mn4FaAP WA0EQj0Ydegrn6V4bUQ0BsEYEAIsbvQ== X-Google-Smtp-Source: AGHT+IFfKS/zZBU4VHAICP0GGyPRJJtk/Cxgki9HoKKQ4zF+v1FuBATPttFV+7BL70xXlnR8aQtP9eVTCuzhA/jWeGM= X-Received: by 2002:a05:6a00:4b16:b0:71e:6fcb:7688 with SMTP id d2e1a72fcca58-71ea32fe8f6mr3890824b3a.25.1729270187649; Fri, 18 Oct 2024 09:49:47 -0700 (PDT) MIME-Version: 1.0 References: <20241018094348.4e91b6e5@hermes.local> In-Reply-To: <20241018094348.4e91b6e5@hermes.local> From: Rajasekhar Pulluru Date: Fri, 18 Oct 2024 22:19:35 +0530 Message-ID: Subject: Re: Restrict max packet size on rx To: Stephen Hemminger Cc: dev@dpdk.org Content-Type: multipart/alternative; boundary="0000000000004172f40624c317d8" X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org --0000000000004172f40624c317d8 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks Stephen. On Fri, Oct 18, 2024 at 10:13=E2=80=AFPM Stephen Hemminger < stephen@networkplumber.org> wrote: > On Fri, 18 Oct 2024 22:05:24 +0530 > Rajasekhar Pulluru wrote: > > > Team, > > Does setting mtu using rte_eth_dev_set_mtu limit the maximum size of th= e > > packet received on the dpdk port to the configured mtu size? > > > > On an intel machine with ixgbe port, with mtu set to 1500, no rx-offloa= ds > > enabled, ixgbe dpdk port is able to receive packets greater than 1500 > size > > and even jumbo frames of size 9000, even though the peer is sending the= m > > fragmented with mtu of 1500. > > > > How do I restrict the port not to receive any frame greater than mtu > size? > > > > Appreciate any help, > > Thanks. > > Rajasekhar > > > In networking, MTU and MRU are overlapping concepts. > The MTU value is used as a hint to the driver as to what size buffer to > allocate > but it can use larger if it wants. If you have restrictions, then the > application > needs to enforce them. > --0000000000004172f40624c317d8 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks Stephen.

On Fri, Oct 18, 2024 at 10:13=E2=80=AFPM St= ephen Hemminger <stephen@n= etworkplumber.org> wrote:
On Fri, 18 Oct 2024 22:05:24 +0530
Rajasekhar Pulluru <pullururajasekhar@gmail.com> wrote:

> Team,
> Does setting mtu using rte_eth_dev_set_mtu limit the maximum size of t= he
> packet received on the dpdk port to the configured mtu size?
>
> On an intel machine with ixgbe port, with mtu set to 1500, no rx-offlo= ads
> enabled, ixgbe dpdk port is able to receive packets greater than 1500 = size
> and even jumbo frames of size 9000, even though the peer is sending th= em
> fragmented with mtu of 1500.
>
> How do I restrict the port not to receive any frame greater than mtu s= ize?
>
> Appreciate any help,
> Thanks.
> Rajasekhar


In networking, MTU and MRU are overlapping concepts.
The MTU value is used as a hint to the driver as to what size buffer to all= ocate
but it can use larger if it wants. If you have restrictions, then the appli= cation
needs to enforce them.
--0000000000004172f40624c317d8--