iw: Add support for antenna configuration commands
[openwrt/svn-archive/archive.git] / package / iw / patches / 120-ibss_mcast_rate.patch
1 --- a/ibss.c
2 +++ b/ibss.c
3 @@ -83,6 +83,20 @@ static int join_ibss(struct nl80211_stat
4 argc--;
5 }
6
7 + /* multicast rate */
8 + if (argc > 1 && strcmp(argv[0], "mcast-rate") == 0) {
9 + argv++;
10 + argc--;
11 +
12 + rate = strtod(argv[0], &end);
13 + if (*end != '\0')
14 + return 1;
15 +
16 + NLA_PUT_U32(msg, NL80211_ATTR_MCAST_RATE, (int) rate * 10);
17 + argv++;
18 + argc--;
19 + }
20 +
21 if (!argc)
22 return 0;
23
24 @@ -109,7 +123,7 @@ COMMAND(ibss, leave, NULL,
25 "Leave the current IBSS cell.");
26 COMMAND(ibss, join,
27 "<SSID> <freq in MHz> [fixed-freq] [<fixed bssid>] "
28 - "[basic-rates <rate in Mbps,rate2,...>] [key d:0:abcde]",
29 + "[basic-rates <rate in Mbps,rate2,...>] [mcast-rate <rate in Mbps>] [key d:0:abcde]",
30 NL80211_CMD_JOIN_IBSS, 0, CIB_NETDEV, join_ibss,
31 "Join the IBSS cell with the given SSID, if it doesn't exist create\n"
32 "it on the given frequency. When fixed frequency is requested, don't\n"