USB: r8a66597-udc: return -ENOMEM if kzalloc() fails
PATCH 1/1 USB: r8a66597-udc: return -ENOMEM if kzalloc() fails
Signed-off-by Axel Lin <[email protected]>
--- drivers/usb/gadget/r8a66597-udc.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/usb/gadget/r8a66597-udc.c +1 -0
@@ -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; }
Signature · 1 line
1.7.2