From: Dmitry Shmidt Date: Mon, 13 Aug 2012 18:37:43 +0000 (-0700) Subject: net: wireless: bcmdhd: Use correct time from boot for TSF X-Git-Tag: firefly_0821_release~7613^2~67 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e15cb9927c7a8e16b4f95918d07d2e55f23adf6c;p=firefly-linux-kernel-4.4.55.git net: wireless: bcmdhd: Use correct time from boot for TSF Signed-off-by: Dmitry Shmidt --- diff --git a/drivers/net/wireless/bcmdhd/wl_cfg80211.c b/drivers/net/wireless/bcmdhd/wl_cfg80211.c index b10a5efff0ac..87d971a5e5dd 100644 --- a/drivers/net/wireless/bcmdhd/wl_cfg80211.c +++ b/drivers/net/wireless/bcmdhd/wl_cfg80211.c @@ -4753,11 +4753,11 @@ static s32 wl_inform_single_bss(struct wl_priv *wl, struct wl_bss_info *bi) signal = notif_bss_info->rssi * 100; if (!mgmt->u.probe_resp.timestamp) { - struct timeval tv; + struct timespec ts; - do_gettimeofday(&tv); - mgmt->u.probe_resp.timestamp = ((u64)tv.tv_sec * 1000000) - + tv.tv_usec; + get_monotonic_boottime(&ts); + mgmt->u.probe_resp.timestamp = ((u64)ts.tv_sec * 1000000) + + ts.tv_nsec / 1000; } cbss = cfg80211_inform_bss_frame(wiphy, channel, mgmt,