kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
From: sandro.stiller@elfin.de (Sandro Stiller)
To: kernelnewbies@lists.kernelnewbies.org
Subject: How to find a bug with lost network messages
Date: Tue, 2 Feb 2016 10:09:20 +0100	[thread overview]
Message-ID: <56B07240.8070409@elfin.de> (raw)

Hello,

I'm struggeling with a network driver (sllin[1]) which is not in the 
official kernel.
It has a lot in common with the slcan driver but is used for LIN networks.
The problem is, that sometimes messages sent to the network layer via 
netif_rx() don't arrive in all listening programs.

This is how the driver works:
1. The application sends CAN messages to the network interface
2. The driver forwards it to the UART (tty)
3. The UART receives the same message (single-wire connection, RX and TX 
connected) and sends it back to the network layer
4. The sending application receives the previously sent message and can 
check for transmission errors and appended LIN slave replies.

Sometimes the last point (4.) does not work after 10 - 40 seconds of 
transmission.
The application does not receive the message using a blocking read() on 
the socket, but other processes receive it (running candump on the 
interface). netif_rx() always returns 0.

If more programs are listening (running multiple instances of candump), 
the problem appears less often or never.
On my PC there is no problem, it occures on ARM only.
I'm using kernel 4.1.

Can you give me a hint where to search for the cause of this behaviour?

Thank you very much.

Sandro


[1]: https://github.com/sstiller/sllin/tree/master/sllin

             reply	other threads:[~2016-02-02  9:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-02  9:09 Sandro Stiller [this message]
2016-02-02 19:05 ` How to find a bug with lost network messages Arthur Pichlkostner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56B07240.8070409@elfin.de \
    --to=sandro.stiller@elfin.de \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).