提交 1bbd28d2 编写于 作者: S Simon Glass 提交者: Anatolij Gustschin

Add gpio_request() to asm-generic header

This function should also be part of the GPIO API, so add it.
Signed-off-by: NSimon Glass <sjg@chromium.org>
上级 3ab270d5
......@@ -94,4 +94,13 @@ int gpio_get_value(unsigned gpio);
*/
int gpio_set_value(unsigned gpio, int value);
/**
* Request a gpio. This should be called before any of the other functions
* are used on this gpio.
*
* @param gp GPIO number
* @param label User label for this GPIO
* @return 0 if ok, -1 on error
*/
int gpio_request(unsigned gpio, const char *label);
#endif /* _ASM_GENERIC_GPIO_H_ */
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册