mac80211: Fix build error when CONFIG_PM is not defined
When mac80211 is built without CONFIG_PM being defined, the following errors are output: net/mac80211/main.c: In function ‘ieee80211_register_hw’: net/mac80211/main.c:700: error: ‘const struct ieee80211_ops’ has no member named ‘suspend’ net/mac80211/main.c:700: error: ‘const struct ieee80211_ops’ has no member named ‘resume’ make[2]: *** [net/mac80211/main.o] Error 1 make[1]: *** [net/mac80211] Error 2 make[1]: *** Waiting for unfinished jobs.... make: *** [net] Error 2 Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
3782cf4a04
commit
38bb3e9da6
1 changed files with 5 additions and 2 deletions
|
@ -696,8 +696,11 @@ int ieee80211_register_hw(struct ieee80211_hw *hw)
|
||||||
WLAN_CIPHER_SUITE_AES_CMAC
|
WLAN_CIPHER_SUITE_AES_CMAC
|
||||||
};
|
};
|
||||||
|
|
||||||
if ((hw->wiphy->wowlan.flags || hw->wiphy->wowlan.n_patterns) &&
|
if ((hw->wiphy->wowlan.flags || hw->wiphy->wowlan.n_patterns)
|
||||||
(!local->ops->suspend || !local->ops->resume))
|
#ifdef CONFIG_PM
|
||||||
|
&& (!local->ops->suspend || !local->ops->resume)
|
||||||
|
#endif
|
||||||
|
)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
if (hw->max_report_rates == 0)
|
if (hw->max_report_rates == 0)
|
||||||
|
|
Loading…
Add table
Reference in a new issue