Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 912f85e1 authored by Wolfram Sang's avatar Wolfram Sang Committed by David S. Miller
Browse files

net: can: usb: esd_usb2: don't print error when allocating urb fails



kmalloc will print enough information in case of failure.

Signed-off-by: default avatarWolfram Sang <wsa-dev@sang-engineering.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 87ced2f9
Loading
Loading
Loading
Loading
+0 −3
Original line number Original line Diff line number Diff line
@@ -558,8 +558,6 @@ static int esd_usb2_setup_rx_urbs(struct esd_usb2 *dev)
		/* create a URB, and a buffer for it */
		/* create a URB, and a buffer for it */
		urb = usb_alloc_urb(0, GFP_KERNEL);
		urb = usb_alloc_urb(0, GFP_KERNEL);
		if (!urb) {
		if (!urb) {
			dev_warn(dev->udev->dev.parent,
				 "No memory left for URBs\n");
			err = -ENOMEM;
			err = -ENOMEM;
			break;
			break;
		}
		}
@@ -730,7 +728,6 @@ static netdev_tx_t esd_usb2_start_xmit(struct sk_buff *skb,
	/* create a URB, and a buffer for it, and copy the data to the URB */
	/* create a URB, and a buffer for it, and copy the data to the URB */
	urb = usb_alloc_urb(0, GFP_ATOMIC);
	urb = usb_alloc_urb(0, GFP_ATOMIC);
	if (!urb) {
	if (!urb) {
		netdev_err(netdev, "No memory left for URBs\n");
		stats->tx_dropped++;
		stats->tx_dropped++;
		dev_kfree_skb(skb);
		dev_kfree_skb(skb);
		goto nourbmem;
		goto nourbmem;