lkml.org 
[lkml]   [2011]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [34-longterm 251/260] USB: atmel_usba_udc: force vbus_pin at -EINVAL when gpio_request failled
On 02:19 Sun 02 Jan     , Paul Gortmaker wrote:
> From: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
>
> commit 969affff54702785330de553b790372e261e93f9 upstream.
>
> to ensure gpio_is_valid return false
>
> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> ---
> drivers/usb/gadget/atmel_usba_udc.c | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/usb/gadget/atmel_usba_udc.c b/drivers/usb/gadget/atmel_usba_udc.c
> index 75a256f..8fd88e1 100644
> --- a/drivers/usb/gadget/atmel_usba_udc.c
> +++ b/drivers/usb/gadget/atmel_usba_udc.c
> @@ -2015,6 +2015,9 @@ static int __init usba_udc_probe(struct platform_device *pdev)
> } else {
> disable_irq(gpio_to_irq(udc->vbus_pin));
> }
> + } else {
> + /* gpio_request fail so use -EINVAL for gpio_is_valid */
> + ubc->vbus_pin = -EINVAL;
there is a typo here
please change to
udc->vbus_pin = -EINVAL;

Best Regards,
J.


\
 
 \ /
  Last update: 2011-01-05 20:07    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site