From: Johan Hovold Date: Mon, 18 Aug 2025 23:08:38 +0000 (-0400) Subject: USB: cdc-acm: do not log successful probe on later errors X-Git-Tag: v5.10.241~90 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=70bc2b56c3ced12e6e8ed72880a032df307c521e;p=thirdparty%2Fkernel%2Fstable.git USB: cdc-acm: do not log successful probe on later errors [ Upstream commit 79579411826647fd573dbe301c4d933bc90e4be7 ] Do not log the successful-probe message until the tty device has been registered. Signed-off-by: Johan Hovold Link: https://lore.kernel.org/r/20210322155318.9837-9-johan@kernel.org Signed-off-by: Greg Kroah-Hartman Stable-dep-of: 64690a90cd7c ("cdc-acm: fix race between initial clearing halt and open") Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c index 571b70b9231cf..50d4392013022 100644 --- a/drivers/usb/class/cdc-acm.c +++ b/drivers/usb/class/cdc-acm.c @@ -1510,8 +1510,6 @@ skip_countries: acm->nb_index = 0; acm->nb_size = 0; - dev_info(&intf->dev, "ttyACM%d: USB ACM device\n", minor); - acm->line.dwDTERate = cpu_to_le32(9600); acm->line.bDataBits = 8; acm_set_line(acm, &acm->line); @@ -1531,6 +1529,8 @@ skip_countries: usb_clear_halt(usb_dev, acm->out); } + dev_info(&intf->dev, "ttyACM%d: USB ACM device\n", minor); + return 0; alloc_fail6: if (!acm->combined_interfaces) {