qcacmn: Add wake time absolute tsf value field in nudge command

In nudge response, FW sends wake TSF value. Implement changes
to handle wake TSF values.

Change-Id: I941f1dbab3ba83bba1f0b8e03b83d1b81365c7dd
CRs-Fixed: 2847181
This commit is contained in:
Rajasekaran Kalidoss
2020-12-07 20:30:39 +05:30
committed by snandini
parent 48dee39efb
commit 9fc1e5f34b
2 changed files with 12 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2018-2020 The Linux Foundation. All rights reserved. * Copyright (c) 2018-2021 The Linux Foundation. All rights reserved.
* *
* Permission to use, copy, modify, and/or distribute this software for * Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the * any purpose with or without fee is hereby granted, provided that the
@@ -519,12 +519,16 @@ enum WMI_HOST_NUDGE_TWT_STATUS {
* @peer_macaddr: Peer mac address * @peer_macaddr: Peer mac address
* @dialog_id: TWT dialog ID * @dialog_id: TWT dialog ID
* @status: refer to WMI_HOST_PAUSE_TWT_STATUS * @status: refer to WMI_HOST_PAUSE_TWT_STATUS
* @next_twt_tsf_us_lo: TSF lower bits (31:0) of next wake time
* @next_twt_tsf_us_hi: TSF higher bits (32:63) of next wake time
*/ */
struct wmi_twt_nudge_dialog_complete_event_param { struct wmi_twt_nudge_dialog_complete_event_param {
uint32_t vdev_id; uint32_t vdev_id;
uint8_t peer_macaddr[QDF_MAC_ADDR_SIZE]; uint8_t peer_macaddr[QDF_MAC_ADDR_SIZE];
uint32_t dialog_id; uint32_t dialog_id;
enum WMI_HOST_NUDGE_TWT_STATUS status; enum WMI_HOST_NUDGE_TWT_STATUS status;
uint32_t next_twt_tsf_us_lo;
uint32_t next_twt_tsf_us_hi;
}; };
/** /**

View File

@@ -1,5 +1,5 @@
/* /*
* Copyright (c) 2018-2020 The Linux Foundation. All rights reserved. * Copyright (c) 2018-2021 The Linux Foundation. All rights reserved.
* *
* Permission to use, copy, modify, and/or distribute this software for * Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the * any purpose with or without fee is hereby granted, provided that the
@@ -703,6 +703,12 @@ static QDF_STATUS extract_twt_nudge_dialog_comp_event_tlv(
WMI_MAC_ADDR_TO_CHAR_ARRAY(&ev->peer_macaddr, params->peer_macaddr); WMI_MAC_ADDR_TO_CHAR_ARRAY(&ev->peer_macaddr, params->peer_macaddr);
params->status = wmi_twt_nudge_status_to_host_twt_status(ev->status); params->status = wmi_twt_nudge_status_to_host_twt_status(ev->status);
params->dialog_id = ev->dialog_id; params->dialog_id = ev->dialog_id;
params->next_twt_tsf_us_lo = ev->sp_tsf_us_lo;
params->next_twt_tsf_us_hi = ev->sp_tsf_us_hi;
wmi_debug("vdev_id: %d dialog_id: %d tsf hi : %x tsf lo: %x",
params->vdev_id, params->dialog_id,
params->next_twt_tsf_us_hi, params->next_twt_tsf_us_lo);
return QDF_STATUS_SUCCESS; return QDF_STATUS_SUCCESS;
} }