From 9477ab2b2ae098423af2ed4fb1f7b864abfc14fc Mon Sep 17 00:00:00 2001 From: Hans-Christian Egtvedt Date: Tue, 24 Mar 2009 15:45:21 +0100 Subject: avr32: use gpio_is_valid() to check USBA vbus_pin I/O line This patch will use gpio_is_valid() to check the vbus_pin I/O line. Signed-off-by: Hans-Christian Egtvedt Signed-off-by: Haavard Skinnemoen --- arch/avr32/mach-at32ap/at32ap700x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/avr32') diff --git a/arch/avr32/mach-at32ap/at32ap700x.c b/arch/avr32/mach-at32ap/at32ap700x.c index 3fbfd1e32a9e..402cae8f9205 100644 --- a/arch/avr32/mach-at32ap/at32ap700x.c +++ b/arch/avr32/mach-at32ap/at32ap700x.c @@ -1753,7 +1753,7 @@ at32_add_device_usba(unsigned int id, struct usba_platform_data *data) if (platform_device_add_data(pdev, data, sizeof(usba_data))) goto out_free_pdev; - if (data->vbus_pin >= 0) + if (gpio_is_valid(data->vbus_pin)) at32_select_gpio(data->vbus_pin, 0); usba0_pclk.dev = &pdev->dev; -- cgit v1.2.3