diff options
author | Rasmus Villemoes <[email protected]> | 2018-10-26 23:22:59 +0200 |
---|---|---|
committer | David S. Miller <[email protected]> | 2018-10-28 19:20:06 -0700 |
commit | 822c5f7341366bef761e5e49f05bb8b1b0afccee (patch) | |
tree | 89d222508b83b263a0d481bcc715124882af1b31 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 0fe5119e267f3e3d8ac206895f5922195ec55a8a (diff) |
ptp: drop redundant kasprintf() to create worker name
Building with -Wformat-nonliteral, gcc complains
drivers/ptp/ptp_clock.c: In function ‘ptp_clock_register’:
drivers/ptp/ptp_clock.c:239:26: warning: format not a string literal and no format arguments [-Wformat-nonliteral]
worker_name : info->name);
kthread_create_worker takes fmt+varargs to set the name of the
worker, and that happens with a vsnprintf() to a stack buffer (that is
then copied into task_comm). So there's no reason not to just pass
"ptp%d", ptp->index to kthread_create_worker() and avoid the
intermediate worker_name variable.
Signed-off-by: Rasmus Villemoes <[email protected]>
Acked-by: Richard Cochran <[email protected]>
Reviewed-by: Kees Cook <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions