提交 8d12c32c 编写于 作者: S Stelian Pop 提交者: Haavard Skinnemoen

atmel_usba_udc: Kill GPIO_PIN_NONE

GPIO_PIN_NONE should no longer be used. Replace it with a simple
test against negative values.

This is a transitional patch, waiting for gpio_is_valid() to be
merged at which point the tests should be revisited.
Signed-off-by: NStelian Pop <stelian@popies.net>
Acked-by: NDavid Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: NHaavard Skinnemoen <hskinnemoen@atmel.com>
上级 7a242471
......@@ -1937,7 +1937,7 @@ static int __init usba_udc_probe(struct platform_device *pdev)
goto err_device_add;
}
if (pdata && pdata->vbus_pin != GPIO_PIN_NONE) {
if (pdata && pdata->vbus_pin >= 0) {
if (!gpio_request(pdata->vbus_pin, "atmel_usba_udc")) {
udc->vbus_pin = pdata->vbus_pin;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册