Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752105AbdFUNye (ORCPT ); Wed, 21 Jun 2017 09:54:34 -0400 Received: from mail-bn3nam01on0061.outbound.protection.outlook.com ([104.47.33.61]:46656 "EHLO NAM01-BN3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750999AbdFUNya (ORCPT ); Wed, 21 Jun 2017 09:54:30 -0400 Authentication-Results: canonical.com; dkim=none (message not signed) header.d=none;canonical.com; dmarc=none action=none header.from=quantenna.com; Date: Wed, 21 Jun 2017 16:54:04 +0300 From: Sergey Matyukevich To: Colin King Cc: Igor Mitsyanko , Avinash Patil , Sergey Matyukevich , Kalle Valo , "David S . Miller" , Bindu Therthala , Kamlesh Rath , Sergei Maksimenko , Johannes Berg , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH][net-next] qtnfmac: fix uninitialized return code in ret Message-ID: <20170621135402.e4iwovvmdumarzqj@bars> Mail-Followup-To: Colin King , Igor Mitsyanko , Avinash Patil , Sergey Matyukevich , Kalle Valo , "David S . Miller" , Bindu Therthala , Kamlesh Rath , Sergei Maksimenko , Johannes Berg , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org References: <20170621132530.11937-1-colin.king@canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170621132530.11937-1-colin.king@canonical.com> User-Agent: NeoMutt/20170113 (1.7.2) X-Originating-IP: [195.182.157.76] X-ClientProxiedBy: KL1PR06CA0047.apcprd06.prod.outlook.com (10.170.170.15) To BLUPR05MB1922.namprd05.prod.outlook.com (10.162.224.12) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 37812412-ab5c-49ad-39a2-08d4b8ad0803 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001)(201703131423075)(201703031133081);SRVR:BLUPR05MB1922; X-Microsoft-Exchange-Diagnostics: 1;BLUPR05MB1922;3:7bqa7SqewIhQt6Sb1fcnHKc0kmJcACDztN1AMm5/3ZvJ6xUwD8/KK7VIUCreFRYSR/NOJJ499sXlN+mmA9yWBGt13lgBnSH0/3hFr/D1ijfn5ioH5p7fxC9z9aAffELyqQlltbFJkNy4oU7NHl547RX5WAXKNirw6ICFt0UCVJHZPM53mNiF0BxXM/ih7kagmJXGKCPtHiWaJlG8GrO973hrXyec0r5BSWpzmtIKLonT2sf8QzU054XrpTCKN2xRomJIQ/AhrZDyuYA6blVFHm12KdZVSn16QSLW2HJgvpmSFdbjSPMDioj1RFaXZU5O0C6wRCj1+gC4cVptdDQZRA==;25:ExW2lQbN6Ea/0OjZGF2nGL92WA3AilJxS9MJ/EGbnOGhT7DpiEtm2mWZNLXEbS0k0fMzbC5mUC6aNFb9rPOTnXdR4cBwhhZ/IrXVDUYmbnBGcaCX0HuLE3GbxQuCEaMORKwHmRpb2NPIp13byu1HYNaJ0QikTMh+pPUvD17neic+Xv9iKVq16uATAyBnkKcBFslGB9nheQs6CJuNDMQ855UA5xIma2e2VBn88yFfS19CFUplteBDCj99zu6jexAxIolpBc38vYpT5FDMO8SZ482gtWF4/tyOLjCqYZz+9JN4NlzVnbQluGepLnjPJFh7fA3ZKCY7BQNuD78vaCZ9dBda+Jj9jXwRPsI9IWif0Ii3xjaglmd0MxPw9mPrn1ODFf6xA9YOVI2IwLawTNXMn/T9ySmcZz9wBsp/UzGJFbPTR/w5F5LPbwIydVCxqGfHeXPN04Mu0V92sCvn2MrfkYBxi8BaS6HDfQ3rS2Ed+VA= X-MS-TrafficTypeDiagnostic: BLUPR05MB1922: X-Microsoft-Exchange-Diagnostics: 1;BLUPR05MB1922;31:u00yV74MsAQIf2aqavFF41b9xY7WaCmjqOdHXkcmYQrQ02ltFpWY09cSXOvjglmFpfYYmYThMFYOWaEEF36fry23d4+Dzv0UT/VJGxB0qGWwbNP85FAiZPmhwtCz5qAB4uLSJ0WhHwI8MW6/PICMeUMwbE3ACIR09X3e3fkp9RU0t3nQMfeK3H/5aOpyV/b2mXNewb00EuKqWSeAeiOnSYJgnDIsRqOBu0ApfIAlWkg=;20:mjN/AEgrsT4436W87sEvHy1QX9XrVwEQr3GTIjzbyLJLXm3W7c0LjvUQ/5Aap+L+4GkwR1jGxNL+Vgkgo6yXN8mTZRlNmfY4cEY4A9b9FbVXXPVMYo4PFEeV1SN47c3WVOSjwEF+aP1lv2/L2VM8T+xzRoc2dqm2YioIgoQzzV+NuUiPL/qTjkj+UzbyOrTHdh5Pn0R9J+L03htFVHMt6eNiu7IDJUTsNKFLXErJTiVKRX4/p4AlJZWWTQICIkLelTQ+Zr7Dy4VSgR3nhdXaLC8BpyAnTbENAMZnrfEEEasFUxj5ugGeiWezECa3mRq622OYxaeGKNl+UmVhhS5XDrG+153HJNvpVNACxv4AY9TO+Ni9PhBQKsTGdhpiO+eCwbtuQPxVpKjMH2aMGLugqQCoQa3HjroX4CEAUKDeuVPdtDkFVuCdQXYhPwMAwwzupjbvC8fOh3dhxkfR3p0Lrl43fw7rUqBg23vMWczn/8iTnYSe2pEPyl9qb2ZZfXlf X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(198206253151910); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046)(100000703101)(100105400095)(93006095)(93001095)(6041248)(20161123560025)(20161123564025)(20161123558100)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123555025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:BLUPR05MB1922;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SR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us-ascii?Q?YFeYINGiaQRrT2RJNFaFOzAjQzmU8KKjv7Z6GhLJydKL3H6EB+gnRXIsjxvx?= =?us-ascii?Q?9lnIO4nzjM/Ut5dMo+BVIKdAUHKNVKVhdgbTQJbCWtiF/3i2eieBBsuUXpnb?= =?us-ascii?Q?sAyWMmxkMDisiIilLXmu+l4pWBLc96RPaKfBg3lfYhnOcbV+S8GqNeHOzJcO?= =?us-ascii?Q?uDuTOjzFxVfaOr41BQqdSKUZvGImh2tRK7Qkie01tvEN8mWrT4eE+cS2DF7R?= =?us-ascii?Q?ENSDw5TOk1jq6kyzA9gwir5b/tV1EXMbcSlKmUM59miEk4iOjH+tegC6XCy7?= =?us-ascii?Q?s2SItqcNECc+I8Rl+sQePs8e9AUrVqiyPzp+q1ruwaIoWb5drUNmtiWPNItS?= =?us-ascii?Q?RmZtELG7E0sKE=3D?= X-Forefront-PRVS: 0345CFD558 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(4630300001)(6009001)(39410400002)(39450400003)(39830400002)(39400400002)(53936002)(55016002)(110136004)(38730400002)(6246003)(305945005)(5660300001)(4001350100001)(189998001)(47776003)(54906002)(9686003)(50466002)(478600001)(575784001)(7736002)(66066001)(86362001)(8676002)(25786009)(81166006)(33646002)(229853002)(4326008)(6116002)(3846002)(1076002)(23726003)(76176999)(54356999)(50986999)(6916009)(33716001)(42186005)(6666003)(2950100002)(83506001)(2906002);DIR:OUT;SFP:1101;SCL:1;SRVR:BLUPR05MB1922;H:bars;FPR:;SPF:None;MLV:sfv;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;BLUPR05MB1922;23:az3shfwJPwkKHSjYdvaAOKLo7F08O4eVZJFalS4n0?= =?us-ascii?Q?ZhHh/ymUdhG5Jw7bU+XjyKtfErgRK1K0KZK49oUBAQTymkz6VOSLrFc1jeaL?= =?us-ascii?Q?AbTVANCvBFpqEiWiVqDgsPThnvsjU9hMK2fLgj0Xc+iKHDA/jH/H4CP2J13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9j1Cx/peUz4UGn0sAwchFwxPOjeM9C9O7?= =?us-ascii?Q?dPeDH9+gEULy6b4YAqjQOQcorbEC3P5jiHSGzZVIVT0l5UF6loYVtqFo53+j?= =?us-ascii?Q?qxv30DIaZUdYePJNOrSVaYyOvg5kaGY+MPtmbUaSD1JIbNrI2g8XLw5rs6Og?= =?us-ascii?Q?wg4kAo0sMgVpZDnrcfvEM3HvVB/KY/GXhpqvM03d30ImD/lunz2dvo3WaHt0?= =?us-ascii?Q?enBNyAi946E8sJGastO8n8n9yhvLBSSp6ast6gtttxUorxiOquHum5QTYIyY?= =?us-ascii?Q?8=3D?= X-Microsoft-Exchange-Diagnostics: 1;BLUPR05MB1922;5:F4N+UJJnN8WXR8MLFQsb89hjb6Qz2ByT4hcLg0KasP/4db4F5kV5ZiKLwUr4NgDQxTHchawTeRbxvyLWUmQspRktDthcG7GmaD7DA4xLzo+nxvV5V6X8KdBFGOOld75IaYKXUfSqeSKwcMDG7VmHzTcJhQp3vsBplWMXjFpwEi/WiL1sUw6DEcRJ5uzz3AzSK/HeeV4tbypkYMbMwOiIrw92Wg6vTsYb3g3Mud+Tt7WqvF3K0EwjH6SQxTVIHj71+WYfUAt0nZpy13dmbRvcqbS3ZExWHBSN0GVuMiNwYNDEZa3qheylmFvqU5YlJ4FUPN5TTVuEIfq1M2sEcZlptVnDhg184H/shTb8bf5gUxYs03hboUW3rn49uHLgfjqKVIyID9vwSXrwBgSBEiZqo4U3kunvqkf2K1POvQTYAAn6SGAUGO42OcDAdV6212QDZVyix/W6BOjpzMispPZyR5hUFnH9S/GSlk9zuv+07RFsCtb79gyQi17Kv23H33P0;24:Lmy//K1I8/Cb1WCI6ZFrd7vDPJQcWjsNJEs9gra5tAVUrGGeTRVNmNdrOOowoyc2B8Jew48HIzfaoXK0PcTSpolqU21iF1wtgrQILLnWKZ0= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;BLUPR05MB1922;7:gHfZFX0Kfw6G/mdO7DwB+YfAGTSJ5hAOuykEvFBPbDe9eHyL/3/YM8vslR2lelwFkcB/HT/eJYJaLJH58dywX0ith/mUcKpG3QVDkc2KGSvgtcFH2TCGe5Wf9tO4sdw6p8RP3zDkgPHJ3hXv2/a3NtCONTeSpIYseBl7eMjkrnd8S2oBj4v3Fjvxhkze30rZ1EYfLXkJNB1EooB9+K29pFrAUOLLJp9DZg/xlChbQT85kAh4TjmmrcaoMt2/jyMcqn0nK3GkM0EfvIVM4Pdp5MKw8CsEGsvonlgj9O47BLoveHSxIHbCMKIsHuk+HHPgSxOb+Mp7Y8uZF7pRE+UNvcYLRKD7bsWMd18mY+v9pNnyFljn3kJrBxeu0pIb/XVM1iTb50N9ydWN2iadm0l4fN9Q3BIHhhtjUKJzVAsLbclPHZCGj8Yxo5Wq/J78TdYXocwKsqGLQKhsMIPt2zUvUlp17iaYKdIz6OS9/nN/zjnV583S3k7w8A8UUm6YPkaJ3tRSApbbf+gyFzgzCw0DHjK/zfjMvWa6TI9dm5czCvlIgst0m960HNRTaZdfndMpFARcL50OyHTDeb/5qakpzAPlHo9MLWkLr/utx076fEbCaU/wC3p/th0rCGYyrGzfC4AURgM8j9OlQehv9i6RlX8rMQVSQ1Sy3Hqc/pUvXDwXHdXEqzC4uU8jcYdxureSLfGCZUYU1Na3PSA8m7MFAEKzZBvzpKQ9VebTODNwa6iDIw27quzFyeF6j745VKbdHu2sDXLX7WaHyrF9Wh1cJEHHsYAmQFfGoMI/qbRHork= X-OriginatorOrg: quantenna.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jun 2017 13:54:19.4986 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR05MB1922 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1345 Lines: 36 > The return value ret is unitialized and garbage is being returned > for the three different error conditions when setting up the PCIe > BARs. Fix this by initializing ret to -ENOMEM to indicate that > the BARs failed to be setup correctly. > > Detected by CoverityScan, CID#1437563 ("Unitialized scalar variable") > > Signed-off-by: Colin Ian King > --- > drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c b/drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c > index f93b27f3a236..7fc4f0d6a9ad 100644 > --- a/drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c > +++ b/drivers/net/wireless/quantenna/qtnfmac/pearl/pcie.c > @@ -247,7 +247,7 @@ static void qtnf_pcie_free_shm_ipc(struct qtnf_pcie_bus_priv *priv) > > static int qtnf_pcie_init_memory(struct qtnf_pcie_bus_priv *priv) > { > - int ret; > + int ret = -ENOMEM; > > priv->sysctl_bar = qtnf_map_bar(priv, QTN_SYSCTL_BAR); > if (IS_ERR_OR_NULL(priv->sysctl_bar)) { > -- Thanks ! Reviewed-by: Sergey Matyukevich By the way, could you please use the recepient list suggested by get_maintainer.pl script from the kernel scripts directory. Regards, Sergey