Skip to content

Commit 820c629

Browse files
bmorkgregkh
authored andcommitted
USB: cdc-wdm: avoid printing odd-looking "cdc-wdm-176" names
usb_register_dev() will change our .minor_base to 0 if CONFIG_USB_DYNAMIC_MINORS is set. And it usually is, of course. Use dev_name() to print the proper interface name instead Signed-off-by: Bjørn Mork <[email protected]> Acked-by: Oliver Neukum <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 7e3054a commit 820c629

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/usb/class/cdc-wdm.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -723,8 +723,7 @@ static int wdm_probe(struct usb_interface *intf, const struct usb_device_id *id)
723723
if (rv < 0)
724724
goto err2;
725725
else
726-
dev_info(&intf->dev, "cdc-wdm%d: USB WDM device\n",
727-
intf->minor - WDM_MINOR_BASE);
726+
dev_info(&intf->dev, "%s: USB WDM device\n", dev_name(intf->usb_dev));
728727
out:
729728
return rv;
730729
err2:

0 commit comments

Comments
 (0)