summaryrefslogtreecommitdiff
path: root/sound/soc/intel/skylake
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2022-08-01 20:01:05 +0300
committerMark Brown <broonie@kernel.org>2022-08-15 03:19:48 +0300
commit11af2b1e33e8c9e72ddf14cd61f9494f34e06c40 (patch)
tree3ced937ed48d2a95ac9213c5174a83d792c6e1d8 /sound/soc/intel/skylake
parent7ae8d8ea9427b6fb1ed04b02faf31ad5e3a6de8b (diff)
downloadlinux-11af2b1e33e8c9e72ddf14cd61f9494f34e06c40.tar.xz
ASoC: Intel: skylake: Replace sprintf() with sysfs_emit()
For sysfs outputs, it's safer to use a new helper, sysfs_emit(), instead of the raw sprintf() & co. This patch replaces those usages straightforwardly with a new helper, sysfs_emit(). Signed-off-by: Takashi Iwai <tiwai@suse.de> Acked-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220801170108.26340-6-tiwai@suse.de Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/skylake')
-rw-r--r--sound/soc/intel/skylake/skl-nhlt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/intel/skylake/skl-nhlt.c b/sound/soc/intel/skylake/skl-nhlt.c
index deb7b820325e..e617b4c335a4 100644
--- a/sound/soc/intel/skylake/skl-nhlt.c
+++ b/sound/soc/intel/skylake/skl-nhlt.c
@@ -61,7 +61,7 @@ static ssize_t platform_id_show(struct device *dev,
nhlt->header.oem_revision);
skl_nhlt_trim_space(platform_id);
- return sprintf(buf, "%s\n", platform_id);
+ return sysfs_emit(buf, "%s\n", platform_id);
}
static DEVICE_ATTR_RO(platform_id);