From: Johannes Berg Date: Tue, 16 Oct 2012 18:12:37 +0000 (+0200) Subject: print more feature flags X-Git-Tag: v3.7~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d28df6b499b47451d1ba8224114c34c713a6bae5;p=thirdparty%2Fiw.git print more feature flags Signed-off-by: Johannes Berg --- diff --git a/info.c b/info.c index f039bba..c4b5de2 100644 --- a/info.c +++ b/info.c @@ -432,12 +432,18 @@ broken_combination: } if (tb_msg[NL80211_ATTR_FEATURE_FLAGS]) { - if (nla_get_u32(tb_msg[NL80211_ATTR_FEATURE_FLAGS]) & - NL80211_FEATURE_SK_TX_STATUS) + unsigned int features = nla_get_u32(tb_msg[NL80211_ATTR_FEATURE_FLAGS]); + + if (features & NL80211_FEATURE_SK_TX_STATUS) printf("\tDevice supports TX status socket option.\n"); - if (nla_get_u32(tb_msg[NL80211_ATTR_FEATURE_FLAGS]) & - NL80211_FEATURE_HT_IBSS) + if (features & NL80211_FEATURE_HT_IBSS) printf("\tDevice supports HT-IBSS.\n"); + if (features & NL80211_FEATURE_INACTIVITY_TIMER) + printf("\tDevice has client inactivity timer.\n"); + if (features & NL80211_FEATURE_CELL_BASE_REG_HINTS) + printf("\tDevice accepts cell base station regulatory hints.\n"); + if (features & NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL) + printf("\tP2P Device uses a channel (of the concurrent ones)\n"); } return NL_SKIP;