firmware-utils/mkzynfw: add support for the NBG460N board
[openwrt.git] / package / iw / patches / 110-freq.patch
1 --- a/interface.c
2 +++ b/interface.c
3 @@ -260,6 +260,27 @@ static int print_iface_handler(struct nl
4 printf("%s\tifindex %d\n", indent, nla_get_u32(tb_msg[NL80211_ATTR_IFINDEX]));
5 if (tb_msg[NL80211_ATTR_IFTYPE])
6 printf("%s\ttype %s\n", indent, iftype_name(nla_get_u32(tb_msg[NL80211_ATTR_IFTYPE])));
7 + if (tb_msg[NL80211_ATTR_WIPHY_FREQ]) {
8 + const char *mode;
9 +
10 + if (tb_msg[NL80211_ATTR_WIPHY_CHANNEL_TYPE])
11 + switch(nla_get_u32(tb_msg[NL80211_ATTR_WIPHY_CHANNEL_TYPE])) {
12 + case NL80211_CHAN_HT20:
13 + mode = "HT20";
14 + break;
15 + case NL80211_CHAN_HT40PLUS:
16 + mode = "HT40+";
17 + break;
18 + case NL80211_CHAN_HT40MINUS:
19 + mode = "HT40-";
20 + break;
21 + default:
22 + mode = "";
23 + }
24 +
25 + printf("%s\tfrequency %d MHz %s\n", indent, nla_get_u32(tb_msg[NL80211_ATTR_WIPHY_FREQ]), mode);
26 + }
27 +
28
29 return NL_SKIP;
30 }
This page took 0.04269 seconds and 5 git commands to generate.