Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753338AbbGUL7v (ORCPT ); Tue, 21 Jul 2015 07:59:51 -0400 Received: from mailout4.samsung.com ([203.254.224.34]:45892 "EHLO mailout4.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751219AbbGUL7s (ORCPT ); Tue, 21 Jul 2015 07:59:48 -0400 X-AuditID: cbfee690-f796f6d000005054-ee-55ae3432f7c7 Date: Tue, 21 Jul 2015 11:59:46 +0000 (GMT) From: Maninder Singh Subject: Re: [PATCH 1/1] ath10k: fixing wrong initialization of struct channel To: Kalle Valo Cc: "ath10k@lists.infradead.org" , "linux-wireless@vger.kernel.org" , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , PANKAJ MISHRA Reply-to: maninder1.s@samsung.com MIME-version: 1.0 X-MTR: 20150721115558388@maninder1.s Msgkey: 20150721115558388@maninder1.s X-EPLocale: en_US.windows-1252 X-Priority: 3 X-EPWebmail-Msg-Type: personal X-EPWebmail-Reply-Demand: 0 X-EPApproval-Locale: X-EPHeader: ML X-MLAttribute: X-RootMTR: 20150721115558388@maninder1.s X-ParentMTR: X-ArchiveUser: X-CPGSPASS: N X-ConfirmMail: N,general Content-type: text/plain; charset=windows-1252 MIME-version: 1.0 Message-id: <1785807958.195941437479984203.JavaMail.weblogic@epmlwas04a> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrGIsWRmVeSWpSXmKPExsWyRsSkTtfIZF2owZF5shaXd81hc2D0+LxJ LoAxissmJTUnsyy1SN8ugSvj94zpzAWLWCsmvlvF2sDYw9rFyMkhJKAmsWjvYzYQW0LAROLu heuMELaYxIV764HiXEA1Sxkl3p5qYoUpevVwNStEYg6jxN27bSwgCRYBVYnfJ7eBTWIT0Jc4 u3cdcxcjB4ewgJ/E+p8OIGERAU2J459Xgg1lFljEJNHTMBXqCkWJ9TeegG3mFRCUODnzCQvE MhWJ5+fWQcVVJT6+fs4OEZeTWDL1M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LWeG 2XV/y1yoXgmJrS1PwO5nBrp/SvdDdgjbQOLIojms6H7hFfCQWPqlj2kCo+wsJKlZSNpnIWlH VrOAkWUVo2hqQXJBcVJ6haFecWJucWleul5yfu4mRnAierZwB+OX89aHGAU4GJV4eC+0rQ0V Yk0sK67MPcQowcGsJMIrYbQuVIg3JbGyKrUoP76oNCe1+BCjKTDWJjJLiSbnA5NkXkm8obGJ uamxqYWBobm5mZI47/9zuSFCAumJJanZqakFqUUwfUwcnFINjB0ikT8FMx90rRYX+bLnCPux I+XyD9o2LpF59sMjep3Xmj/fxRcrHFWseBJ3/Bdzi2mlhQ/zl4fytRwtQlMjmzjTsvbw8v94 vk/wzfw6Fpvrv3oenbPrOHH4pfP9GxdvLP6w58ePyReCfKRevbnvZpGS2n2E8aXwioX/vZWa kzyDXndtMk7o9FZiKc5INNRiLipOBAATP6LlWgMAAA== DLP-Filter: Pass X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by mail.home.local id t6LBxx55004466 Content-Length: 634 Lines: 15 >> chandef is initialized with NULL and on the very next line, >> we are using it to get channel, which is not correct. >> >> channel should be initialized after obtaining chandef. >> >> Signed-off-by: Maninder Singh >How did you find this bug? Static anlysis reports this bug like coverity or any other static tool like cppcheck :- drivers/net/wireless/ath/ath10k/mac.c:839]: (error) Possible null pointer dereference: chandef Thanks, Maninder????{.n?+???????+%?????ݶ??w??{.n?+????{??G?????{ay?ʇڙ?,j??f???h?????????z_??(?階?ݢj"???m??????G????????????&???~???iO???z??v?^?m???? ????????I?