diff options
author | sam <sam@FreeBSD.org> | 2005-12-12 17:54:39 +0000 |
---|---|---|
committer | sam <sam@FreeBSD.org> | 2005-12-12 17:54:39 +0000 |
commit | 9b57399d9c80a38cd6b74718b6d472674344b49a (patch) | |
tree | 141e7e546c1c1e4f1373aa8a7d91f7517f982f64 /sys | |
parent | 4c5cf2f0f19cd9e60956aa3d9626effcafffdeff (diff) | |
download | FreeBSD-src-9b57399d9c80a38cd6b74718b6d472674344b49a.zip FreeBSD-src-9b57399d9c80a38cd6b74718b6d472674344b49a.tar.gz |
add fixed rate for sending multicast frames
Obtained from: atheros
MFC after: 1 week
Diffstat (limited to 'sys')
-rw-r--r-- | sys/net80211/ieee80211_ioctl.c | 6 | ||||
-rw-r--r-- | sys/net80211/ieee80211_ioctl.h | 1 | ||||
-rw-r--r-- | sys/net80211/ieee80211_proto.c | 1 | ||||
-rw-r--r-- | sys/net80211/ieee80211_var.h | 2 |
4 files changed, 10 insertions, 0 deletions
diff --git a/sys/net80211/ieee80211_ioctl.c b/sys/net80211/ieee80211_ioctl.c index 8a15ca8..9419871 100644 --- a/sys/net80211/ieee80211_ioctl.c +++ b/sys/net80211/ieee80211_ioctl.c @@ -1480,6 +1480,9 @@ ieee80211_ioctl_get80211(struct ieee80211com *ic, u_long cmd, struct ieee80211re case IEEE80211_IOC_PUREG: ireq->i_val = (ic->ic_flags & IEEE80211_F_PUREG) != 0; break; + case IEEE80211_IOC_MCAST_RATE: + ireq->i_val = ic->ic_mcast_rate; + break; case IEEE80211_IOC_FRAGTHRESHOLD: ireq->i_val = ic->ic_fragthreshold; break; @@ -2369,6 +2372,9 @@ ieee80211_ioctl_set80211(struct ieee80211com *ic, u_long cmd, struct ieee80211re if (ic->ic_curmode == IEEE80211_MODE_11G) error = ENETRESET; break; + case IEEE80211_IOC_MCAST_RATE: + ic->ic_mcast_rate = ireq->i_val & IEEE80211_RATE_VAL; + break; case IEEE80211_IOC_FRAGTHRESHOLD: if ((ic->ic_caps & IEEE80211_C_TXFRAG) == 0 && ireq->i_val != IEEE80211_FRAG_MAX) diff --git a/sys/net80211/ieee80211_ioctl.h b/sys/net80211/ieee80211_ioctl.h index 8c3b2ab..86da41e 100644 --- a/sys/net80211/ieee80211_ioctl.h +++ b/sys/net80211/ieee80211_ioctl.h @@ -442,6 +442,7 @@ struct ieee80211req { #define IEEE80211_IOC_ADDMAC 54 /* add sta to MAC ACL table */ #define IEEE80211_IOC_DELMAC 55 /* del sta from MAC ACL table */ #define IEEE80211_IOC_PUREG 56 /* pure 11g (no 11b stations) */ +#define IEEE80211_IOC_MCAST_RATE 72 /* tx rate for mcast frames */ #define IEEE80211_IOC_FRAGTHRESHOLD 73 /* tx fragmentation threshold */ /* diff --git a/sys/net80211/ieee80211_proto.c b/sys/net80211/ieee80211_proto.c index 5537b33..8f3abd8 100644 --- a/sys/net80211/ieee80211_proto.c +++ b/sys/net80211/ieee80211_proto.c @@ -97,6 +97,7 @@ ieee80211_proto_attach(struct ieee80211com *ic) ic->ic_rtsthreshold = IEEE80211_RTS_DEFAULT; ic->ic_fragthreshold = IEEE80211_FRAG_DEFAULT; ic->ic_fixed_rate = IEEE80211_FIXED_RATE_NONE; + ic->ic_mcast_rate = IEEE80211_MCAST_RATE_DEFAULT; ic->ic_protmode = IEEE80211_PROT_CTSONLY; ic->ic_roaming = IEEE80211_ROAMING_AUTO; diff --git a/sys/net80211/ieee80211_var.h b/sys/net80211/ieee80211_var.h index 05a8849..b4be276 100644 --- a/sys/net80211/ieee80211_var.h +++ b/sys/net80211/ieee80211_var.h @@ -74,6 +74,7 @@ #define IEEE80211_PS_MAX_QUEUE 50 /* maximum saved packets */ #define IEEE80211_FIXED_RATE_NONE -1 +#define IEEE80211_MCAST_RATE_DEFAULT (2*1) /* default mcast rate (1M) */ #define IEEE80211_RTS_DEFAULT IEEE80211_RTS_MAX #define IEEE80211_FRAG_DEFAULT IEEE80211_FRAG_MAX @@ -138,6 +139,7 @@ struct ieee80211com { struct ieee80211_channel *ic_ibss_chan; struct ieee80211_channel *ic_curchan; /* current channel */ int ic_fixed_rate; /* index to ic_sup_rates[] */ + int ic_mcast_rate; /* rate for mcast frames */ u_int16_t ic_rtsthreshold; u_int16_t ic_fragthreshold; struct ieee80211_node *(*ic_node_alloc)(struct ieee80211_node_table*); |