projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b652336
)
gpio: mockup: don't return magic numbers from probe()
author
Bartosz Golaszewski
<brgl@bgdev.pl>
Fri, 9 Jun 2017 11:41:29 +0000
(13:41 +0200)
committer
Linus Walleij
<linus.walleij@linaro.org>
Tue, 20 Jun 2017 07:18:59 +0000
(09:18 +0200)
When the requested number of GPIO lines is 0, return -EINVAL, not
-1 which is -EPERM.
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/gpio/gpio-mockup.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/gpio/gpio-mockup.c
b/drivers/gpio/gpio-mockup.c
index 0cb6cbacc069b39c0ede1fc1b02fa039a18f057d..ab2d38e491bc1f6109bfa2585796072164a61c5d 100644
(file)
--- a/
drivers/gpio/gpio-mockup.c
+++ b/
drivers/gpio/gpio-mockup.c
@@
-369,7
+369,7
@@
static int gpio_mockup_probe(struct platform_device *pdev)
ret = gpio_mockup_add(dev, &chips[i],
chip_name, base, ngpio);
} else {
- ret = -
1
;
+ ret = -
EINVAL
;
}
if (ret) {