diff options
author | 2019-04-03 14:06:36 -0500 | |
---|---|---|
committer | 2019-05-07 16:52:39 +0300 | |
commit | 4f735cd73650d8136f8bd78dca8f61f361791622 (patch) | |
tree | 26956aded963dba6c7e8b510d5c77f714dc3eafc /tools/perf/scripts/python/export-to-postgresql.py | |
parent | ath10k: Use struct_size() helper (diff) | |
download | wireguard-linux-4f735cd73650d8136f8bd78dca8f61f361791622.tar.xz wireguard-linux-4f735cd73650d8136f8bd78dca8f61f361791622.zip |
ath10k: coredump: use struct_size() helper
Make use of the struct_size() helper instead of an open-coded version
in order to avoid any potential type mistakes, in particular in the
context in which this code is being used.
So, replace code of the following form:
sizeof(*ce_hdr) + CE_COUNT * sizeof(ce_hdr->entries[0])
with:
struct_size(ce_hdr, entries, CE_COUNT)
This code was detected with the help of Coccinelle.
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions