mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Aloka Dixit <alokad@codeaurora.org>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	Kalle Valo <kvalo@codeaurora.org>
Subject: drivers/net/wireless/ath/ath11k/mac.c:1892:7: warning: Uninitialized variable: ret
Date: Tue, 2 Mar 2021 01:02:31 +0800	[thread overview]
Message-ID: <202103020120.4uzsVzW3-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8
commit: 047679e366b9842a9da3ab82dca26fcaad8020eb ath11k: FILS discovery and unsolicited broadcast probe response support
date:   4 months ago
compiler: or1k-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>


"cppcheck warnings: (new ones prefixed by >>)"
>> drivers/net/wireless/ath/ath11k/mac.c:1892:7: warning: Uninitialized variable: ret [uninitvar]
    if (!ret)
         ^

vim +1892 drivers/net/wireless/ath/ath11k/mac.c

  1852	
  1853	static int ath11k_mac_fils_discovery(struct ath11k_vif *arvif,
  1854					     struct ieee80211_bss_conf *info)
  1855	{
  1856		struct ath11k *ar = arvif->ar;
  1857		struct sk_buff *tmpl;
  1858		int ret;
  1859		u32 interval;
  1860		bool unsol_bcast_probe_resp_enabled = false;
  1861	
  1862		if (info->fils_discovery.max_interval) {
  1863			interval = info->fils_discovery.max_interval;
  1864	
  1865			tmpl = ieee80211_get_fils_discovery_tmpl(ar->hw, arvif->vif);
  1866			if (tmpl)
  1867				ret = ath11k_wmi_fils_discovery_tmpl(ar, arvif->vdev_id,
  1868								     tmpl);
  1869		} else if (info->unsol_bcast_probe_resp_interval) {
  1870			unsol_bcast_probe_resp_enabled = 1;
  1871			interval = info->unsol_bcast_probe_resp_interval;
  1872	
  1873			tmpl = ieee80211_get_unsol_bcast_probe_resp_tmpl(ar->hw,
  1874									 arvif->vif);
  1875			if (tmpl)
  1876				ret = ath11k_wmi_probe_resp_tmpl(ar, arvif->vdev_id,
  1877								 tmpl);
  1878		} else { /* Disable */
  1879			return ath11k_wmi_fils_discovery(ar, arvif->vdev_id, 0, false);
  1880		}
  1881	
  1882		if (!tmpl) {
  1883			ath11k_warn(ar->ab,
  1884				    "mac vdev %i failed to retrieve %s template\n",
  1885				    arvif->vdev_id, (unsol_bcast_probe_resp_enabled ?
  1886				    "unsolicited broadcast probe response" :
  1887				    "FILS discovery"));
  1888			return -EPERM;
  1889		}
  1890		kfree_skb(tmpl);
  1891	
> 1892		if (!ret)
  1893			ret = ath11k_wmi_fils_discovery(ar, arvif->vdev_id, interval,
  1894							unsol_bcast_probe_resp_enabled);
  1895	
  1896		return ret;
  1897	}
  1898	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

                 reply	other threads:[~2021-03-01 20:13 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202103020120.4uzsVzW3-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=alokad@codeaurora.org \
    --cc=kbuild-all@lists.01.org \
    --cc=kvalo@codeaurora.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®