diff options
author | Axel Lin <axel.lin@gmail.com> | 2010-08-17 09:41:29 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-08-23 20:50:15 -0700 |
commit | 96f2a34d2cec71d59014be9ecd7a038435e88584 (patch) | |
tree | 12a030b3379f9b34a1df52fbff50ff64fdbfffc9 /drivers | |
parent | 0827a9ff2bbcbb03c33f1a6eb283fe051059482c (diff) | |
download | linux-96f2a34d2cec71d59014be9ecd7a038435e88584.tar.bz2 |
USB: r8a66597-udc: return -ENOMEM if kzalloc() fails
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/gadget/r8a66597-udc.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/gadget/r8a66597-udc.c b/drivers/usb/gadget/r8a66597-udc.c index 70a817842755..2456ccd9965e 100644 --- a/drivers/usb/gadget/r8a66597-udc.c +++ b/drivers/usb/gadget/r8a66597-udc.c @@ -1557,6 +1557,7 @@ static int __init r8a66597_probe(struct platform_device *pdev) /* initialize ucd */ r8a66597 = kzalloc(sizeof(struct r8a66597), GFP_KERNEL); if (r8a66597 == NULL) { + ret = -ENOMEM; printk(KERN_ERR "kzalloc error\n"); goto clean_up; } |