Hello all, I am trying to use the serial ports of the iMX28 in a design that is closely based on the iMX28 EVK. The ltib builds: Linux Latest 184.108.40.206-571-gcca29a0-svn42278 #55 PREEMPT Tue Sep 4 15:03:16 EST 2012 armv5tejl GNU/Linux The particular application has a continuous stream of data at 9600 baud. I want to process about 150 bytes at a time, it doesn't mater how much exactly. I am opening the port like: iohw_serial = open(serialport,O_RDWR, O_NOCTTY | O_NONBLOCK | O_ASYNC /* | O_NOATIME */); Using the termios call I am setting VMIN=150, VTIME=0 and expecting the read() to return with about 150 bytes at a time. I compile the same code for the host linux and for the iMX28. The read() is passed a buffer of 1024 bytes. Under linux it returns about 150 to 168 characters at a time. On the iMX28 platform it waits 4 seconds and returns four buffers of 1024 bytes then waits another 4 seconds and so on. It seems that the low level drivers are taking the VMIN=150,VTIME=0 as if it was VMIN=1,VTIME=1. I.E. extending the timeout on each character and only returning when the driver's internal 4k buffer is full. I've spent today looking through the kernel and drivers but I find it to hard to follow. I cannot find where the termios c_cc[VMIN] (or VTIME) setting is used, so I can't begin to look at the drivers to see if there's a problem there. Has anyone else had such a problems with the serial port? Does anyone know where VMIN/VTIME is implemented in the kernel/drivers?
Original Attachment has been moved to: 4-main.c