From: Assaf Krauss Date: Mon, 30 Jun 2008 09:23:16 +0000 (+0800) Subject: mac80211: add beacon timestamp to beacon template in IBSS X-Git-Tag: Ubuntu-snapdragon-4.4.0-1050.54~31655^2~224^2~18 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=4faeb86070c38c0df9f5a23c3f6acf5538492a33;p=mirror_ubuntu-artful-kernel.git mac80211: add beacon timestamp to beacon template in IBSS This patch adds a beacon timestamp to the beacon template used in IBSS mode. This way the underlying driver can update its TSF accordingly. According the spec station should adopt the highest TSF from an incoming beacons in the cell. Signed-off-by: Assaf Krauss Signed-off-by: Zhu Yi Signed-off-by: John W. Linville --- diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c index 1e4054b273dd..0a310d09ab07 100644 --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c @@ -2503,6 +2503,7 @@ static int ieee80211_sta_join_ibss(struct net_device *dev, memcpy(mgmt->bssid, ifsta->bssid, ETH_ALEN); mgmt->u.beacon.beacon_int = cpu_to_le16(local->hw.conf.beacon_int); + mgmt->u.beacon.timestamp = cpu_to_le64(bss->timestamp); mgmt->u.beacon.capab_info = cpu_to_le16(bss->capability); pos = skb_put(skb, 2 + ifsta->ssid_len);