Skip to content

Commit 28c6a39

Browse files
David CohenH. Peter Anvin
authored andcommitted
x86, intel-mid: Return proper error code from get_gpio_by_name()
This patch cleans up get_gpio_by_name() to return an error code instead of hardcoded -1. Signed-off-by: David Cohen <david.a.cohen@linux.intel.com> Link: http://lkml.kernel.org/r/1389913624-9149-4-git-send-email-david.a.cohen@linux.intel.com Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
1 parent a957a14 commit 28c6a39

File tree

1 file changed

+1
-1
lines changed
  • arch/x86/platform/intel-mid

1 file changed

+1
-1
lines changed

arch/x86/platform/intel-mid/sfi.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ int get_gpio_by_name(const char *name)
224224
if (!strncmp(name, pentry->pin_name, SFI_NAME_LEN))
225225
return pentry->pin_no;
226226
}
227-
return -1;
227+
return -EINVAL;
228228
}
229229

230230
void __init intel_scu_device_register(struct platform_device *pdev)

0 commit comments

Comments
 (0)