On Wed, Jun 29, 2022 at 02:01:18PM +0200, Oliver Neukum wrote: > You have something in the buffer, which the tty layer will try to send. > > > In userspace the hang happens at a call to close() on the TTY, and using > > The tty layer is supposed to wait a defined amount of time > if a tty needs to drain. > This amount (among many other things) is traditionally > set with the TIOCSSERIAL ioctl() > > > perf and ftrace it looks to be spending a lot of time poisoning urbs in > > acm_port_shutdown. > > That is a bit odd. > > > - Is this a bug? > > Maybe, but unlikely. If and only it takes much more time than the > termios say. > > > - Can I reduce the timeout somehow? > > ioctl() TIOCSSERIAL. If that does not work, > it's a bug. This sounds like exactly what's happening. Next time I hit this issue I'll see if changing closing_wait fixes this. > HTH > Oliver