From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 546F0A04CC; Mon, 21 Sep 2020 15:38:49 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id EFF261DA47; Mon, 21 Sep 2020 15:38:40 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by dpdk.org (Postfix) with ESMTP id 946591D942 for ; Mon, 21 Sep 2020 15:38:37 +0200 (CEST) IronPort-SDR: 5YTg3gAzIRAsabTQfnIKXwVf9IyeOJJZzt9Z3Q8+Egux19ytK8iT20FIOxe33PvKAsn8sTYr78 2CxlkzE/fE5A== X-IronPort-AV: E=McAfee;i="6000,8403,9750"; a="140387192" X-IronPort-AV: E=Sophos;i="5.77,286,1596524400"; d="scan'208";a="140387192" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Sep 2020 06:38:34 -0700 IronPort-SDR: IKJ2KiivbkpII+9rpVX9S5iGtZpeC2gjaflPkmVNQzc8JK7KNK0KOZ9xm72VEstCwuP8khlAYB LalUMdL2AniA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,286,1596524400"; d="scan'208";a="510074220" Received: from silpixa00399752.ir.intel.com (HELO silpixa00399752.ger.corp.intel.com) ([10.237.222.180]) by fmsmga006.fm.intel.com with ESMTP; 21 Sep 2020 06:38:32 -0700 From: Ferruh Yigit To: Rasesh Mody , Shahed Shaikh Cc: dev@dpdk.org, Ferruh Yigit Date: Mon, 21 Sep 2020 14:38:27 +0100 Message-Id: <20200921133830.1575872-1-ferruh.yigit@intel.com> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 1/4] net/qede: fix build with gcc 11 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" Error observed with gcc 11 under development gcc (GCC) 11.0.0 20200920 (experimental) build error: ../drivers/net/qede/qede_main.c: In function ‘qed_get_current_link’: ../drivers/net/qede/qede_main.c:587:17: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation] 587 | if (!ptt) | ^~ ../drivers/net/qede/qede_main.c:590:25: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’ 590 | qed_fill_link(hwfn, ptt, if_link); | ^~~~~~~~~~~~~ Signed-off-by: Ferruh Yigit --- I am not clear what the exact intention of the original code is, compiler warning is about wrong indentation of 'qed_fill_link(..)', I have updated the code to keep the behavior same but fix the indentation. Please send a proper fix if the existing behavior needs to be updated. --- drivers/net/qede/qede_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/qede/qede_main.c b/drivers/net/qede/qede_main.c index aecb98261..0f82568d3 100644 --- a/drivers/net/qede/qede_main.c +++ b/drivers/net/qede/qede_main.c @@ -587,7 +587,7 @@ qed_get_current_link(struct ecore_dev *edev, struct qed_link_output *if_link) if (!ptt) DP_NOTICE(hwfn, true, "Failed to fill link; No PTT\n"); - qed_fill_link(hwfn, ptt, if_link); + qed_fill_link(hwfn, ptt, if_link); if (ptt) ecore_ptt_release(hwfn, ptt); -- 2.26.2