Search Linux Wireless

Re: [PATCH 5/6v2] mac80211: rx.c/tx.c remove more users of tx/rx_data->fc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2008-07-09 at 01:04 +0200, Johannes Berg wrote:
> On Tue, 2008-07-08 at 15:25 -0700, Harvey Harrison wrote:
> > Those functions that still use ieee80211_get_hdrlen are moved over
> > to use the little endian frame control.
> 
> > -	switch (fc & (IEEE80211_FCTL_TODS | IEEE80211_FCTL_FROMDS)) {
> > -	case IEEE80211_FCTL_TODS:
> > -		/* BSSID SA DA */
> > -		memcpy(dst, hdr->addr3, ETH_ALEN);
> > -		memcpy(src, hdr->addr2, ETH_ALEN);
> > -
> > +	switch (hdr->frame_control &
> > +		cpu_to_le16(IEEE80211_FCTL_TODS | IEEE80211_FCTL_FROMDS)) {
> > +	case __constant_cpu_to_le16(IEEE80211_FCTL_TODS):
> >  		if (unlikely(sdata->vif.type != IEEE80211_IF_TYPE_AP &&
> >  			     sdata->vif.type != IEEE80211_IF_TYPE_VLAN))
> >  			return -1;
> >  		break;
> 
> Looks good, but didn't you just lose all the memcpys?
> 

See the three lines immediately before the part you quoted.

Harvey

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux