aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/ether.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/gadget/ether.c')
-rw-r--r--drivers/usb/gadget/ether.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/usb/gadget/ether.c b/drivers/usb/gadget/ether.c
index a3376739a81..593e23507b1 100644
--- a/drivers/usb/gadget/ether.c
+++ b/drivers/usb/gadget/ether.c
@@ -1723,7 +1723,8 @@ rx_submit (struct eth_dev *dev, struct usb_request *req, gfp_t gfp_flags)
size += sizeof (struct rndis_packet_msg_type);
size -= size % dev->out_ep->maxpacket;
- if ((skb = alloc_skb (size + NET_IP_ALIGN, gfp_flags)) == 0) {
+ skb = alloc_skb(size + NET_IP_ALIGN, gfp_flags);
+ if (skb == NULL) {
DEBUG (dev, "no rx skb\n");
goto enomem;
}