svn commit: r193766 - projects/mesh11s/sys/net80211
Rui Paulo
rpaulo at FreeBSD.org
Mon Jun 8 21:44:04 UTC 2009
Author: rpaulo
Date: Mon Jun 8 21:44:03 2009
New Revision: 193766
URL: http://svn.freebsd.org/changeset/base/193766
Log:
Set the qos variable for MBSS case.
Sponsored by: The FreeBSD Foundation
Modified:
projects/mesh11s/sys/net80211/ieee80211_output.c
Modified: projects/mesh11s/sys/net80211/ieee80211_output.c
==============================================================================
--- projects/mesh11s/sys/net80211/ieee80211_output.c Mon Jun 8 21:42:30 2009 (r193765)
+++ projects/mesh11s/sys/net80211/ieee80211_output.c Mon Jun 8 21:44:03 2009 (r193766)
@@ -1224,6 +1224,7 @@ ieee80211_encap(struct ieee80211vap *vap
int meshhdrsize, meshae;
struct ieee80211_meshcntl_ae11 *mc;
uint32_t seq;
+ uint8_t *qos;
/*
* Copy existing Ethernet header to a safe place. The
@@ -1368,6 +1369,7 @@ ieee80211_encap(struct ieee80211vap *vap
wh = mtod(m, struct ieee80211_frame *);
wh->i_fc[0] = IEEE80211_FC0_VERSION_0 | IEEE80211_FC0_TYPE_DATA;
*(uint16_t *)wh->i_dur = 0;
+ qos = NULL; /* NB: quiet compiler */
if (is4addr) {
wh->i_fc[1] = IEEE80211_FC1_DIR_DSTODS;
IEEE80211_ADDR_COPY(wh->i_addr1, ni->ni_macaddr);
@@ -1410,6 +1412,7 @@ ieee80211_encap(struct ieee80211vap *vap
IEEE80211_ADDR_COPY(wh->i_addr3, eh.ether_dhost);
IEEE80211_ADDR_COPY(WH4(wh)->i_addr4, eh.ether_shost);
mc->mc_flags = 0;
+ qos = ((struct ieee80211_qosframe_addr4 *) wh)->i_qos;
break;
case 4: /* mcast, no proxy */
wh->i_fc[1] = IEEE80211_FC1_DIR_FROMDS;
@@ -1417,6 +1420,7 @@ ieee80211_encap(struct ieee80211vap *vap
IEEE80211_ADDR_COPY(wh->i_addr2, vap->iv_myaddr);
IEEE80211_ADDR_COPY(wh->i_addr3, eh.ether_shost);
mc->mc_flags = 0; /* NB: AE is really 0 */
+ qos = ((struct ieee80211_qosframe *) wh)->i_qos;
break;
case 1: /* mcast, proxy */
wh->i_fc[1] = IEEE80211_FC1_DIR_FROMDS;
@@ -1426,6 +1430,7 @@ ieee80211_encap(struct ieee80211vap *vap
IEEE80211_ADDR_COPY(wh->i_addr3, eh.ether_shost);
mc->mc_flags = 1;
IEEE80211_ADDR_COPY(mc->mc_addr4, eh.ether_shost);
+ qos = ((struct ieee80211_qosframe *) wh)->i_qos;
break;
case 2: /* ucast, proxy */
wh->i_fc[1] = IEEE80211_FC1_DIR_DSTODS;
@@ -1437,6 +1442,7 @@ ieee80211_encap(struct ieee80211vap *vap
mc->mc_flags = 2;
IEEE80211_ADDR_COPY(mc->mc_addr5, eh.ether_shost);
IEEE80211_ADDR_COPY(mc->mc_addr6, eh.ether_shost);
+ qos = ((struct ieee80211_qosframe_addr4 *) wh)->i_qos;
break;
default:
KASSERT(0, ("meshae %d", meshae));
@@ -1456,12 +1462,12 @@ ieee80211_encap(struct ieee80211vap *vap
if (m->m_flags & M_MORE_DATA)
wh->i_fc[1] |= IEEE80211_FC1_MORE_DATA;
if (addqos) {
- uint8_t *qos;
int ac, tid;
if (is4addr) {
qos = ((struct ieee80211_qosframe_addr4 *) wh)->i_qos;
- } else
+ /* NB: mesh case handled earlier */
+ } else if (vap->iv_opmode != IEEE80211_M_MBSS)
qos = ((struct ieee80211_qosframe *) wh)->i_qos;
ac = M_WME_GETAC(m);
/* map from access class/queue to 11e header priorty value */
More information about the svn-src-projects
mailing list