]> git.ipfire.org Git - thirdparty/linux.git/commit
wifi: rtw89: chan: allow callers to check if a link has no managed chanctx
authorZong-Zhe Yang <kevin_yang@realtek.com>
Mon, 15 Sep 2025 06:52:03 +0000 (14:52 +0800)
committerPing-Ke Shih <pkshih@realtek.com>
Thu, 18 Sep 2025 01:10:12 +0000 (09:10 +0800)
commitdf3d55a63f9a9372f6530fedfc495b2164181c5d
treef46ffe48048da4516614b758ae823003e231e6e3
parent17002412a82feb21be040bd5577789049dfeebe2
wifi: rtw89: chan: allow callers to check if a link has no managed chanctx

Originally, to directly align with the chanctx design, getter of managed
chanctx returned a default channel when a link doesn't own a chanctx yet.
Then, callers could simply use the return without trivial NULL checking.

But in MLD HW settings of next chip, there will be a special case that a
caller needs to check if a link has owned chanctx or not to determine
CCK hardware circuit working on HW-x. So, add a func *_or_null for this
first.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Link: https://patch.msgid.link/20250915065213.38659-2-pkshih@realtek.com
drivers/net/wireless/realtek/rtw89/chan.c
drivers/net/wireless/realtek/rtw89/chan.h