From mboxrd@z Thu Jan 1 00:00:00 1970 From: Oliver Hartkopp Subject: Re: ti hecc rx frames out of order Date: Sat, 10 Dec 2016 15:11:41 +0100 Message-ID: <0b6dc834-db5b-a8e3-1461-f97c7c79ad44@hartkopp.net> References: <1579A5A5423CC14B827884B535F8E951349421F6@SSCOXCHG2.spray.com> <08de827f-0d1b-4523-0ed9-f0979345de87@hartkopp.net> <1579A5A5423CC14B827884B535F8E95134942564@SSCOXCHG2.spray.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mo4-p00-ob.smtp.rzone.de ([81.169.146.216]:12652 "EHLO mo4-p00-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752278AbcLJOLw (ORCPT ); Sat, 10 Dec 2016 09:11:52 -0500 In-Reply-To: <1579A5A5423CC14B827884B535F8E95134942564@SSCOXCHG2.spray.com> Sender: linux-can-owner@vger.kernel.org List-ID: To: "Grim, Dennis" , "linux-can@vger.kernel.org" On 12/07/2016 05:55 PM, Grim, Dennis wrote: >>> When running canfdtest on a TI AM3517 HECC, frames randomly appear out of >> order. >>> >>> "can-utils" is current (cloned this week from github) >>> >>> Linux kernel is 3.19.0. >> >> (..) >> >>> From Peak PCAN-View: >> >>> 99904) 594366.8 Rx 0077 8 F3 F4 F5 F6 F7 F8 F9 FA >>> 99905) 594367.3 Rx 0078 8 F2 F3 F4 F5 F6 F7 F8 F9 >>> 99906) 594367.8 Rx 0078 8 F3 F4 F5 F6 F7 F8 F9 FA >>> 99907) 594368.3 Rx 0077 8 F4 F5 F6 F7 F8 F9 FA FB >>> 99908) 594368.7 Rx 0078 8 F1 F2 F3 F4 F5 F6 F7 F8 NOTE: this line >> is out of order >>> 99909) 594369.2 Rx 0077 8 F5 F6 F7 F8 F9 FA FB FC >>> 99910) 594369.7 Rx 0078 8 F4 F5 F6 F7 F8 F9 FA FB >>> 99911) 594370.2 Rx 0077 8 F6 F7 F8 F9 FA FB FC FD >> >> Please correct me if I'm wrong, but when you can see this out-of-order issue on a >> different host with a different tool: >> >> Doesn't this lead to the question of a TX out-of-order instead of a RX out-of- >> order?? >> >> Regards, >> Oliver >> > > Thank you Oliver for your reply. > > Pardon me for not providing a clearer description of the issue. > > I believe that it is RX out-of-order. > > Peak PCAN-View is a Windows application that can be used to monitor CAN bus activity. > > When run as a host, the can-utils canfdtest application generates CAN frames with a fixed ID and with data byte values that monotonically increase by one on each successive frame. The lines marked with an * in the PCAN-View output below are frames generated by the host. Note that the data byte values increment monotonically from one frame to the next. > > 99893) 594360.7 Rx 0077 8 ED EE EF F0 F1 F2 F3 F4 * > 99894) 594361.1 Rx 0078 8 EC ED EE EF F0 F1 F2 F3 > 99895) 594361.6 Rx 0077 8 EE EF F0 F1 F2 F3 F4 F5 * > 99896) 594362.1 Rx 0078 8 ED EE EF F0 F1 F2 F3 F4 > 99897) 594362.5 Rx 0078 8 EE EF F0 F1 F2 F3 F4 F5 > 99898) 594363.0 Rx 0078 8 EF F0 F1 F2 F3 F4 F5 F6 > 99899) 594363.5 Rx 0077 8 EF F0 F1 F2 F3 F4 F5 F6 * > 99900) 594363.9 Rx 0077 8 F0 F1 F2 F3 F4 F5 F6 F7 * > 99901) 594364.4 Rx 0078 8 F0 F1 F2 F3 F4 F5 F6 F7 > 99902) 594364.9 Rx 0077 8 F1 F2 F3 F4 F5 F6 F7 F8 * > 99903) 594365.8 Rx 0077 8 F2 F3 F4 F5 F6 F7 F8 F9 * > 99904) 594366.8 Rx 0077 8 F3 F4 F5 F6 F7 F8 F9 FA * > 99905) 594367.3 Rx 0078 8 F2 F3 F4 F5 F6 F7 F8 F9 > 99906) 594367.8 Rx 0078 8 F3 F4 F5 F6 F7 F8 F9 FA > 99907) 594368.3 Rx 0077 8 F4 F5 F6 F7 F8 F9 FA FB * > 99908) 594368.7 Rx 0078 8 F1 F2 F3 F4 F5 F6 F7 F8 > 99909) 594369.2 Rx 0077 8 F5 F6 F7 F8 F9 FA FB FC * > 99910) 594369.7 Rx 0078 8 F4 F5 F6 F7 F8 F9 FA FB > 99911) 594370.2 Rx 0077 8 F6 F7 F8 F9 FA FB FC FD * > > When run as a device under test (DUT), the can-utils canfdtest application simply receives CAN frames and (optionally) outputs them to the console then increments the ID and each data byte value by one and sends them. Note that in the canfdtest DUT output below (for frames received from the canfdtest host) lines appear in order except for the line marked with *. > > 0077: [8] ed ee ef f0 f1 f2 f3 f4 > 0077: [8] ee ef f0 f1 f2 f3 f4 f5 > 0077: [8] ef f0 f1 f2 f3 f4 f5 f6 > 0077: [8] f1 f2 f3 f4 f5 f6 f7 f8 > 0077: [8] f2 f3 f4 f5 f6 f7 f8 f9 > 0077: [8] f0 f1 f2 f3 f4 f5 f6 f7 * > 0077: [8] f3 f4 f5 f6 f7 f8 f9 fa > 0077: [8] f4 f5 f6 f7 f8 f9 fa fb > 0077: [8] f5 f6 f7 f8 f9 fa fb fc > > Since the frames were sent in order by the canfdtest host but reported out of order by the canfdtest DUT, it seems that it is an RX issue. > > I have been away for a few days but plan to investigate the issue now. > > Any help with this issue would be most welcome. Hi Dennis, can you check whether this idea helps you in your setup: http://marc.info/?l=linux-can&m=148007442317274&w=2 Regards, Oliver