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 8912741BAE for ; Thu, 2 Feb 2023 13:56:05 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8121342FB6; Thu, 2 Feb 2023 13:56:05 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 5B02F4014F for ; Thu, 2 Feb 2023 13:56:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1675342563; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=n1pe55U3qVWS2J9Cn3qwfgXigCe/3J4Kjvdr6SJOVts=; b=Muke3eJkOWmhsmcrQram/p3CSKtrcBUJo/Z2JF3pPOKPFj7G6yjGk4VL3b07rrBMKJCBuG cxbqDCnIMdUulJkL4tEm/PFSWL78R+IXQh4nJtRPQ9szMRgurRdfWv+Efo0W3au/CJSO52 TYyAZ9XlcVeikacsbvTYB42F4DHxpeA= Received: from mail-pj1-f69.google.com (mail-pj1-f69.google.com [209.85.216.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-561-gZHGfcgaPSGXzEFhfVqPxA-1; Thu, 02 Feb 2023 07:55:55 -0500 X-MC-Unique: gZHGfcgaPSGXzEFhfVqPxA-1 Received: by mail-pj1-f69.google.com with SMTP id nb8-20020a17090b35c800b0022bb3fd0718so941014pjb.4 for ; Thu, 02 Feb 2023 04:55:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=n1pe55U3qVWS2J9Cn3qwfgXigCe/3J4Kjvdr6SJOVts=; b=dW+uUpB3QiJklo+s1wJFhXgGSEuNVby3SN6vqYR6ISuiKP7qtceI1AfKV2cf5iC/eT amIHHqix8BYjD5m6TLGyxybmxFjQCSEDw8ysb5XIzYccz1Y6ipaFGg8v/5j2YxP+opex 6aAGA4mmbx8nfdK8A6hC+2Y653P8z5nk4T2VeKN9S7DBFB8YABMwfyF7Sn1WHKz76lYn syjeyPcYCF2i2OTbRCvYltvyo4OBZmgew7fgKthqnqS5AjkAJvKc1sY623ksR4B9jTV1 ajzTJrzxeJRy/t/6Y4AtmUkvSytjJ7BJaeoprsYEgWN1uVBVyH/oNOQEO6t4Owj3h6Qh AzjQ== X-Gm-Message-State: AO0yUKVEY4OLQyp2vvERjI24uW32pTW5d+cnE3cKHrh3b2yjWmNjiqGf SuDLFO8/YIv6xQcsJMw+2W9392alxWnW+EmSlustUoYb5trs2Ye3vwBeU3xH7dPEMPBuROPMCxE BelcfXlN3VhqqWmSgYLCYIEU= X-Received: by 2002:a05:6a00:1ca0:b0:592:6299:43d2 with SMTP id y32-20020a056a001ca000b00592629943d2mr1318063pfw.1.1675342553976; Thu, 02 Feb 2023 04:55:53 -0800 (PST) X-Google-Smtp-Source: AK7set+WBp46N69gkiHoBw9jDsda2ZAXygj6mN1PZltzGq0qNID4EOjdpAZx3PxJhXFqp/7APfUiSu8Zd3KwJHewTUU= X-Received: by 2002:a05:6a00:1ca0:b0:592:6299:43d2 with SMTP id y32-20020a056a001ca000b00592629943d2mr1318053pfw.1.1675342553710; Thu, 02 Feb 2023 04:55:53 -0800 (PST) MIME-Version: 1.0 References: <20230202123021.54416-1-simei.su@intel.com> <20230202123632.56730-1-simei.su@intel.com> In-Reply-To: <20230202123632.56730-1-simei.su@intel.com> From: David Marchand Date: Thu, 2 Feb 2023 13:55:42 +0100 Message-ID: Subject: Re: [PATCH v5] net/i40e: rework maximum frame size configuration To: Simei Su , qi.z.zhang@intel.com Cc: beilei.xing@intel.com, yuying.zhang@intel.com, dev@dpdk.org, qiming.yang@intel.com, stable@dpdk.org X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org On Thu, Feb 2, 2023 at 1:37 PM Simei Su wrote: > > This patch reverts mentioned changes below to remove unnecessary link > status check and only moves max frame size configuration to dev_start. > Also, it sets the parameter "wait to complete" true to wait for complete > right after setting link up. Why is the change on link status needed? Is it necessary? > > Fixes: a4ba77367923 ("net/i40e: enable maximum frame size at port level") > Fixes: 2184f7cdeeaa ("net/i40e: fix max frame size config at port level") > Fixes: 719469f13b11 ("net/i40e: fix jumbo frame Rx with X722") > Cc: stable@dpdk.org > > Signed-off-by: Simei Su I would have preferred you reply to my original report. At least, I'd like you add some credit with my name in the commitlog. For the record, the differences with my v1 are: diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c index 5635dd03cf..5d57bb9a0e 100644 --- a/drivers/net/i40e/i40e_ethdev.c +++ b/drivers/net/i40e/i40e_ethdev.c @@ -2327,6 +2327,7 @@ i40e_dev_start(struct rte_eth_dev *dev) uint32_t intr_vector = 0; struct i40e_vsi *vsi; uint16_t nb_rxq, nb_txq; + uint16_t max_frame_size; hw->adapter_stopped = 0; @@ -2447,7 +2448,7 @@ i40e_dev_start(struct rte_eth_dev *dev) PMD_DRV_LOG(WARNING, "Fail to set phy mask"); /* Call get_link_info aq command to enable/disable LSE */ - i40e_dev_link_update(dev, 0); + i40e_dev_link_update(dev, 1); } if (dev->data->dev_conf.intr_conf.rxq == 0) { @@ -2465,8 +2466,16 @@ i40e_dev_start(struct rte_eth_dev *dev) "please call hierarchy_commit() " "before starting the port"); - i40e_aq_set_mac_config(hw, dev->data->mtu + I40E_ETH_OVERHEAD, TRUE, - false, 0, NULL); + max_frame_size = dev->data->mtu ? + dev->data->mtu + I40E_ETH_OVERHEAD : + I40E_FRAME_SIZE_MAX; + + /* Set the max frame size to HW*/ + ret = i40e_aq_set_mac_config(hw, max_frame_size, TRUE, false, 0, NULL); + if (ret) { + PMD_DRV_LOG(ERR, "Fail to set mac config"); + return ret; + } return I40E_SUCCESS; Qi, don't apply this fix yet. I'll generate some binaries internally to have Red Hat QE run their tests. Thanks. -- David Marchand