diff options
author | Gustavo A. R. Silva <gustavo@embeddedor.com> | 2019-04-03 22:06:36 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2019-05-07 16:52:39 +0300 |
commit | 4f735cd73650d8136f8bd78dca8f61f361791622 (patch) | |
tree | 26956aded963dba6c7e8b510d5c77f714dc3eafc /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | 35b50e70df272a4b4d313b7042e386445c98f06d (diff) | |
download | linux-4f735cd73650d8136f8bd78dca8f61f361791622.tar.xz |
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/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions