提交 96f2a34d 编写于 作者: A Axel Lin 提交者: Greg Kroah-Hartman

USB: r8a66597-udc: return -ENOMEM if kzalloc() fails

Signed-off-by: NAxel Lin <axel.lin@gmail.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 0827a9ff
......@@ -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;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册