From 5e8254061e7e4f761e3bf9aa39fccc8719e019df Mon Sep 17 00:00:00 2001 From: Adwait Nayak Date: Fri, 14 Aug 2020 18:51:33 +0530 Subject: [PATCH] qcacmn: Modify data type of timestamp The 'timestamp' field in CFR meta data corresponds to TSF at the reception of PPDU in micro second unit. To capture timestamp for one shot, periodic and repetitive channel capture, this field is being used. case 1: For one shot and periodic capture, the clock used for timestamp is private to the target and not visible to host. So it is being passed by FW to host and the placeholder being exchanged between Host and target is of 32 bit. case 2: In case of repetitive channel capture, the timestamp is being populated from the received PPDU, which is 64bit. To accommodate the timestamp, in both above cases, change the data type to u_int64_t from u_int32_t Change-Id: Ifa612bd97dc4f597368daefcd4224b84f2484c03 CRs-Fixed: 2751408 --- target_if/cfr/src/target_if_cfr_enh.c | 2 +- umac/cfr/dispatcher/inc/wlan_cfr_utils_api.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/target_if/cfr/src/target_if_cfr_enh.c b/target_if/cfr/src/target_if_cfr_enh.c index d26227a3b21c..b34198f33c5e 100644 --- a/target_if/cfr/src/target_if_cfr_enh.c +++ b/target_if/cfr/src/target_if_cfr_enh.c @@ -349,7 +349,7 @@ static void dump_metadata(struct csi_cfr_header *header, uint32_t cookie) "cfr_capture_type = %d\n" "sts_count = %d\n" "num_rx_chain = %d\n" - "timestamp = 0x%x\n" + "timestamp = %llu\n" "length = %d\n" "is_mu_ppdu = %d\n" "num_users = %d\n", diff --git a/umac/cfr/dispatcher/inc/wlan_cfr_utils_api.h b/umac/cfr/dispatcher/inc/wlan_cfr_utils_api.h index daabef6c307d..090db0137576 100644 --- a/umac/cfr/dispatcher/inc/wlan_cfr_utils_api.h +++ b/umac/cfr/dispatcher/inc/wlan_cfr_utils_api.h @@ -177,7 +177,7 @@ struct cfr_metadata_version_3 { u_int8_t capture_type; /* cfr_capture_type */ u_int8_t sts_count; u_int8_t num_rx_chain; - u_int32_t timestamp; + u_int64_t timestamp; u_int32_t length; u_int8_t is_mu_ppdu; u_int8_t num_mu_users;