diff options
author | adrian <adrian@FreeBSD.org> | 2011-11-08 14:22:40 +0000 |
---|---|---|
committer | adrian <adrian@FreeBSD.org> | 2011-11-08 14:22:40 +0000 |
commit | 17ae07e6dd6a50b4609582559848105c36e1ce43 (patch) | |
tree | 1e2aabb594ca28fbfaecb350cd8283004b43363d /sbin/ifconfig/ifieee80211.c | |
parent | c2950f3c9ceda28fc6ac670023806066c9b2af75 (diff) | |
download | FreeBSD-src-17ae07e6dd6a50b4609582559848105c36e1ce43.zip FreeBSD-src-17ae07e6dd6a50b4609582559848105c36e1ce43.tar.gz |
Add quiet time element configuration support to ifconfig.
This allows a hostap to specify to a set of stations that they
should not transmit for a certain period of time after each
beacon interval has expired. This is used when searching for
radar pulses or general interference.
Submitted by: Himali Patel <himali.patel@sibridgetech.com>
Sponsored by: Sibridge Technologies
Diffstat (limited to 'sbin/ifconfig/ifieee80211.c')
-rw-r--r-- | sbin/ifconfig/ifieee80211.c | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/sbin/ifconfig/ifieee80211.c b/sbin/ifconfig/ifieee80211.c index 77fcc8c..a84c5bf 100644 --- a/sbin/ifconfig/ifieee80211.c +++ b/sbin/ifconfig/ifieee80211.c @@ -1337,6 +1337,36 @@ set80211pureg(const char *val, int d, int s, const struct afswtch *rafp) } static void +set80211quiet(const char *val, int d, int s, const struct afswtch *rafp) +{ + set80211(s, IEEE80211_IOC_QUIET, d, 0, NULL); +} + +static +DECL_CMD_FUNC(set80211quietperiod, val, d) +{ + set80211(s, IEEE80211_IOC_QUIET_PERIOD, atoi(val), 0, NULL); +} + +static +DECL_CMD_FUNC(set80211quietcount, val, d) +{ + set80211(s, IEEE80211_IOC_QUIET_COUNT, atoi(val), 0, NULL); +} + +static +DECL_CMD_FUNC(set80211quietduration, val, d) +{ + set80211(s, IEEE80211_IOC_QUIET_DUR, atoi(val), 0, NULL); +} + +static +DECL_CMD_FUNC(set80211quietoffset, val, d) +{ + set80211(s, IEEE80211_IOC_QUIET_OFFSET, atoi(val), 0, NULL); +} + +static void set80211bgscan(const char *val, int d, int s, const struct afswtch *rafp) { set80211(s, IEEE80211_IOC_BGSCAN, d, 0, NULL); @@ -5161,6 +5191,12 @@ static struct cmd ieee80211_cmds[] = { DEF_CMD_ARG("bgscanidle", set80211bgscanidle), DEF_CMD_ARG("bgscanintvl", set80211bgscanintvl), DEF_CMD_ARG("scanvalid", set80211scanvalid), + DEF_CMD("quiet", 1, set80211quiet), + DEF_CMD("-quiet", 0, set80211quiet), + DEF_CMD_ARG("quiet_count", set80211quietcount), + DEF_CMD_ARG("quiet_period", set80211quietperiod), + DEF_CMD_ARG("quiet_dur", set80211quietduration), + DEF_CMD_ARG("quiet_offset", set80211quietoffset), DEF_CMD_ARG("roam:rssi", set80211roamrssi), DEF_CMD_ARG("roam:rate", set80211roamrate), DEF_CMD_ARG("mcastrate", set80211mcastrate), |