We're tying to use CAN using Linux 22.214.171.124 and the SocketCan interface. Preliminary tests like sending / receiving with cansend / candump command line tools are running fine.
When we try to send more packets (i.e.48) in a loop, they are sent in a different order, not always the same. Receiving with candump on the same node and interface does not reveal the problem, because the local dump shows the correct order. Only using an external sniffer (which can be another i.mx53 board running candump) the issue becomes visible. Some packets are also sometimes lost.
If the packets are sent followed by a delay much longer than the transmission time, the sending order is preserved, but the throughput is in that case not acceptable. Trying to send 8..16 packets followed by a delay a little longer than the transmission time seemed to offer a workaround in a test program, but it failed in the production code (the packets are again reordered/lost).
I have attached a simple test program that exposes the problem.
Original Attachment has been moved to: i_mx53_FlexCan_bug.zip