From f1096fd358a4156f425ea700dcfab1c02c325ef7 Mon Sep 17 00:00:00 2001 From: Alan Chen Date: Mon, 11 Nov 2019 09:39:06 -0800 Subject: [PATCH] qcacld-3.0: Replace calls to get_monotonic_boottime() with qdf wrapper Some functions have been calling get_monotonic_bootime() directly, which is now obsolete, having been replaced with ktime_get_boottime(). Change calls to get_monotonic_boottime() with qdf_get_monotonic_boottime(), which has now been updated to call ktime_get_boottime(). Change-Id: I9ce4bf2104077b6aacf841416997acb6f64b2841 CRs-Fixed: 2564544 --- core/hdd/src/wlan_hdd_cfg80211.c | 5 +---- core/hdd/src/wlan_hdd_ext_scan.c | 4 +--- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index eb3adf199c4f..e068a1866ce0 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -17503,7 +17503,6 @@ wlan_hdd_inform_bss_frame(struct hdd_adapter *adapter, uint32_t i; struct cfg80211_bss *bss_status = NULL; struct hdd_context *hdd_ctx; - struct timespec ts; struct hdd_config *cfg_param; struct wlan_cfg80211_inform_bss bss_data = {0}; @@ -17541,9 +17540,7 @@ wlan_hdd_inform_bss_frame(struct hdd_adapter *adapter, /* Android does not want the timestamp from the frame. * Instead it wants a monotonic increasing value */ - get_monotonic_boottime(&ts); - bss_data.mgmt->u.probe_resp.timestamp = - ((u64) ts.tv_sec * 1000000) + (ts.tv_nsec / 1000); + bss_data.mgmt->u.probe_resp.timestamp = qdf_get_monotonic_boottime(); bss_data.mgmt->u.probe_resp.beacon_int = bss_desc->beaconInterval; bss_data.mgmt->u.probe_resp.capab_info = bss_desc->capabilityInfo; diff --git a/core/hdd/src/wlan_hdd_ext_scan.c b/core/hdd/src/wlan_hdd_ext_scan.c index f23c7bea3efc..3b38f83f8359 100644 --- a/core/hdd/src/wlan_hdd_ext_scan.c +++ b/core/hdd/src/wlan_hdd_ext_scan.c @@ -731,7 +731,6 @@ wlan_hdd_cfg80211_extscan_full_scan_result_event(struct hdd_context *hdd_ctx, data) { struct sk_buff *skb; - struct timespec ts; struct hdd_ext_scan_context *context; int flags = cds_get_gfp_flags(); @@ -767,8 +766,7 @@ wlan_hdd_cfg80211_extscan_full_scan_result_event(struct hdd_context *hdd_ctx, * Android does not want the time stamp from the frame. * Instead it wants a monotonic increasing value since boot */ - get_monotonic_boottime(&ts); - data->ap.ts = ((u64)ts.tv_sec * 1000000) + (ts.tv_nsec / 1000); + data->ap.ts = qdf_get_monotonic_boottime(); hdd_debug("Req Id %u More Data %u", data->requestId, data->moreData);