From patchwork Tue May 14 05:20:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kalle Valo X-Patchwork-Id: 10942031 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 21F1176 for ; Tue, 14 May 2019 05:20:46 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0FD97285DD for ; Tue, 14 May 2019 05:20:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0402F285E0; Tue, 14 May 2019 05:20:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id E54A0285DD for ; Tue, 14 May 2019 05:20:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Cc:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=cjgsma6XHFvW6cL9F/GgTTyPV+ajGFbuhC7xoAQ3wrg=; b=UtK5os3/MBYWMJ EgbhLTFuqkAkZU9ttQEwnFKzQjbSSJquOhNBuittYR8HrcrY1MgCfY/reyWybX/hQSGyysGrOyp1j FkTUqVt6bii+LYiP7VMm4rD1+Z4chwl3xkBUPRsKYFg0PwAyFNAUToRMmYKqGBfAI//4IAxjzm3jp 2mKeXii8bAuYvUV0DlFrB/tDfMtBil03XlUAC3d3ua2QGCtBntWrzarTwoGGXM+XsDQhpRH11B7Pa 47oz60X0avXJjhuSoyJu1c6XGc6LwmKCT5qMPHmy04gqx6JyRVKprz3KkFHATNm6B1a+GUsiCn30y uznUd8uFwkchGaFMZjAQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hQPrn-00058r-Ud; Tue, 14 May 2019 05:20:43 +0000 Received: from smtp.codeaurora.org ([198.145.29.96]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hQPrk-00057p-Vd for ath11k@lists.infradead.org; Tue, 14 May 2019 05:20:43 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id AFC40608A5; Tue, 14 May 2019 05:20:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1557811240; bh=I2/rXQcmNT8/pDfyyDG9C0m/yBQLBinjts5bhnOMxpc=; h=From:To:Subject:Date:In-Reply-To:References:From; b=SUjS+fv5bhwAojDayo4zYUHdDZx9FtoPv5o7EkXPxLiVSD5A1dPvx6A6zR7xzoQhB mSis7IcHG5BcyJZyyXx7uvoxXyHNPSGAWoJzPbfeXRm0gwMcl9z7EJKrR5fJ4A+f9d KzYMy1Q+Q/nPIo73iuZimHTADQijSmOyuqZZQoLg= Received: from x230.adurom.net (88-114-240-156.elisa-laajakaista.fi [88.114.240.156]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: kvalo@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id B054960364 for ; Tue, 14 May 2019 05:20:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1557811240; bh=I2/rXQcmNT8/pDfyyDG9C0m/yBQLBinjts5bhnOMxpc=; h=From:To:Subject:Date:In-Reply-To:References:From; b=SUjS+fv5bhwAojDayo4zYUHdDZx9FtoPv5o7EkXPxLiVSD5A1dPvx6A6zR7xzoQhB mSis7IcHG5BcyJZyyXx7uvoxXyHNPSGAWoJzPbfeXRm0gwMcl9z7EJKrR5fJ4A+f9d KzYMy1Q+Q/nPIo73iuZimHTADQijSmOyuqZZQoLg= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org B054960364 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=kvalo@codeaurora.org From: Kalle Valo To: ath11k@lists.infradead.org Subject: [PATCH 3/3] ath11k: workaround GCC unitialised warnings Date: Tue, 14 May 2019 08:20:34 +0300 Message-Id: <1557811234-5439-3-git-send-email-kvalo@codeaurora.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1557811234-5439-1-git-send-email-kvalo@codeaurora.org> References: <1557811234-5439-1-git-send-email-kvalo@codeaurora.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190513_222041_050341_24CAC398 X-CRM114-Status: UNSURE ( 9.99 ) X-CRM114-Notice: Please train this message. X-BeenThere: ath11k@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "ath11k" Errors-To: ath11k-bounces+patchwork-ath11k=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP After making some WMI functions static GCC started to warn quite a lot about uninitalised variables: ath11k/wmi.c:5303:3: warning: 'install_key_compl.status' may be used uninitialized in this function [-Wmaybe-uninitialized] From a quick look they look like false warnings but let's initialise the variables anyway to make the warning go away. Signed-off-by: Kalle Valo --- drivers/net/wireless/ath/ath11k/wmi.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/net/wireless/ath/ath11k/wmi.c b/drivers/net/wireless/ath/ath11k/wmi.c index 7ca0a64befb4..9a0b904a16ff 100644 --- a/drivers/net/wireless/ath/ath11k/wmi.c +++ b/drivers/net/wireless/ath/ath11k/wmi.c @@ -4805,7 +4805,7 @@ static void ath11k_bcn_tx_status_event(struct ath11k_base *ab, u8 *evt_buf, u32 static void ath11k_vdev_stopped_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { struct ath11k *ar; - u32 vdev_id; + u32 vdev_id = 0; if (ath11k_pull_vdev_stopped_param_tlv(ab, evt_buf, len, &vdev_id) != 0) { @@ -4831,7 +4831,7 @@ static void ath11k_vdev_stopped_event(struct ath11k_base *ab, u8 *evt_buf, u32 l static void ath11k_mgmt_rx_event(struct ath11k_base *ab, struct sk_buff *skb) { - struct mgmt_rx_event_params rx_ev; + struct mgmt_rx_event_params rx_ev = {0}; struct ath11k *ar; struct ieee80211_rx_status *status = IEEE80211_SKB_RXCB(skb); struct ieee80211_hdr *hdr; @@ -4940,7 +4940,7 @@ static void ath11k_mgmt_rx_event(struct ath11k_base *ab, struct sk_buff *skb) static void ath11k_mgmt_tx_compl_event(struct ath11k_base *ab, struct sk_buff *skb) { - struct wmi_mgmt_tx_compl_event tx_compl_param; + struct wmi_mgmt_tx_compl_event tx_compl_param = {0}; struct ath11k *ar; if (ath11k_pull_mgmt_tx_compl_param_tlv(ab, skb->data, skb->len, @@ -4972,7 +4972,7 @@ static void ath11k_mgmt_tx_compl_event(struct ath11k_base *ab, struct sk_buff *s static void ath11k_scan_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { struct ath11k *ar; - struct wmi_scan_event scan_ev; + struct wmi_scan_event scan_ev = {0}; if (ath11k_pull_scan_ev(ab, evt_buf, len, &scan_ev) != 0) { @@ -5079,7 +5079,7 @@ static void ath11k_peer_sta_kickout_event(struct ath11k_base *ab, u8 *evt_buf, u static void ath11k_roam_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { - struct wmi_roam_event roam_ev; + struct wmi_roam_event roam_ev = {}; struct ath11k *ar; if (ath11k_pull_roam_ev(ab, evt_buf, len, &roam_ev) != 0) { @@ -5125,7 +5125,7 @@ static void ath11k_roam_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) static void ath11k_chan_info_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { - struct wmi_chan_info_event ch_info_ev; + struct wmi_chan_info_event ch_info_ev = {0}; struct ath11k *ar; struct survey_info *survey; int idx; @@ -5199,7 +5199,7 @@ static void ath11k_chan_info_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) static void ath11k_pdev_bss_chan_info_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { - struct wmi_pdev_bss_chan_info_event bss_ch_info_ev; + struct wmi_pdev_bss_chan_info_event bss_ch_info_ev = {}; struct survey_info *survey; struct ath11k *ar; u32 cc_freq_hz = ab->cc_freq_hz; @@ -5273,7 +5273,7 @@ static void ath11k_pdev_bss_chan_info_event(struct ath11k_base *ab, u8 *evt_buf, static void ath11k_vdev_install_key_compl_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { - struct wmi_vdev_install_key_complete_arg install_key_compl; + struct wmi_vdev_install_key_complete_arg install_key_compl = {0}; struct ath11k *ar; if (ath11k_pull_vdev_install_key_compl_ev(ab, evt_buf, len, @@ -5347,7 +5347,7 @@ static void ath11k_service_available_event(struct ath11k_base *ab, u8 *evt_buf, static void ath11k_peer_assoc_conf_event(struct ath11k_base *ab, u8 *evt_buf, u32 len) { - struct wmi_peer_assoc_conf_arg peer_assoc_conf; + struct wmi_peer_assoc_conf_arg peer_assoc_conf = {0}; struct ath11k *ar; if (ath11k_pull_peer_assoc_conf_ev(ab, evt_buf, len,