Re: SELECT() returns 1 But FIONREAD says (Input/output error)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Robert Hancock wrote:

It's because you haven't done anything to handle the error which is still persisting. Likely the only thing sane you can do in this case is close the fd and try to reopen it later.

This seems to be true, but not for what you might think.

It appears that if u plug the USB/serial device back into the usb-hub, the code creates a /dev/ttyUSB1 ( if you have not yet closed the disconnected /dev/ttyUSB0. ) When you do close /dev/ttyUSB0, then the device is erased from the /dev directory.

Now /dev/ttyUSB1 is the device. And /dev/ttyUSB0 disappeared. This does not seem proper. As now the program has no idea or capability to re-open the GPS device.

I have been informed that this was an approved kernel feature. Is this suppose to happen? Or was it an unintended consequence?
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux