Skip to content

Commit

Permalink
ACPI / osl: Propagate actual error code for kstrtoul()
Browse files Browse the repository at this point in the history
There is no need to override the error code returned by kstrtoul().
Propagate it directly to the caller.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Andy Shevchenko authored and Rafael J. Wysocki committed Dec 6, 2016
1 parent 3e5de27 commit 5dcb9ca
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/acpi/osl.c
Original file line number Diff line number Diff line change
@@ -181,9 +181,7 @@ void acpi_os_vprintf(const char *fmt, va_list args)
static unsigned long acpi_rsdp;
static int __init setup_acpi_rsdp(char *arg)
{
if (kstrtoul(arg, 16, &acpi_rsdp))
return -EINVAL;
return 0;
return kstrtoul(arg, 16, &acpi_rsdp);
}
early_param("acpi_rsdp", setup_acpi_rsdp);
#endif

0 comments on commit 5dcb9ca

Please sign in to comment.