OSDN Git Service

uacce: use sysfs_emit instead of sprintf
authorKai Ye <yekai13@huawei.com>
Mon, 6 Dec 2021 10:47:24 +0000 (18:47 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 21 Dec 2021 09:13:34 +0000 (10:13 +0100)
commit2d2802fb24de8cbacb4a2d6da2e002acc1c17143
tree181b1adc68f8de93679e73dbdfbde0ad06c4844e
parent909c648e03e8eda8eb72678b3e95042739d6eb71
uacce: use sysfs_emit instead of sprintf

Use the sysfs_emit to replace sprintf. sprintf may cause
output defect in sysfs content, it is better to use new
added sysfs_emit function which knows the size of the
temporary buffer.

Signed-off-by: Kai Ye <yekai13@huawei.com>
Link: https://lore.kernel.org/r/20211206104724.11559-1-yekai13@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/misc/uacce/uacce.c