From: Johannes Berg Date: Sat, 11 Apr 2009 11:32:46 +0000 (+0200) Subject: cfg80211: convert mutex assert to macro X-Git-Tag: v2.6.31-rc1~330^2~568^2~69 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=7edfab7adef45a09b459cb7f5957f476108f5e77;p=~shefty%2Frdma-dev.git cfg80211: convert mutex assert to macro That will make the various cases where the WARN_ON can happen distinguishable. Signed-off-by: Johannes Berg Signed-off-by: John W. Linville --- diff --git a/net/wireless/core.h b/net/wireless/core.h index fcee83a0c9b..02668b02e33 100644 --- a/net/wireless/core.h +++ b/net/wireless/core.h @@ -73,10 +73,7 @@ bool wiphy_idx_valid(int wiphy_idx) extern struct mutex cfg80211_mutex; extern struct list_head cfg80211_drv_list; -static inline void assert_cfg80211_lock(void) -{ - WARN_ON(!mutex_is_locked(&cfg80211_mutex)); -} +#define assert_cfg80211_lock() WARN_ON(!mutex_is_locked(&cfg80211_mutex)) /* * You can use this to mark a wiphy_idx as not having an associated wiphy.