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 57DF5A034F; Fri, 26 Feb 2021 16:25:38 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7042D22A277; Fri, 26 Feb 2021 16:25:37 +0100 (CET) Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id E6F6140692 for ; Fri, 26 Feb 2021 16:25:35 +0100 (CET) IronPort-SDR: r/oOeM8pmd0w0c8JmqbDbYcmfMa3Sxy9OMpu/PIp0xfimF3t7kUS7s5fmyXSig12Pz3KV7BqF+ LuyBO3FaAPIw== X-IronPort-AV: E=McAfee;i="6000,8403,9907"; a="247322639" X-IronPort-AV: E=Sophos;i="5.81,208,1610438400"; d="scan'208";a="247322639" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Feb 2021 07:25:34 -0800 IronPort-SDR: xK0qahabq+f+W3YstNTeuuhsGk0rasyqmkanCEUUgb18/S/MpK4yIAtpL4EaNlt9RhjpccIh8g tDZfN+WJh+QA== X-IronPort-AV: E=Sophos;i="5.81,208,1610438400"; d="scan'208";a="404941731" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.252.17.170]) ([10.252.17.170]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Feb 2021 07:25:33 -0800 To: Lijun Ou Cc: dev@dpdk.org, linuxarm@openeuler.org References: <1614130139-42926-1-git-send-email-oulijun@huawei.com> <1614130139-42926-10-git-send-email-oulijun@huawei.com> From: Ferruh Yigit X-User: ferruhy Message-ID: Date: Fri, 26 Feb 2021 15:25:32 +0000 MIME-Version: 1.0 In-Reply-To: <1614130139-42926-10-git-send-email-oulijun@huawei.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [PATCH 09/13] net/hns3: fix maximum frame size update after buffer alloc 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 Sender: "dev" On 2/24/2021 1:28 AM, Lijun Ou wrote: > From: Chengchang Tang > > After MTU changed, the buffer used to store packets in HW should be > reallocated. And buffer size is allocated based on the maximum frame > size in the PF struct. However, the value of maximum frame size is > not updated in time when MTU is changed. This would lead to a packet > loss for not enough buffer. > > This patch update the maximum frame size before reallocating the HW > buffer. And a rollback operation is added to avoid the side effects > of buffer reallocation failures. > > Fixes: 1f5ca0b460cd ("net/hns3: support some device operations") > Fixes: d51867db65c1 ("net/hns3: add initialization") > Cc: stable@dpdk.org > > Signed-off-by: Chengchang Tang > Signed-off-by: Lijun Ou Isn't the patch title should say 'before', like: net/hns3: fix maximum frame size update _before_ buffer alloc Or perhaps I get the patch wrong...