linux-can.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Erik Flodin <erik@flodin.me>
To: linux-can@vger.kernel.org
Subject: CAN_RAW_RECV_OWN_MSGS and filters
Date: Wed, 14 Apr 2021 21:22:50 +0200	[thread overview]
Message-ID: <CAAMKmofMUGrXPynSQXcvFCvB3nJXYrvosv63Aq4tcxyFok=rgA@mail.gmail.com> (raw)

Hi all,

I've been using a raw CAN socket with RECV_OWN_MSGS enabled to get a
transmission confirmation when a frame has been sent. Today when I
tried to enable filters to limit what I receive to only those frames
that I'm interested in I noticed that the filters also affected
reception of my own frames. So in order to receive all frames that I
send I must also add a filter that matches all frames that I send.

Is this the expected behavior? I can see why it works the way it does,
but I had expected that setting the RECV_OWN_MSGS flag would give me
all frames sent on the socket. Is there a way to get my expected
behavior without having to set a filter that matches all frames that I
plan to send?

// Erik

             reply	other threads:[~2021-04-14 19:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-14 19:22 Erik Flodin [this message]
2021-04-15  8:32 ` CAN_RAW_RECV_OWN_MSGS and filters Marc Kleine-Budde
2021-04-20 19:40   ` Erik Flodin

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='CAAMKmofMUGrXPynSQXcvFCvB3nJXYrvosv63Aq4tcxyFok=rgA@mail.gmail.com' \
    --to=erik@flodin.me \
    --cc=linux-can@vger.kernel.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).