diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-08-07 13:17:46 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-08-07 13:17:46 +0000 |
commit | 7f3a4257159dea8e7ef66d1a539dc6df708b8ed3 (patch) | |
tree | bcc69b5f4609f348fac49e2f59e210b29eaea783 /drivers/platform/x86/fujitsu-laptop.c | |
parent | Adding upstream version 6.9.12. (diff) | |
download | linux-7f3a4257159dea8e7ef66d1a539dc6df708b8ed3.tar.xz linux-7f3a4257159dea8e7ef66d1a539dc6df708b8ed3.zip |
Adding upstream version 6.10.3.upstream/6.10.3
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'drivers/platform/x86/fujitsu-laptop.c')
-rw-r--r-- | drivers/platform/x86/fujitsu-laptop.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/platform/x86/fujitsu-laptop.c b/drivers/platform/x86/fujitsu-laptop.c index 94480af494..968fc91bd5 100644 --- a/drivers/platform/x86/fujitsu-laptop.c +++ b/drivers/platform/x86/fujitsu-laptop.c @@ -386,11 +386,11 @@ static ssize_t lid_show(struct device *dev, struct device_attribute *attr, struct fujitsu_laptop *priv = dev_get_drvdata(dev); if (!(priv->flags_supported & FLAG_LID)) - return sprintf(buf, "unknown\n"); + return sysfs_emit(buf, "unknown\n"); if (priv->flags_state & FLAG_LID) - return sprintf(buf, "open\n"); + return sysfs_emit(buf, "open\n"); else - return sprintf(buf, "closed\n"); + return sysfs_emit(buf, "closed\n"); } static ssize_t dock_show(struct device *dev, struct device_attribute *attr, @@ -399,11 +399,11 @@ static ssize_t dock_show(struct device *dev, struct device_attribute *attr, struct fujitsu_laptop *priv = dev_get_drvdata(dev); if (!(priv->flags_supported & FLAG_DOCK)) - return sprintf(buf, "unknown\n"); + return sysfs_emit(buf, "unknown\n"); if (priv->flags_state & FLAG_DOCK) - return sprintf(buf, "docked\n"); + return sysfs_emit(buf, "docked\n"); else - return sprintf(buf, "undocked\n"); + return sysfs_emit(buf, "undocked\n"); } static ssize_t radios_show(struct device *dev, struct device_attribute *attr, @@ -412,11 +412,11 @@ static ssize_t radios_show(struct device *dev, struct device_attribute *attr, struct fujitsu_laptop *priv = dev_get_drvdata(dev); if (!(priv->flags_supported & FLAG_RFKILL)) - return sprintf(buf, "unknown\n"); + return sysfs_emit(buf, "unknown\n"); if (priv->flags_state & FLAG_RFKILL) - return sprintf(buf, "on\n"); + return sysfs_emit(buf, "on\n"); else - return sprintf(buf, "killed\n"); + return sysfs_emit(buf, "killed\n"); } static DEVICE_ATTR_RO(lid); |