mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 08:43:31 +00:00
drm/amdgpu: use sysfs_emit() to instead of scnprintf()
Replace the open-code with sysfs_emit() to simplify the code. Reviewed-by: Luben Tuikov <luben.tuikov@amd.com> Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
949933b0f3
commit
2cffcb6679
1 changed files with 1 additions and 1 deletions
|
@ -1267,7 +1267,7 @@ static ssize_t amdgpu_ras_sysfs_features_read(struct device *dev,
|
|||
struct amdgpu_ras *con =
|
||||
container_of(attr, struct amdgpu_ras, features_attr);
|
||||
|
||||
return scnprintf(buf, PAGE_SIZE, "feature mask: 0x%x\n", con->features);
|
||||
return sysfs_emit(buf, "feature mask: 0x%x\n", con->features);
|
||||
}
|
||||
|
||||
static void amdgpu_ras_sysfs_remove_bad_page_node(struct amdgpu_device *adev)
|
||||
|
|
Loading…
Add table
Reference in a new issue