* [PATCH] staging: rtl8192u: remove null check after call container_of()
@ 2022-05-16 10:22 Haowen Bai
0 siblings, 0 replies; only message in thread
From: Haowen Bai @ 2022-05-16 10:22 UTC (permalink / raw)
To: Greg Kroah-Hartman; +Cc: Haowen Bai, linux-staging, linux-kernel
container_of() will never return NULL, so remove useless code.
Signed-off-by: Haowen Bai <baihaowen@meizu.com>
---
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c b/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
index 7fdce759d23d..92001cb36730 100644
--- a/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
+++ b/drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
@@ -1700,8 +1700,6 @@ static inline void ieee80211_sta_ps(struct work_struct *work)
unsigned long flags, flags2;
ieee = container_of(work, struct ieee80211_device, ps_task);
- if (!ieee)
- return;
spin_lock_irqsave(&ieee->lock, flags);
--
2.7.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2022-05-16 10:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-16 10:22 [PATCH] staging: rtl8192u: remove null check after call container_of() Haowen Bai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).