wihap_sta_disassoc(sc, rxfrm->wi_addr2, IEEE80211_REASON_ASSOC_LEAVE);
wihap_data_input(struct wi_softc *sc, struct wi_frame *rxfrm, struct mbuf *m){	struct ifnet		*ifp = &sc->sc_arpcom.ac_if;	struct wihap_info	*whi = &sc->wi_hostap_info;	struct wihap_sta_info	*sta;	int			mcast, s;	/* TODS flag must be set. */	if (!(rxfrm->wi_frame_ctl & htole16(WI_FCTL_TODS))) {		if (ifp->if_flags & IFF_DEBUG)			printf("wihap_data_input: no TODS src=%s\n",			    ether_sprintf(rxfrm->wi_addr2));		m_freem(m);		return (1);	}	/* Check BSSID. (Is this necessary?) */	if (!addr_cmp(rxfrm->wi_addr1, sc->sc_arpcom.ac_enaddr)) {		if (ifp->if_flags & IFF_DEBUG)			printf("wihap_data_input: incorrect bss: %s\n",			    ether_sprintf(rxfrm->wi_addr1));		m_freem(m);		return (1);	}	s = splsoftclock();	/* Find source station. */	sta = wihap_sta_find(whi, rxfrm->wi_addr2);	/* Source station must be associated. */	if (sta == NULL || !(sta->flags & WI_SIFLAGS_ASSOC)) {		if (ifp->if_flags & IFF_DEBUG)			printf("wihap_data_input: dropping unassoc src %s\n",			    ether_sprintf(rxfrm->wi_addr2));		splx(s);		m_freem(m);		return (1);	}	timeout_add(&sta->tmo, hz * whi->inactivity_time);	sta->sig_info = letoh16(rxfrm->wi_q_info);	splx(s);	/* Repeat this packet to BSS? */	mcast = (rxfrm->wi_addr3[0] & 0x01) != 0;	if (mcast || wihap_sta_is_assoc(whi, rxfrm->wi_addr3)) {		/* If it's multicast, make a copy.		 */		if (mcast) {			m = m_copym(m, 0, M_COPYALL, M_DONTWAIT);			if (m == NULL)				return (0);			m->m_flags |= M_MCAST; /* XXX */		}		/* Queue up for repeating.		 */		if (IF_QFULL(&ifp->if_snd)) {			IF_DROP(&ifp->if_snd);			m_freem(m);		}		else {			ifp->if_obytes += m->m_pkthdr.len;			if (m->m_flags & M_MCAST)				ifp->if_omcasts++;			IF_ENQUEUE(&ifp->if_snd, m);			if ((ifp->if_flags & IFF_OACTIVE) == 0)				(*ifp->if_start)(ifp);		}		return (!mcast);	}	return (0);}