mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 18:41:58 +09:00
wifi: ath9k: fix parameter check in ath9k_init_debug()
[ Upstream commit 6edb4ba6fb ]
Make IS_ERR() judge the debugfs_create_dir() function return
in ath9k_init_debug()
Signed-off-by: Minjie Du <duminjie@vivo.com>
Acked-by: Toke Høiland-Jørgensen <toke@toke.dk>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20230712114740.13226-1-duminjie@vivo.com
Stable-dep-of: f6ffe7f01847 ("wifi: ath9k: Remove error checks when creating debugfs entries")
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
f4ea89abbe
commit
4738809fee
@@ -1420,7 +1420,7 @@ int ath9k_init_debug(struct ath_hw *ah)
|
|||||||
|
|
||||||
sc->debug.debugfs_phy = debugfs_create_dir("ath9k",
|
sc->debug.debugfs_phy = debugfs_create_dir("ath9k",
|
||||||
sc->hw->wiphy->debugfsdir);
|
sc->hw->wiphy->debugfsdir);
|
||||||
if (!sc->debug.debugfs_phy)
|
if (IS_ERR(sc->debug.debugfs_phy))
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
#ifdef CONFIG_ATH_DEBUG
|
#ifdef CONFIG_ATH_DEBUG
|
||||||
|
|||||||
Reference in New Issue
Block a user