mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-02 16:44:10 +08:00
ACPI: sysfs: use sysfs_emit() to instead of scnprintf()
Replace scnprintf() with sysfs_emit() to simplify the code. Reported-by: Zeal Robot <zealci@zte.com.cn> Signed-off-by: Xu Panda <xu.panda@zte.com.cn> Signed-off-by: Yang Yang <yang.yang29@zte.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
4612c7f138
commit
82d08d61e3
@ -198,7 +198,7 @@ static int param_set_trace_method_name(const char *val,
|
||||
|
||||
static int param_get_trace_method_name(char *buffer, const struct kernel_param *kp)
|
||||
{
|
||||
return scnprintf(buffer, PAGE_SIZE, "%s\n", acpi_gbl_trace_method_name);
|
||||
return sysfs_emit(buffer, "%s\n", acpi_gbl_trace_method_name);
|
||||
}
|
||||
|
||||
static const struct kernel_param_ops param_ops_trace_method = {
|
||||
|
Loading…
Reference in New Issue
Block a user