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] [thread-next>] [day] [month] [year] [list]
Message-ID: <2024041536-simile-flatly-824a@gregkh>
Date: Mon, 15 Apr 2024 11:52:49 +0200
From: Greg KH <gregkh@...uxfoundation.org>
To: Bjørn Mork <bjorn@...k.no>
Cc: Oliver Neukum <oneukum@...e.com>,
	Aleksander Morgado <aleksandermj@...omium.org>,
	linux-usb@...r.kernel.org, linux@...ck-us.net,
	linux-kernel@...r.kernel.org, ejcaruso@...omium.org
Subject: Re: [PATCH] usb: cdc-wdm: close race between read and workqueue

On Mon, Apr 15, 2024 at 11:26:00AM +0200, Bjørn Mork wrote:
> Oliver Neukum <oneukum@...e.com> writes:
> > On 15.04.24 08:47, Bjørn Mork wrote:
> >
> >> urb from service_outstanding_interrupt(). That's why it was added. See
> >> the explanation Robert wrote when introducing it:
> >> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/drivers/usb/class/cdc-wdm.c?id=c1da59dad0ebd3f9bd238f3fff82b1f7ffda7829
> >
> > Well, the explanation is correct in that we must read
> > data available. However, if the RESPONDING flag is set
> > and the URB submitted, we are already doing so.
> 
> Sounds reasonable.  Except that the bug proves we didn't.
> 
> If you are right that service_outstanding_interrupt can race againts
> itself (and I don't doubt that), then I guess this could also happen
> between failure to submit the URB and clearing the flag?
> 
> >> As for the XMM behaviour: it's been a long time since I tried any of
> >> those, but AFAIR one the major differences compared to Qualcomm was the
> >> strict queue handling in the firmware.  This caused a number of problems
> >> where the cdc-wdm driver wanted to skip a message for some reason.  So
> >> I'm not surprised that a bug like this is triggered by one of those
> >> modems. That's probably the only thing they are good for :-)
> >
> > I am not sure where exactly the issue lies here. Suggestions for
> > debugging?
> 
> Nothing more than the obvious;  Get one of those modems and do some
> usbmon snooping.

So for now, should we just revert this problem commit?

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ