Skip to content

Commit 7113ac8

Browse files
Xuezhi Zhangandersson
authored andcommitted
rpmsg: convert sysfs snprintf to sysfs_emit
Fix the following coccicheck warning: drivers/rpmsg/qcom_glink_native.c:1677:8-16: WARNING: use scnprintf or sprintf Signed-off-by: Xuezhi Zhang <[email protected]> Signed-off-by: Bjorn Andersson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 6538258 commit 7113ac8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/rpmsg/qcom_glink_native.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1672,7 +1672,7 @@ static ssize_t rpmsg_name_show(struct device *dev,
16721672
if (ret < 0)
16731673
name = dev->of_node->name;
16741674

1675-
return snprintf(buf, RPMSG_NAME_SIZE, "%s\n", name);
1675+
return sysfs_emit(buf, "%s\n", name);
16761676
}
16771677
static DEVICE_ATTR_RO(rpmsg_name);
16781678

0 commit comments

Comments
 (0)