aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/sbs.c
diff options
context:
space:
mode:
authorLuis G.F <luisgf@luisgf.es>2014-02-10 05:36:42 -0500
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-02-13 09:18:37 -0500
commit32a90512055b300587cceead9127f41e311e01aa (patch)
treee880ad3c435f732a102069ea035a3fe53521b4ae /drivers/acpi/sbs.c
parentb28a960c42fcd9cfc987441fa6d1c1a471f0f9ed (diff)
ACPI / SBS: Fix incorrect sscanf() string
Fix incorrect sscanf() string in function acpi_battery_alarm_store(). Signed-off-by: Luis G.F <luisgf@luisgf.es> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/sbs.c')
-rw-r--r--drivers/acpi/sbs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/acpi/sbs.c b/drivers/acpi/sbs.c
index d465ae6cdd00..02d0c21b807e 100644
--- a/drivers/acpi/sbs.c
+++ b/drivers/acpi/sbs.c
@@ -450,7 +450,7 @@ static ssize_t acpi_battery_alarm_store(struct device *dev,
450{ 450{
451 unsigned long x; 451 unsigned long x;
452 struct acpi_battery *battery = to_acpi_battery(dev_get_drvdata(dev)); 452 struct acpi_battery *battery = to_acpi_battery(dev_get_drvdata(dev));
453 if (sscanf(buf, "%ld\n", &x) == 1) 453 if (sscanf(buf, "%lu\n", &x) == 1)
454 battery->alarm_capacity = x / 454 battery->alarm_capacity = x /
455 (1000 * acpi_battery_scale(battery)); 455 (1000 * acpi_battery_scale(battery));
456 if (battery->present) 456 if (battery->present)