public inbox for ath12k@lists.infradead.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@linaro.org>
To: Maharaja Kennadyrajan <maharaja.kennadyrajan@oss.qualcomm.com>
Cc: ath12k@lists.infradead.org
Subject: [bug report] wifi: ath12k: Extend beacon miss handling for MLO non-AP STA
Date: Tue, 23 Sep 2025 14:21:15 +0300	[thread overview]
Message-ID: <aNKCq7AiPb_1z3ig@stanley.mountain> (raw)

Hello Maharaja Kennadyrajan,

Commit dcdb05a43df9 ("wifi: ath12k: Extend beacon miss handling for
MLO non-AP STA") from Aug 12, 2025 (linux-next), leads to the
following Smatch static checker warning:

	drivers/net/wireless/ath/ath12k/wmi.c:7344 ath12k_peer_sta_kickout_event()
	error: uninitialized symbol 'link_id'.

drivers/net/wireless/ath/ath12k/wmi.c
    7305 static void ath12k_peer_sta_kickout_event(struct ath12k_base *ab, struct sk_buff *skb)
    7306 {
    7307         struct wmi_peer_sta_kickout_arg arg = {};
    7308         struct ath12k_link_vif *arvif;
    7309         struct ieee80211_sta *sta;
    7310         struct ath12k_peer *peer;
    7311         unsigned int link_id;
    7312         struct ath12k *ar;
    7313 
    7314         if (ath12k_pull_peer_sta_kickout_ev(ab, skb, &arg) != 0) {
    7315                 ath12k_warn(ab, "failed to extract peer sta kickout event");
    7316                 return;
    7317         }
    7318 
    7319         rcu_read_lock();
    7320 
    7321         spin_lock_bh(&ab->base_lock);
    7322 
    7323         peer = ath12k_peer_find_by_addr(ab, arg.mac_addr);
    7324 
    7325         if (!peer) {
    7326                 ath12k_warn(ab, "peer not found %pM\n",
    7327                             arg.mac_addr);
    7328                 goto exit;
    7329         }
    7330 
    7331         arvif = ath12k_mac_get_arvif_by_vdev_id(ab, peer->vdev_id);
    7332         if (!arvif) {
    7333                 ath12k_warn(ab, "invalid vdev id in peer sta kickout ev %d",
    7334                             peer->vdev_id);
    7335                 goto exit;
    7336         }
    7337 
    7338         ar = arvif->ar;
    7339 
    7340         if (peer->mlo) {
    7341                 sta = ieee80211_find_sta_by_link_addrs(ath12k_ar_to_hw(ar),
    7342                                                        arg.mac_addr,
    7343                                                        NULL, &link_id);

link_id is uninitialized on error.

--> 7344                 if (peer->link_id != link_id) {
                                              ^^^^^^^

    7345                         ath12k_warn(ab,
    7346                                     "Spurious quick kickout for MLO STA %pM with invalid link_id, peer: %d, sta: %d\n",
    7347                                     arg.mac_addr, peer->link_id, link_id);
    7348                         goto exit;

regards,
dan carpenter


                 reply	other threads:[~2025-09-23 11:21 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=aNKCq7AiPb_1z3ig@stanley.mountain \
    --to=dan.carpenter@linaro.org \
    --cc=ath12k@lists.infradead.org \
    --cc=maharaja.kennadyrajan@oss.qualcomm.com \
    /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