greybus: arche-apb: Replace gpio_is_valid() with gpio < 0 checks
authorViresh Kumar <viresh.kumar@linaro.org>
Mon, 11 Jan 2016 05:59:10 +0000 (11:29 +0530)
committerGreg Kroah-Hartman <gregkh@google.com>
Mon, 11 Jan 2016 23:58:01 +0000 (15:58 -0800)
commit7541c1a1c6b0e5531545c400e27b8aee2ba71610
tree3bec2da03288bc32bba4151b73f89895ef5c3a10
parent977ff250755f4ae01ef50e98d792fabebb199c34
greybus: arche-apb: Replace gpio_is_valid() with gpio < 0 checks

There can be no invalid values in the DTS. The actual pin numbers are
assigned by gpiolib when the gpio controller is registered.

And so a simple 'gpio < 0' is enough instead of gpio_is_valid() which
also checks for 'gpio < ARCH_NR_GPIOS'.

This will make the usage of of_get_named_gpio() similar with how it is
done in arche-platform driver.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Reviewed-by: Vaibhav Hiremath <vaibhav.hiremath@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/arche-apb-ctrl.c