I'm running uCLinux and have a device connected to the RX line of one of my 16450-compatible UARTs. When my device is initialized (through another mechanism, not the serial port), the device sends about 16 bytes (at 9600-E-8-2) to the RX line, verified by an o'scope.
The problem I'm seeing is that a read() will not return the received data until I transmit a byte. I modified the serial driver to return immediately in uart_tx_chars() to try get filling the FIFO out of the picture. Doing that and transmitting a byte in my application (the byte did not transmit, as shown by the scope) allowed the read() to work, whether the read() occurred 1 second later or 5 minutes later.
I first saw this with my app, but tip (I tap a key and the data shows up) shows the same thing, so I don't think it's an initialization problem. I'm combing through the driver now, but does this condition look familiar to anyone? Any comments or suggestions would be appreciated.
Thanks.