Just return an error upon failure. Signed-off-by: Oliver Neukum <oneu...@suse.com> --- drivers/net/usb/kaweth.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/drivers/net/usb/kaweth.c b/drivers/net/usb/kaweth.c index 37bf715..3cd6906 100644 --- a/drivers/net/usb/kaweth.c +++ b/drivers/net/usb/kaweth.c @@ -1049,6 +1049,8 @@ static int kaweth_probe( /* Download the firmware */ dev_info(dev, "Downloading firmware...\n"); kaweth->firmware_buf = (__u8 *)__get_free_page(GFP_KERNEL); + if (!kaweth->firmware_buf) + return -ENOMEM; if ((result = kaweth_download_firmware(kaweth, "kaweth/new_code.bin", 100, -- 2.1.4 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html