]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
spi: tle62x0: Add newline to sysfs attribute output
authorZhongqiu Han <zhongqiu.han@oss.qualcomm.com>
Thu, 30 Oct 2025 12:47:55 +0000 (20:47 +0800)
committerMark Brown <broonie@kernel.org>
Thu, 30 Oct 2025 13:08:11 +0000 (13:08 +0000)
Append a newline to the sysfs_emit() output in tle62x0_gpio_show. This
aligns with common kernel conventions and improves readability for
userspace tools that expect newline-terminated values.

Signed-off-by: Zhongqiu Han <zhongqiu.han@oss.qualcomm.com>
Link: https://patch.msgid.link/20251030124755.1828434-1-zhongqiu.han@oss.qualcomm.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-tle62x0.c

index a565352f63815fc8d8698047c5793545ddd6f1bc..663c0136d119b2e7fd99f9b9a0d3c16183dae9d9 100644 (file)
@@ -141,7 +141,7 @@ static ssize_t tle62x0_gpio_show(struct device *dev,
        value = (st->gpio_state >> gpio_num) & 1;
        mutex_unlock(&st->lock);
 
-       return sysfs_emit(buf, "%d", value);
+       return sysfs_emit(buf, "%d\n", value);
 }
 
 static ssize_t tle62x0_gpio_store(struct device *dev,