From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f50.google.com (mail-lf1-f50.google.com [209.85.167.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 032B23806BC for ; Mon, 2 Feb 2026 16:49:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770050997; cv=none; b=QhFYTKQYd05GqQFmg483CPrXdbPXtASxXZ53jseb9mIxvQ+jH9K101iU79Jw78au9mdBG//EHXEaNIHwVHlRTBfTz3q3zfjvET4ztwiLE15kd5p6UJdC3duHETeimyfh61kkk33aoXuUBlbSTcREpsSosgQfispP/A3YikPmohg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770050997; c=relaxed/simple; bh=jhN+YleJ9I8wkZB6e165Fsm08eZT4j05sZ9wxNMGoE0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=E61uYuH370MAzmtz6eQf+jTI0qNVUrNUoC6+UyFgn581SW/98ktkjMgx7Udc/yo0Ar0fi63W4ECIENgvGd6AoaGFe9mxsscqVHRzD9PI6x7qrFP2MtxUP+qG0SH1tPuB9rYxors57eWU9L1I3OMVJkuosDZlifrhUW/1hrVTUXs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=lPPziV2+; arc=none smtp.client-ip=209.85.167.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="lPPziV2+" Received: by mail-lf1-f50.google.com with SMTP id 2adb3069b0e04-59dd54b1073so5451532e87.0 for ; Mon, 02 Feb 2026 08:49:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1770050994; x=1770655794; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=fXhgxcsuPkNcRdWC6jKl2Ki9gol6dqqET4szBsmvqSc=; b=lPPziV2+8KqpvVW4SSYqUvubwR55ZB7NbvQJkcT8WqbHMBodB/OqWVecJjQL2hLYvh vAsgNnJlpQEsFGdGdwgxb12Uz89qaK0a+Zj8wzsoCFE8s/GjyEcYUjTWVnEYDsnXgz1M lM5YHURR/DErrpnQXzoHF7YkmD13v4ZumEJQ3qixrJl9xBx7fU1m49LYGDJbmi+ojVEz EcU5PefYFBE0jnT4ND5xFQ4iNBmOAyaDcFw4PHqKp0PiTnCk5vd+iHTi4x89nFfvCJVf s6N6DmeBEy1ph+M1Gp2Oa9TJ7DKH4g3juujiqrWuS2ZfSCiNavx3pG5s5yEnnqXvelqi d7VQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770050994; x=1770655794; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=fXhgxcsuPkNcRdWC6jKl2Ki9gol6dqqET4szBsmvqSc=; b=Jd4+7+YLKydT8VRW/OtOGz13bkZLcq+UkKIqIzR37Pjq+779imrhiEFYQLtOY/LEOu ivmhOizBzBRuFZnoupYhZd6M9ZssypVAK1QPgYx51rdywFut+eEVE/k+S7Y6MykTFLII ymlBnbW02M62JG7Q7OmON+I33n19+UzmFLyKSSWN4oGdZ/d9mLc+ma35BLalNWUnmgDN ELb6JJq8LRO8Fh7MUMt01pi9/Gqs1fAfoqwsImwiYenDZyy2iiQWOFSQETQguTFy4jL1 f6pyItC4yi+MTkehfGbXc2dY5W3p90Ygt+yppwLC42/pP25u7W2kqcyZwzwfmFNVkMl0 aEHQ== X-Forwarded-Encrypted: i=1; AJvYcCU9tfqt1EZ/Ga3Bbeuo2gZPtFDmEnSKTytBSMSC4rZ2tAgZ6MPBA/rNxFKD1ZmrumFEYwT6k1wyUFN8Gqw=@vger.kernel.org X-Gm-Message-State: AOJu0YxNwhjyqXT4JzWifE+ToxVj7vwmfdwNWXbCil0biaE6jj35CGDT OgUaIYT8inRzD2ylrkjVjWkqmP8uG6/IqutaPy3f5T16GE26MkuHSB+C X-Gm-Gg: AZuq6aLsSOw+erYw2DdRl42zI1U2LrkV4QR/fmXYvF77nV1jVpatMDMwyyDynabs9zq 7xprYspkOe0opoHwdKxH2ypKcXqOiYwpbPL+NE0GaQI/URwQLpwtpNgrz0g/YDrH2c3ig3VrU/F 7dsENjy2oMrHi05fkIEZ+xtOLyXP1iQvIrnAayqMa1AYOr+bcBYA3s8zTefX+JH+mRR34GOB1Pw DJ23cZEEI8kuASFcAxuht2aihXLvjkPqbQqgdl6sG/ROG7kyljNXLmSvovOc6Iy+x0sH0zYCF6q 6l4VDCsSXrxO7patdc8sgmDs/BB51Ekhvr7rAkCrhDByUD9/aRH8I/J0O6x4ShwJIn5wH79g/m1 H0dAeEUsSwsrN/L0KifsuiYzOOK32GKtIdpYBiMCidu8Xt3ZXZr7pq72I1B9muYi3toXpxnuzwD /MsthpckMm+z5jk6LEThuhBOWTwLTMG4785A+Rvk0HEzutCia8BL/JJi9YJud6B7XqmKVWoDiuO JGrLkgukA== X-Received: by 2002:ac2:4f07:0:b0:59e:2c7a:1ae0 with SMTP id 2adb3069b0e04-59e2c7a1b1dmr780344e87.13.1770050994021; Mon, 02 Feb 2026 08:49:54 -0800 (PST) Received: from uuba.fritz.box (2001-14ba-6e-3100-2ef5-59d5-c9b3-566.rev.dnainternet.fi. [2001:14ba:6e:3100:2ef5:59d5:c9b3:566]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-59e074b7092sm3598268e87.71.2026.02.02.08.49.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Feb 2026 08:49:53 -0800 (PST) From: =?UTF-8?q?Hanne-Lotta=20M=C3=A4enp=C3=A4=C3=A4?= To: stable@vger.kernel.org Cc: johannes@sipsolutions.net, linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, Johannes Berg , Emmanuel Grumbach , =?UTF-8?q?Hanne-Lotta=20M=C3=A4enp=C3=A4=C3=A4?= Subject: [PATCH 6.1.y 2/2] wifi: mac80211: move TDLS work to wiphy work Date: Mon, 2 Feb 2026 18:49:24 +0200 Message-ID: <20260202164924.215621-2-hannelotta@gmail.com> X-Mailer: git-send-email 2.53.0.rc2.2.g2258446484 In-Reply-To: <20260202164924.215621-1-hannelotta@gmail.com> References: <20260202164924.215621-1-hannelotta@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Johannes Berg [ Upstream commit 777b26002b73127e81643d9286fadf3d41e0e477 ] Again, to have the wiphy locked for it. Reviewed-by: Emmanuel Grumbach Signed-off-by: Johannes Berg [ Summary of conflict resolutions: - In mlme.c, move only tdls_peer_del_work to wiphy work, and none the other works ] Signed-off-by: Hanne-Lotta Mäenpää --- net/mac80211/ieee80211_i.h | 4 ++-- net/mac80211/mlme.c | 7 ++++--- net/mac80211/tdls.c | 11 ++++++----- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index 6cc5bba2ba52..e94a370da4c4 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h @@ -531,7 +531,7 @@ struct ieee80211_if_managed { /* TDLS support */ u8 tdls_peer[ETH_ALEN] __aligned(2); - struct delayed_work tdls_peer_del_work; + struct wiphy_delayed_work tdls_peer_del_work; struct sk_buff *orig_teardown_skb; /* The original teardown skb */ struct sk_buff *teardown_skb; /* A copy to send through the AP */ spinlock_t teardown_lock; /* To lock changing teardown_skb */ @@ -2525,7 +2525,7 @@ int ieee80211_tdls_mgmt(struct wiphy *wiphy, struct net_device *dev, size_t extra_ies_len); int ieee80211_tdls_oper(struct wiphy *wiphy, struct net_device *dev, const u8 *peer, enum nl80211_tdls_operation oper); -void ieee80211_tdls_peer_del_work(struct work_struct *wk); +void ieee80211_tdls_peer_del_work(struct wiphy *wiphy, struct wiphy_work *wk); int ieee80211_tdls_channel_switch(struct wiphy *wiphy, struct net_device *dev, const u8 *addr, u8 oper_class, struct cfg80211_chan_def *chandef); diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c index 8824460a2060..30db27df6b79 100644 --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c @@ -6517,8 +6517,8 @@ void ieee80211_sta_setup_sdata(struct ieee80211_sub_if_data *sdata) ieee80211_beacon_connection_loss_work); INIT_WORK(&ifmgd->csa_connection_drop_work, ieee80211_csa_connection_drop_work); - INIT_DELAYED_WORK(&ifmgd->tdls_peer_del_work, - ieee80211_tdls_peer_del_work); + wiphy_delayed_work_init(&ifmgd->tdls_peer_del_work, + ieee80211_tdls_peer_del_work); timer_setup(&ifmgd->timer, ieee80211_sta_timer, 0); timer_setup(&ifmgd->bcn_mon_timer, ieee80211_sta_bcn_mon_timer, 0); timer_setup(&ifmgd->conn_mon_timer, ieee80211_sta_conn_mon_timer, 0); @@ -7524,7 +7524,8 @@ void ieee80211_mgd_stop(struct ieee80211_sub_if_data *sdata) cancel_work_sync(&ifmgd->monitor_work); cancel_work_sync(&ifmgd->beacon_connection_loss_work); cancel_work_sync(&ifmgd->csa_connection_drop_work); - cancel_delayed_work_sync(&ifmgd->tdls_peer_del_work); + wiphy_delayed_work_cancel(sdata->local->hw.wiphy, + &ifmgd->tdls_peer_del_work); sdata_lock(sdata); if (ifmgd->assoc_data) diff --git a/net/mac80211/tdls.c b/net/mac80211/tdls.c index 04531d18fa93..1f07b598a6a1 100644 --- a/net/mac80211/tdls.c +++ b/net/mac80211/tdls.c @@ -21,7 +21,7 @@ /* give usermode some time for retries in setting up the TDLS session */ #define TDLS_PEER_SETUP_TIMEOUT (15 * HZ) -void ieee80211_tdls_peer_del_work(struct work_struct *wk) +void ieee80211_tdls_peer_del_work(struct wiphy *wiphy, struct wiphy_work *wk) { struct ieee80211_sub_if_data *sdata; struct ieee80211_local *local; @@ -1128,9 +1128,9 @@ ieee80211_tdls_mgmt_setup(struct wiphy *wiphy, struct net_device *dev, return ret; } - ieee80211_queue_delayed_work(&sdata->local->hw, - &sdata->u.mgd.tdls_peer_del_work, - TDLS_PEER_SETUP_TIMEOUT); + wiphy_delayed_work_queue(sdata->local->hw.wiphy, + &sdata->u.mgd.tdls_peer_del_work, + TDLS_PEER_SETUP_TIMEOUT); return 0; out_unlock: @@ -1427,7 +1427,8 @@ int ieee80211_tdls_oper(struct wiphy *wiphy, struct net_device *dev, } if (ret == 0 && ether_addr_equal(sdata->u.mgd.tdls_peer, peer)) { - cancel_delayed_work(&sdata->u.mgd.tdls_peer_del_work); + wiphy_delayed_work_cancel(sdata->local->hw.wiphy, + &sdata->u.mgd.tdls_peer_del_work); eth_zero_addr(sdata->u.mgd.tdls_peer); } -- 2.53.0.rc2.2.g2258446484