Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5075893ybv; Tue, 11 Feb 2020 08:44:37 -0800 (PST) X-Google-Smtp-Source: APXvYqyzFzkWzZ8VozjyANiHe8Xq3FAnyqrMrRUukzOWHjxpqOVZ82Nvx0BEvItIJVjHHWEWtIbt X-Received: by 2002:a05:6830:18c4:: with SMTP id v4mr5699980ote.265.1581439477334; Tue, 11 Feb 2020 08:44:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581439477; cv=none; d=google.com; s=arc-20160816; b=kxLf6QthYdkwIJzE3V4rL4Pkn2PpTLwKtf+jNpsR3wHsHlX7/B/7UcdwqA5ugY6iNM tECu0a1rYdBz3DypvAhvfS0+bzbrQ2bF07UtazXhqjIyBGXcytv1uuDt6k2Y7ZXbYBNP +rXlN5ccGL34oM2j5bbG0EH9gSmdZCJzJNzmFmaiwBWTSekWuPHklkr0Yg17aTxOr7jl ZGjQZ5zaP+dwbaaZBsyX60SrmLUGbnvsiC5fuLtytXGFO92M5VUETYtIdfdzBVQQyza8 1d3ntKljcmgrCKFv/k0UdCafIwL1sBQYBTjlxN7DhoWDC34Trp90QZ8n9VaGEfxQLBMl dhqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=ZEVAORjxHVdfjX6yMrMUf83tPWM3dzcA6bh4IDQ8gj4=; b=H0UEV5LPDJ3ZRlvCBv2Pawe7+JJtl6jfn/Ec5hdL6D9JnqWvIxwGBrW1fVXF68InMa QJ1PpsZaaG603XZOItENXEj1Z0+AI9/aW0CxPkHznFTPuC5ePeoFeohEWsM7tbeTeb3t Srh+SAx8uqzX1r0EHDF+GTxgmbsSsFAq0HfhxLkN3Bsw19KTls5Q1ns+gsvO8XBzS3wM G8p6ilhoBTslHz1Ap8pJUpzcgIYuwLgxt/Ha2kU/yKVKr1bDGnLJvn9dFc8X/yhgyBTa eFu13/VNcIa80Ki6gN5TdV43MWqQw/2zdiWfIuRwE7vuJc8ZYIgaNf3icxKs5nDxpD7U Cbug== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u1si2304304otg.113.2020.02.11.08.44.26; Tue, 11 Feb 2020 08:44:37 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728810AbgBKOnx (ORCPT + 99 others); Tue, 11 Feb 2020 09:43:53 -0500 Received: from nbd.name ([46.4.11.11]:39786 "EHLO nbd.name" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727728AbgBKOnx (ORCPT ); Tue, 11 Feb 2020 09:43:53 -0500 Received: from [2a04:4540:1401:2a00:cab8:b5b3:a1b1:af79] by ds12 with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1j1WlP-0002NF-1t; Tue, 11 Feb 2020 15:43:47 +0100 Subject: Re: [RESEND V2 3/4] ath11k: switch to using ieee80211_tx_status_ext() To: Sven Eckelmann , ath11k@lists.infradead.org Cc: Kalle Valo , linux-wireless@vger.kernel.org References: <20200204151135.25302-1-john@phrozen.org> <20200204151135.25302-3-john@phrozen.org> <87h7zxxob7.fsf@kamboji.qca.qualcomm.com> <4744821.iAptAJfnkX@bentobox> From: John Crispin Message-ID: <94d0da89-6b48-0433-7a01-275af1a99ca1@phrozen.org> Date: Tue, 11 Feb 2020 15:43:46 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <4744821.iAptAJfnkX@bentobox> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On 11/02/2020 15:38, Sven Eckelmann wrote: > On Tuesday, 11 February 2020 14:10:04 CET Kalle Valo wrote: > [...] >>> diff --git a/drivers/net/wireless/ath/ath11k/dp_tx.c b/drivers/net/wireless/ath/ath11k/dp_tx.c >>> index 7b532bf9acd8..66a6cfd54ad9 100644 >>> --- a/drivers/net/wireless/ath/ath11k/dp_tx.c >>> +++ b/drivers/net/wireless/ath/ath11k/dp_tx.c >>> @@ -357,9 +357,12 @@ static void ath11k_dp_tx_complete_msdu(struct ath11k *ar, >>> struct sk_buff *msdu, >>> struct hal_tx_status *ts) >>> { >>> + struct ieee80211_tx_status status = { 0 }; >> >> This adds a sparse warning: >> >> drivers/net/wireless/ath/ath11k/dp_tx.c:350:47: warning: Using plain integer as NULL pointer >> >> Seems like a false warning, no? But not sure how to shut up the warning, >> using '{ NULL }' would do that but just feels wrong. Any opinions? > > Why is this a false warning? The structure is following: > > struct ieee80211_tx_status { > struct ieee80211_sta *sta; > struct ieee80211_tx_info *info; > struct sk_buff *skb; > struct rate_info *rate; > }; > > And this is a pre-C99 initializer. The equal C99-Initializer would be > > struct ieee80211_tx_status status = { > .sta = NULL, > }; > > So it is initializing status.sta with 0. But status.sta is a pointer > and we should use NULL for pointers instead of plain 0. If you want > to initialize the object on stack to zero but not initialize each > member then just use {}. > > Kind regards, > Sven > yup, i just need to drop the 0 and use {}. I'll respin/send John