qcacmn: dp: Add support to update tsf timestamp in data packet

Add support to update tsf timestamp on driver entry and
exit in data packet. This helps debug latency issue in
XR usecases

Change-Id: I9c966c1b8cb09dc5eab6104fdad36c19a1d68045
CRs-Fixed: 3090108
Этот коммит содержится в:
Nirav Shah
2022-01-24 18:38:30 +05:30
коммит произвёл Madan Koyyalamudi
родитель 3e4c2182ff
Коммит 33528eaa41
7 изменённых файлов: 79 добавлений и 0 удалений

Просмотреть файл

@@ -23,6 +23,7 @@
#include <dp_mon.h>
#include <hal_li_tx.h>
#include <hal_li_rx.h>
#include <qdf_pkt_add_timestamp.h>
/* WBM2SW ring id for rx release */
#define WBM2SW_REL_ERR_RING_NUM 3
@@ -108,4 +109,39 @@ qdf_size_t dp_get_context_size_li(enum dp_context_type context_type);
qdf_size_t dp_mon_get_context_size_li(enum dp_context_type context_type);
#ifdef CONFIG_DP_PKT_ADD_TIMESTAMP
/**
* dp_pkt_add_timestamp() - add timestamp in data payload
*
* @vdev: dp vdev
* @index: index to decide offset in payload
* @time: timestamp to add in data payload
* @nbuf: network buffer
*
* Return: none
*/
void dp_pkt_add_timestamp(struct dp_vdev *vdev,
enum qdf_pkt_timestamp_index index, uint64_t time,
qdf_nbuf_t nbuf);
/**
* dp_pkt_get_timestamp() - get current system time
*
* @time: return current system time
*
* Return: none
*/
void dp_pkt_get_timestamp(uint64_t *time);
#else
static inline
void dp_pkt_add_timestamp(struct dp_vdev *vdev,
enum qdf_pkt_timestamp_index index, uint64_t time,
qdf_nbuf_t nbuf)
{
}
static inline
void dp_pkt_get_timestamp(uint64_t *time)
{
}
#endif
#endif