]> www.infradead.org Git - users/jedix/linux-maple.git/commit
platform/x86: thinkpad_acpi: Fix coccinelle warnings
authorYe Guojin <ye.guojin@zte.com.cn>
Mon, 18 Oct 2021 09:17:50 +0000 (09:17 +0000)
committerHans de Goede <hdegoede@redhat.com>
Tue, 19 Oct 2021 15:18:37 +0000 (17:18 +0200)
commit33ce79be2784bb7c327ef0f3be184936238c91d3
tree6ae9b635c4d527fa586a1b22714a67152cade50f
parent2d5b0755b754fcb39598df87b3a8656a569e9979
platform/x86: thinkpad_acpi: Fix coccinelle warnings

coccicheck complains about the use of snprintf() in sysfs show
functions:

WARNING  use scnprintf or sprintf

Use sysfs_emit instead of scnprintf or sprintf makes more sense.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Ye Guojin <ye.guojin@zte.com.cn>
Link: https://lore.kernel.org/r/20211018091750.858826-1-ye.guojin@zte.com.cn
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/thinkpad_acpi.c