mwifiex: minor cleanups w/ sta_list_spinlock in cfg80211.c
commitf0f7c2275fb925ea287e2da0585d17bde3d1fd2e
authorDouglas Anderson <dianders@chromium.org>
Tue, 3 Oct 2017 15:19:44 +0000 (3 20:49 +0530)
committerKalle Valo <kvalo@codeaurora.org>
Fri, 13 Oct 2017 09:38:03 +0000 (13 12:38 +0300)
tree86bd489bbd71268091bca63a3e48dfd288181274
parent40351051d022762d95142a5a9e37220dbbce39f5
mwifiex: minor cleanups w/ sta_list_spinlock in cfg80211.c

The sta_list_spinlock looks to be used to control locking of the
list. Specifically when someone has the lock they may be allowed
to modify or delete elements of the list.

That implies that we shouldn't access the fields of the elements
returned by mwifiex_get_sta_entry() after we've released the
spinlock. Let's make some small changes so this is true.

It's unlikely that this matters since it looks to be just error
handling, but it's nice to be clean.

Signed-off-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: Ganapathi Bhat <gbhat@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/marvell/mwifiex/cfg80211.c
drivers/net/wireless/marvell/mwifiex/sta_event.c