From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 852B21B4B6 for ; Thu, 29 Nov 2018 14:22:43 +0100 (CET) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id DB99AA705; Thu, 29 Nov 2018 13:22:42 +0000 (UTC) Received: from ktraynor.remote.csb (ovpn-117-230.ams2.redhat.com [10.36.117.230]) by smtp.corp.redhat.com (Postfix) with ESMTP id 97FB41001F50; Thu, 29 Nov 2018 13:22:41 +0000 (UTC) From: Kevin Traynor To: Yanglong Wu Cc: Rosen Xu , Qi Zhang , dpdk stable Date: Thu, 29 Nov 2018 13:20:29 +0000 Message-Id: <20181129132128.7609-29-ktraynor@redhat.com> In-Reply-To: <20181129132128.7609-1-ktraynor@redhat.com> References: <20181129132128.7609-1-ktraynor@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Thu, 29 Nov 2018 13:22:42 +0000 (UTC) Subject: [dpdk-stable] patch 'net/ixgbevf: fix link state' has been queued to stable release 18.08.1 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Nov 2018 13:22:43 -0000 Hi, FYI, your patch has been queued to stable release 18.08.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 12/08/18. 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. If the code is different (ie: not only metadata diffs), due for example to a change in context or macro names, please double check it. Thanks. Kevin Traynor --- >>From dddf7cc46a056d3b0f1da9fda67b3334f6778143 Mon Sep 17 00:00:00 2001 From: Yanglong Wu Date: Tue, 13 Nov 2018 14:34:43 +0800 Subject: [PATCH] net/ixgbevf: fix link state [ upstream commit 91546fb62e675943a574c2542c0486f2928fed49 ] For ixgbevf kernel driver, link status changes from down to up will trigger vf kernel driver send IXGBE_VF_RESET message to pf kernel driver, after this, vf kernel driver will disable and enable it self. By these series operations, the vf kernel driver report link up. Besides, all these operations handles in kernel thread. For DPDK user space driver, it only gets link status changes from down to up, but miss IXGBE_VF_RESET message sending and reset itself. If we will add fully implementation of link status change for DPDK user space driver, we need take much more modification. We have aligned that for link status changes from down to up we only notify link is up, users need to reset vf port. Fixes: dc66e5fd01b9 ("net/ixgbe: improve link state check on VF") Signed-off-by: Rosen Xu Signed-off-by: Yanglong Wu Acked-by: Qi Zhang --- drivers/net/ixgbe/ixgbe_ethdev.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c index 6b04820da..9de9c0c3e 100644 --- a/drivers/net/ixgbe/ixgbe_ethdev.c +++ b/drivers/net/ixgbe/ixgbe_ethdev.c @@ -3884,9 +3884,4 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, int *link_up, int wait_to_complete) { - /** - * for a quick link status checking, wait_to_compelet == 0, - * skip PF link status checking - */ - bool no_pflink_check = wait_to_complete == 0; struct ixgbe_mbx_info *mbx = &hw->mbx; struct ixgbe_mac_info *mac = &hw->mac; @@ -3949,12 +3944,4 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, } - if (no_pflink_check) { - if (*speed == IXGBE_LINK_SPEED_UNKNOWN) - mac->get_link_status = true; - else - mac->get_link_status = false; - - goto out; - } /* if the read failed it could just be a mailbox collision, best wait * until we are called again and don't report an error @@ -3966,5 +3953,5 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, /* msg is not CTS and is NACK we must have lost CTS status */ if (in_msg & IXGBE_VT_MSGTYPE_NACK) - ret_val = -1; + mac->get_link_status = false; goto out; } -- 2.19.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2018-11-29 13:11:35.765752130 +0000 +++ 0028-net-ixgbevf-fix-link-state.patch 2018-11-29 13:11:34.000000000 +0000 @@ -1,8 +1,10 @@ -From 91546fb62e675943a574c2542c0486f2928fed49 Mon Sep 17 00:00:00 2001 +From dddf7cc46a056d3b0f1da9fda67b3334f6778143 Mon Sep 17 00:00:00 2001 From: Yanglong Wu Date: Tue, 13 Nov 2018 14:34:43 +0800 Subject: [PATCH] net/ixgbevf: fix link state +[ upstream commit 91546fb62e675943a574c2542c0486f2928fed49 ] + For ixgbevf kernel driver, link status changes from down to up will trigger vf kernel driver send IXGBE_VF_RESET message to pf kernel driver, after this, vf kernel driver will disable and enable @@ -16,7 +18,6 @@ link is up, users need to reset vf port. Fixes: dc66e5fd01b9 ("net/ixgbe: improve link state check on VF") -Cc: stable@dpdk.org Signed-off-by: Rosen Xu Signed-off-by: Yanglong Wu @@ -26,10 +27,10 @@ 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c -index 8148577f5..91ba6201d 100644 +index 6b04820da..9de9c0c3e 100644 --- a/drivers/net/ixgbe/ixgbe_ethdev.c +++ b/drivers/net/ixgbe/ixgbe_ethdev.c -@@ -3881,9 +3881,4 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, +@@ -3884,9 +3884,4 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, int *link_up, int wait_to_complete) { - /** @@ -39,7 +40,7 @@ - bool no_pflink_check = wait_to_complete == 0; struct ixgbe_mbx_info *mbx = &hw->mbx; struct ixgbe_mac_info *mac = &hw->mac; -@@ -3946,12 +3941,4 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, +@@ -3949,12 +3944,4 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, } - if (no_pflink_check) { @@ -52,7 +53,7 @@ - } /* if the read failed it could just be a mailbox collision, best wait * until we are called again and don't report an error -@@ -3963,5 +3950,5 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, +@@ -3966,5 +3953,5 @@ ixgbevf_check_link(struct ixgbe_hw *hw, ixgbe_link_speed *speed, /* msg is not CTS and is NACK we must have lost CTS status */ if (in_msg & IXGBE_VT_MSGTYPE_NACK) - ret_val = -1;