Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: USB serial problems
On Wed, Sep 21, 2016 at 08:46:50AM -0400, Greg Troxel wrote:
> dtyU0 is the right file. ttyU0 and dtyU0 are for the same device, but
> dty is a dialout device that does not block waiting for carrier detect,
> vs tty that by default blocks opening until CD is asserted. (Back when
> I was young, we had 300 baud modems, with dialin from terminals and
> dialout for uucp!)
Thanks for the explanation! I just found that com(4) points to tty(4)
which explains this, but ucom(4) (where I had looked before) doesn't.
> > At the same time, the USB keyboard and USB mouse stopped working,
> > without anything visible in dmesg.
> >
> > I wanted other processes to finish before rebooting, so I waited.
> >
> > 4 hours later I saw the following in the kernel log:
> > ehci_sync_hc: cv_timedwait() = 35
> >
> > 4 hours later I tried rebooting, but had to press the reset button,
> > 'shutdown -r' didn't work.
> >
> > Should I have used /dev/ttyU0 instead?
> >
> > I find it worrying that the USB mouse and keyboard stopped working
> > without any kernel messages, and that the processes hung unkillably.
>
> I think you are running into either
>
> really serious bugs in our kernel, or
>
> a broken device that is causing way more trouble than it should
>
>
> Did you remove the serial dongle? I have found that at times, pulling a
> troublesome USB device resolves things.
I just tried again, on a kernel with EHCI_DEBUG and UCOM_DEBUG.
The device seems to want 115200 baud, so I used
cu -s 115200 -l /dev/dtyU0
which showed some patterns when it worked, perhaps some self tests.
I booted into single-user mode and after enabling ehci and ucom debug,
I tried a couple of times to start cu, exit it (with "<ENTER>~."), and
power off/on the device again. After about the 5th try, the NetBSD
machine hung. There were no kernel messages when I unplugged or
replugged USB devices, and even the PS/2 keyboard that is attached
didn't work any longer. I didn't really know what to do with such a
stuck system, so I rebooted.
Any ideas what I should try next time?
> Did you try on a netbsd-7 system?
No, I'm only running -current on that machine, and the netbsd-7
machines I have are remote.
Thomas
Home |
Main Index |
Thread Index |
Old Index