提交 72f908c8 编写于 作者: A Adrian Hunter 提交者: Linus Walleij

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: NAdrian Hunter <adrian.hunter@intel.com>
Acked-by: NAlexandre Courbot <acourbot@nvidia.com>
Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
上级 0f33be00
无相关合并请求
...@@ -1674,7 +1674,7 @@ struct gpio_desc *__must_check __gpiod_get_index(struct device *dev, ...@@ -1674,7 +1674,7 @@ struct gpio_desc *__must_check __gpiod_get_index(struct device *dev,
set_bit(FLAG_OPEN_SOURCE, &desc->flags); set_bit(FLAG_OPEN_SOURCE, &desc->flags);
/* No particular flag request, return here... */ /* No particular flag request, return here... */
if (flags & GPIOD_FLAGS_BIT_DIR_SET) if (!(flags & GPIOD_FLAGS_BIT_DIR_SET))
return desc; return desc;
/* Process flags */ /* Process flags */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册
反馈
建议
客服 返回
顶部