mirror of
https://github.com/torvalds/linux.git
synced 2024-11-22 04:38:03 +00:00
s390/vmlogrdr: Switch over to sysfs_emit()
Per Documentation/filesystems/sysfs.rst, sysfs_emit() is preferred for presenting attributes to user space in sysfs. Convert the left-over uses in the char/vmlogrdr code. Signed-off-by: Mete Durlu <meted@linux.ibm.com> Reviewed-by: Heiko Carstens <hca@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
This commit is contained in:
parent
6a5ac284a8
commit
182d54671c
@ -531,7 +531,7 @@ static ssize_t vmlogrdr_autopurge_show(struct device *dev,
|
||||
char *buf)
|
||||
{
|
||||
struct vmlogrdr_priv_t *priv = dev_get_drvdata(dev);
|
||||
return sprintf(buf, "%u\n", priv->autopurge);
|
||||
return sysfs_emit(buf, "%u\n", priv->autopurge);
|
||||
}
|
||||
|
||||
|
||||
@ -605,7 +605,7 @@ static ssize_t vmlogrdr_autorecording_show(struct device *dev,
|
||||
char *buf)
|
||||
{
|
||||
struct vmlogrdr_priv_t *priv = dev_get_drvdata(dev);
|
||||
return sprintf(buf, "%u\n", priv->autorecording);
|
||||
return sysfs_emit(buf, "%u\n", priv->autorecording);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user