diff options
author | sam <sam@FreeBSD.org> | 2005-12-12 19:23:55 +0000 |
---|---|---|
committer | sam <sam@FreeBSD.org> | 2005-12-12 19:23:55 +0000 |
commit | 7245fda6a0da943b16115109fc02e54f53fc90cc (patch) | |
tree | 42a4fcec2f6c0df4b3c1124c2d8fd6227dd8a375 /sbin/ifconfig/ifieee80211.c | |
parent | f051015cb92da82137e08a0aeefe9a9a2b6e5dc2 (diff) | |
download | FreeBSD-src-7245fda6a0da943b16115109fc02e54f53fc90cc.zip FreeBSD-src-7245fda6a0da943b16115109fc02e54f53fc90cc.tar.gz |
add mcastrate support
MFC after: 1 week
Diffstat (limited to 'sbin/ifconfig/ifieee80211.c')
-rw-r--r-- | sbin/ifconfig/ifieee80211.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/sbin/ifconfig/ifieee80211.c b/sbin/ifconfig/ifieee80211.c index b7c6a82..eece245 100644 --- a/sbin/ifconfig/ifieee80211.c +++ b/sbin/ifconfig/ifieee80211.c @@ -663,6 +663,12 @@ set80211pureg(const char *val, int d, int s, const struct afswtch *rafp) } static +DECL_CMD_FUNC(set80211mcastrate, val, d) +{ + set80211(s, IEEE80211_IOC_MCAST_RATE, (int) 2*atof(val), 0, NULL); +} + +static DECL_CMD_FUNC(set80211fragthreshold, val, d) { set80211(s, IEEE80211_IOC_FRAGTHRESHOLD, @@ -1613,6 +1619,17 @@ ieee80211_status(int s) LINE_CHECK("%crtsthreshold %d", spacer, ireq.i_val); } + ireq.i_type = IEEE80211_IOC_MCAST_RATE; + if (ioctl(s, SIOCG80211, &ireq) != -1) { + if (ireq.i_val != 2*1 || verbose) { + if (ireq.i_val == 11) + LINE_CHECK("%cmcastrate 5.5", spacer); + else + LINE_CHECK("%cmcastrate %d", spacer, + ireq.i_val/2); + } + } + ireq.i_type = IEEE80211_IOC_FRAGTHRESHOLD; if (ioctl(s, SIOCG80211, &ireq) != -1) { if (ireq.i_val != IEEE80211_FRAG_MAX || verbose) @@ -1913,6 +1930,7 @@ static struct cmd ieee80211_cmds[] = { DEF_CMD_ARG("mac:kick", set80211kickmac), DEF_CMD("pureg", 1, set80211pureg), DEF_CMD("-pureg", 0, set80211pureg), + DEF_CMD_ARG("mcastrate", set80211mcastrate), DEF_CMD_ARG("fragthreshold", set80211fragthreshold), }; static struct afswtch af_ieee80211 = { |