gpio: Fix gpio direction flags not getting set
GPIO direction flags are not getting set because an 'if' statement is the wrong way around. Cc: Stable <stable@vger.kernel.org> # 3.15+ Signed-off-by: Adrian Hunter <adrian.hunter@intel.com> Acked-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
Родитель
0f33be009b
Коммит
72f908c88c
|
@ -1674,7 +1674,7 @@ struct gpio_desc *__must_check __gpiod_get_index(struct device *dev,
|
|||
set_bit(FLAG_OPEN_SOURCE, &desc->flags);
|
||||
|
||||
/* No particular flag request, return here... */
|
||||
if (flags & GPIOD_FLAGS_BIT_DIR_SET)
|
||||
if (!(flags & GPIOD_FLAGS_BIT_DIR_SET))
|
||||
return desc;
|
||||
|
||||
/* Process flags */
|
||||
|
|
Загрузка…
Ссылка в новой задаче