lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aSSJh+jbqZ+E1LP6@duo.ucw.cz>
Date: Mon, 24 Nov 2025 17:36:23 +0100
From: Pavel Machek <pavel@....cz>
To: Naüm Jumpertz <n.jumpertz@...tonmail.com>
Cc: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>,
	"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>
Subject: Re: Oppo/Oneplus phones and usb3.0 incompatibility

Hi!

> Because of wrong device descriptor, certain oppo/oneplus phones, 
> like my oppo find x5, can't connect to linux computers using usb3 cables,
> the issue is also on other oppo/oneplus phones such as oneplus 9 pro, 
> starting from OxygenOs 13 in december 2022 
> link: https://xdaforums.com/t/connection-problems-to-a-computer-with-linux.4642402/
> The issue is present in kernel 6.17 but also in older versions.
> The connection correctly works using an usb2 cable.
> 
> The phone is detected as a USB SuperSpeed device but the device descriptor flag given is USB 2.0,
> so, according to dmesg, the kernel warm reset the phone and don't manage to establishes the connection, which is annoying:
> 
> [ 3537.701845] usb 2-2: new SuperSpeed USB device number 4 using xhci_hcd
> [ 3537.722594] usb 2-2: got a wrong device descriptor, warm reset device
> [ 3538.105960] usb 2-2: new SuperSpeed USB device number 5 using xhci_hcd
> [ 3538.126933] usb 2-2: got a wrong device descriptor, warm reset device
> [ 3538.313826] usb usb2-port2: attempt power cycle
> [ 3539.241985] usb 2-2: new SuperSpeed USB device number 6 using xhci_hcd
> [ 3539.262410] usb 2-2: got a wrong device descriptor, warm reset device
> [ 3539.646017] usb 2-2: new SuperSpeed USB device number 7 using xhci_hcd
> [ 3539.666993] usb 2-2: got a wrong device descriptor, warm reset device
> [ 3539.853713] usb usb2-port2: unable to enumerate USB device
> 
> The issue is due to oppo phones not being conformant to usb standard.
> Maybe the kernel should still establish the connection if warm resets fail, by counting fails or something,
> otherwise oppo phones will never manage to connect through usb3.0 cables, until oppo fixes it.
> 
> I'm not a dev, so my solution was just to disable the feature:

I'm afraid patch will not be acceptable like this, but you could be
able to put this behind some kind of blacklist.

Best regards,
								Pavel

>  drivers/usb/core/hub.c | 14 --------------
>  1 file changed, 14 deletions(-)
> 
> diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
> index 256fe8c86828..be28296b39de 100644
> --- a/drivers/usb/core/hub.c
> +++ b/drivers/usb/core/hub.c
> @@ -5186,20 +5186,6 @@ hub_port_init(struct usb_hub *hub, struct usb_device *udev, int port1,
>  		*dev_descr = *descr;
>  	kfree(descr);
>  
> -	/*
> -	 * Some superspeed devices have finished the link training process
> -	 * and attached to a superspeed hub port, but the device descriptor
> -	 * got from those devices show they aren't superspeed devices. Warm
> -	 * reset the port attached by the devices can fix them.
> -	 */
> -	if ((udev->speed >= USB_SPEED_SUPER) &&
> -			(le16_to_cpu(udev->descriptor.bcdUSB) < 0x0300)) {
> -		dev_err(&udev->dev, "got a wrong device descriptor, warm reset device\n");
> -		hub_port_reset(hub, port1, udev, HUB_BH_RESET_TIME, true);
> -		retval = -EINVAL;
> -		goto fail;
> -	}
> -
>  	usb_detect_quirks(udev);
>  
>  	if (le16_to_cpu(udev->descriptor.bcdUSB) >= 0x0201) {

-- 
I don't work for Nazis and criminals, and neither should you.
Boycott Putin, Trump, Netanyahu and Musk!

Download attachment "signature.asc" of type "application/pgp-signature" (196 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ