Skip to content

Commit

Permalink
usb: hso: no complaint about kmalloc failure
Browse files Browse the repository at this point in the history
If this fails, kmalloc() will print a report including
a stack trace. There is no need for a separate complaint.

Signed-off-by: Oliver Neukum <oneukum@suse.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Oliver Neukum authored and David S. Miller committed Aug 6, 2020
1 parent 5fcfb6d commit 11c5f6d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions drivers/net/usb/hso.c
Original file line number Diff line number Diff line change
Expand Up @@ -2465,10 +2465,9 @@ static void hso_create_rfkill(struct hso_device *hso_dev,
&interface_to_usbdev(interface)->dev,
RFKILL_TYPE_WWAN,
&hso_rfkill_ops, hso_dev);
if (!hso_net->rfkill) {
dev_err(dev, "%s - Out of memory\n", __func__);
if (!hso_net->rfkill)
return;
}

if (rfkill_register(hso_net->rfkill) < 0) {
rfkill_destroy(hso_net->rfkill);
hso_net->rfkill = NULL;
Expand Down

0 comments on commit 11c5f6d

Please sign in to comment.