diff options
| author | Kenneth Lee <[email protected]> | 2022-08-06 22:16:56 -0700 |
|---|---|---|
| committer | Marc Kleine-Budde <[email protected]> | 2022-09-05 22:00:42 +0200 |
| commit | 00784da3e6b8c1f0e58d813272503d014de8f64b (patch) | |
| tree | 0c5e466b3e53662bac649c3387fb3d49bd0803de /tools/perf/scripts/python/event_analyzing_sample.py | |
| parent | ddbbed25309f1cd0079e5b099748568842a5ec2b (diff) | |
can: kvaser_usb: kvaser_usb_hydra: Use kzalloc for allocating only one element
Use kzalloc(...) rather than kcalloc(1, ...) since because the number of
elements we are specifying in this case is 1, kzalloc would accomplish the
same thing and we can simplify. Also refactor how we calculate the sizeof()
as checkstyle for kzalloc() prefers using the variable we are assigning
to versus the type of that variable for calculating the size to allocate.
Signed-off-by: Kenneth Lee <[email protected]>
Link: https://lore.kernel.org/all/[email protected]
Signed-off-by: Marc Kleine-Budde <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/event_analyzing_sample.py')
0 files changed, 0 insertions, 0 deletions