Search Linux Wireless

Re: [PATCH 1/3] mac80211: add IEEE802.11e/WMM structures

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

 



On Wednesday 06 June 2007 01:22, Zhu Yi wrote:
> +#define IEEE80211_TSINFO_TYPE(a)	((a.short1 & 0x0001) >> 0)
> +#define IEEE80211_TSINFO_TSID(a)	((a.short1 & 0x001E) >> 1)
> +#define IEEE80211_TSINFO_DIR(a)		((a.short1 & 0x0060) >> 5)
> +#define IEEE80211_TSINFO_POLICY(a)	((a.short1 & 0x0180) >> 7)
> +#define IEEE80211_TSINFO_AGG(a)		((a.short1 & 0x0200) >> 9)
> +#define IEEE80211_TSINFO_APSD(a)	((a.short1 & 0x0400) >> 10)
> +#define IEEE80211_TSINFO_UP(a)		((a.short1 & 0x3800) >> 11)
> +#define IEEE80211_TSINFO_ACK(a)		((a.short1 & 0xC000) >> 14)
> +#define IEEE80211_TSINFO_SCHEDULE(a)	((a.byte3 & 0x01) >> 0)
> +
> +#define SET_TSINFO_TYPE(i, d)		(i.short1 |= (d << 0) & 0x0001)
> +#define SET_TSINFO_TSID(i, d)		(i.short1 |= (d << 1) & 0x001E)
> +#define SET_TSINFO_DIR(i, d)		(i.short1 |= (d << 5) & 0x0060)
> +#define SET_TSINFO_POLICY(i, d)		(i.short1 |= (d << 7) & 0x0180)
> +#define SET_TSINFO_AGG(i, d)		(i.short1 |= (d << 9) & 0x0200)
> +#define SET_TSINFO_APSD(i, d)		(i.short1 |= (d << 10) & 0x0400)
> +#define SET_TSINFO_UP(i, d)		(i.short1 |= (d << 11) & 0x3800)
> +#define SET_TSINFO_ACK(i, d)		(i.short1 |= (d << 14) & 0xC000)
> +#define SET_TSINFO_SCHEDULE(i, d)	(i.byte3 |= (d << 0) & 0x01)
> +
Everything that touches short1 looks broken on big endian.

-Michael Wu

Attachment: pgpOuVCNCnuH5.pgp
Description: PGP signature


[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