From: Harsh Kumar Date: Fri, 31 May 2013 15:30:42 +0000 (+0530) Subject: Staging: winbond: Check for unsuccessful allocation immediately X-Git-Tag: omap-for-v3.11/fixes-for-merge-window~76^2~320 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d3d472b6e57e55132a0c2a048e3b18759c73ee7b;p=pandora-kernel.git Staging: winbond: Check for unsuccessful allocation immediately Check to see if allocation by kzalloc() or usb_alloc_urb() was unsuccessful immediately after the allocation. Exit from the function can be right at that point in case of allocation failure. This avoids unnecessary use of usb_alloc_urb() & usb_free_urb() if kzalloc() returns NULL. Also, makes the code better structured & easier to understand. Signed-off-by: Harsh Kumar Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed