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 E4804A0093 for ; Wed, 9 Mar 2022 17:31:19 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D20AA410E6; Wed, 9 Mar 2022 17:31:19 +0100 (CET) Received: from mail-wr1-f52.google.com (mail-wr1-f52.google.com [209.85.221.52]) by mails.dpdk.org (Postfix) with ESMTP id 2039540687 for ; Wed, 9 Mar 2022 17:31:18 +0100 (CET) Received: by mail-wr1-f52.google.com with SMTP id r10so3937510wrp.3 for ; Wed, 09 Mar 2022 08:31:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=GcYA3f5mLPVVTWRvFuO7gq8qF567dNtAZTKGLJ2wsdE=; b=klCF9kjJ5s/oKOrT8J0WV+ofo55uwoF+6gNmtOYS+zob75/4U5EuEcXDQB89kTOpEP ASc/uAqjoR4F0SrsNyEiK2e4T+NVmaZ+Lqgc0x1J3EfhICM0R9AogPp/nmJ2GQDTksCo zun72mEYHEyUT2OhYXv1tgxeIRbE2aUMB1RoMe6cw0X5aJJAzgB/JeEQYG/uaP2jYqEu kl1GbB5CAWG9LNENbk8+Dl2MPUNYpqpHc9MRa2V2HTWqIh6b1JtQqUei2x7pGghueta8 GXDdDu2Jyp1jgVCQJkAqHysDe0SYp85VyNAyDgXHO/IxhiVBQ5nVGKliOsUY8rcVGMBE Xxhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=GcYA3f5mLPVVTWRvFuO7gq8qF567dNtAZTKGLJ2wsdE=; b=WQnyTNqsWeH7EBrjhLAJowv5rs/FW5STQy49A20uPZKCg8Z1HjGnw08tjzS/vXkJUT xL5ruGX+Mm4AHBSp2mp4XP1vCSZ1h+kYtvauOcjqyhob8oRyuQSoKwszQvQXonhS+4MK 6ZM1rT5Ua9DDrlCksfru3M9aG57HfFMD4sobP7m+tgo6unWt68NVIA49hcIhfa4hC5W+ GmnwWeKSK96NC9HNTMpYIB8TThY65e0UhSce8BtGxvMDOgKvgXFb4zp/r3M0mJKmRT1C 6dPtXoFFmAqwG8RuEqFFCMg0QzsXR6e+DaoZlTKbiJ6zZEU/LNuiFC4IhPm5ZgIRDI+p wvmg== X-Gm-Message-State: AOAM531ybOahWC5xib01Q8cihMMoDK8WYhu8xN2zMamOeBQnJJj1KjvG PkshCt0XUgpbFACAziw3BaDJM9bSviw= X-Google-Smtp-Source: ABdhPJwMboi41K/HwIqi4F25oArHoZn4zvtNYbGgm6VBzrMUwfbqblIvEEVujyqfvtbL1q5nij3vxA== X-Received: by 2002:adf:fd0a:0:b0:1f0:25fd:4082 with SMTP id e10-20020adffd0a000000b001f025fd4082mr318697wrr.501.1646843477748; Wed, 09 Mar 2022 08:31:17 -0800 (PST) Received: from localhost ([137.220.125.106]) by smtp.gmail.com with ESMTPSA id j34-20020a05600c1c2200b0038995cb915fsm8224555wms.9.2022.03.09.08.31.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Mar 2022 08:31:17 -0800 (PST) From: luca.boccassi@gmail.com To: Huisong Li Cc: Min Hu , dpdk stable Subject: patch 'net/hns3: increase time waiting for PF reset completion' has been queued to stable release 20.11.5 Date: Wed, 9 Mar 2022 16:30:25 +0000 Message-Id: <20220309163053.245754-9-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220309163053.245754-1-luca.boccassi@gmail.com> References: <20220218123931.1749595-1-luca.boccassi@gmail.com> <20220309163053.245754-1-luca.boccassi@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Hi, FYI, your patch has been queued to stable release 20.11.5 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 03/11/22. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/38dee9e84ab49a01d12f921e7590062948248a81 Thanks. Luca Boccassi --- >From 38dee9e84ab49a01d12f921e7590062948248a81 Mon Sep 17 00:00:00 2001 From: Huisong Li Date: Wed, 2 Mar 2022 08:35:01 +0800 Subject: [PATCH] net/hns3: increase time waiting for PF reset completion [ upstream commit d6a9f8fb26b8d6adaac20d6a303faa5c5ba4d5bc ] On the case that PF and VF need to be reset, after the hardware reset is complete, VF needs wait for 1 second to restore the configuration so that VF does not fail to recover because PF reset isn't complete. But the estimated time is not sufficient. This patch fixes it to 5 seconds. Fixes: 2790c6464725 ("net/hns3: support device reset") Signed-off-by: Huisong Li Acked-by: Min Hu (Connor) --- drivers/net/hns3/hns3_ethdev_vf.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/net/hns3/hns3_ethdev_vf.c b/drivers/net/hns3/hns3_ethdev_vf.c index 317dd5ec46..b0db01993b 100644 --- a/drivers/net/hns3/hns3_ethdev_vf.c +++ b/drivers/net/hns3/hns3_ethdev_vf.c @@ -2331,6 +2331,7 @@ hns3vf_is_reset_pending(struct hns3_adapter *hns) static int hns3vf_wait_hardware_ready(struct hns3_adapter *hns) { +#define HNS3_WAIT_PF_RESET_READY_TIME 5 struct hns3_hw *hw = &hns->hw; struct hns3_wait_data *wait_data = hw->reset.wait_data; struct timeval tv; @@ -2351,12 +2352,14 @@ hns3vf_wait_hardware_ready(struct hns3_adapter *hns) return 0; wait_data->check_completion = NULL; - wait_data->interval = 1 * MSEC_PER_SEC * USEC_PER_MSEC; + wait_data->interval = HNS3_WAIT_PF_RESET_READY_TIME * + MSEC_PER_SEC * USEC_PER_MSEC; wait_data->count = 1; wait_data->result = HNS3_WAIT_REQUEST; rte_eal_alarm_set(wait_data->interval, hns3_wait_callback, wait_data); - hns3_warn(hw, "hardware is ready, delay 1 sec for PF reset complete"); + hns3_warn(hw, "hardware is ready, delay %d sec for PF reset complete", + HNS3_WAIT_PF_RESET_READY_TIME); return -EAGAIN; } else if (wait_data->result == HNS3_WAIT_TIMEOUT) { hns3_clock_gettime(&tv); -- 2.30.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-03-09 16:30:08.877914881 +0000 +++ 0009-net-hns3-increase-time-waiting-for-PF-reset-completi.patch 2022-03-09 16:30:08.495023990 +0000 @@ -1 +1 @@ -From d6a9f8fb26b8d6adaac20d6a303faa5c5ba4d5bc Mon Sep 17 00:00:00 2001 +From 38dee9e84ab49a01d12f921e7590062948248a81 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit d6a9f8fb26b8d6adaac20d6a303faa5c5ba4d5bc ] + @@ -12 +13,0 @@ -Cc: stable@dpdk.org @@ -21 +22 @@ -index 06ddf64184..9091706fe5 100644 +index 317dd5ec46..b0db01993b 100644 @@ -24 +25 @@ -@@ -1877,6 +1877,7 @@ hns3vf_is_reset_pending(struct hns3_adapter *hns) +@@ -2331,6 +2331,7 @@ hns3vf_is_reset_pending(struct hns3_adapter *hns) @@ -32 +33 @@ -@@ -1897,12 +1898,14 @@ hns3vf_wait_hardware_ready(struct hns3_adapter *hns) +@@ -2351,12 +2352,14 @@ hns3vf_wait_hardware_ready(struct hns3_adapter *hns)