#include "core.h"
#if !defined(_TRACE_H_)
-static inline u32 ath10k_frm_hdr_len(void *buf)
+static inline u32 ath10k_frm_hdr_len(const void *buf)
{
- return ieee80211_hdrlen(((struct ieee80211_hdr *)buf)->frame_control);
+ const struct ieee80211_hdr *hdr = buf;
+
+ return ieee80211_hdrlen(hdr->frame_control);
}
#endif
);
TRACE_EVENT(ath10k_wmi_cmd,
- TP_PROTO(struct ath10k *ar, int id, void *buf, size_t buf_len, int ret),
+ TP_PROTO(struct ath10k *ar, int id, const void *buf, size_t buf_len,
+ int ret),
TP_ARGS(ar, id, buf, buf_len, ret),
);
TRACE_EVENT(ath10k_wmi_event,
- TP_PROTO(struct ath10k *ar, int id, void *buf, size_t buf_len),
+ TP_PROTO(struct ath10k *ar, int id, const void *buf, size_t buf_len),
TP_ARGS(ar, id, buf, buf_len),
);
TRACE_EVENT(ath10k_htt_stats,
- TP_PROTO(struct ath10k *ar, void *buf, size_t buf_len),
+ TP_PROTO(struct ath10k *ar, const void *buf, size_t buf_len),
TP_ARGS(ar, buf, buf_len),
);
TRACE_EVENT(ath10k_wmi_dbglog,
- TP_PROTO(struct ath10k *ar, void *buf, size_t buf_len),
+ TP_PROTO(struct ath10k *ar, const void *buf, size_t buf_len),
TP_ARGS(ar, buf, buf_len),
);
TRACE_EVENT(ath10k_htt_pktlog,
- TP_PROTO(struct ath10k *ar, void *buf, u16 buf_len),
+ TP_PROTO(struct ath10k *ar, const void *buf, u16 buf_len),
TP_ARGS(ar, buf, buf_len),
);
DECLARE_EVENT_CLASS(ath10k_hdr_event,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len),
);
DECLARE_EVENT_CLASS(ath10k_payload_event,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len),
);
DEFINE_EVENT(ath10k_hdr_event, ath10k_tx_hdr,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len)
);
DEFINE_EVENT(ath10k_payload_event, ath10k_tx_payload,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len)
);
DEFINE_EVENT(ath10k_hdr_event, ath10k_rx_hdr,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len)
);
DEFINE_EVENT(ath10k_payload_event, ath10k_rx_payload,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len)
);
TRACE_EVENT(ath10k_htt_rx_desc,
- TP_PROTO(struct ath10k *ar, void *data, size_t len),
+ TP_PROTO(struct ath10k *ar, const void *data, size_t len),
TP_ARGS(ar, data, len),