All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thierry Bultel <thierry.bultel@wanadoo.fr>
To: xenomai@xenomai.org
Subject: [Xenomai] Modified rtcan_virt driver
Date: Thu, 04 Oct 2012 14:15:59 +0200	[thread overview]
Message-ID: <506D7DFF.6040403@wanadoo.fr> (raw)

Hi,

The existing rtcan_virt driver simulates a single CAN bus, on which are 
N devices.
Sending to one dispatches the frame to all the others but the not to the 
sender.

This has several disadvantages:

- First, to run an application that uses 2 or more physical buses, it 
does not fit, because both devices would be linked together.
- Second, having N instantiated virtual devices is in some cases not 
necessary, because an application can open the
same device several times, and simulate many CAN nodes, on that single 
device.

Thus I have written another rtcan_virt driver, based on the original one.

Its behavior is as follows:

- It instantiates N rtcan devices, that are independent (no frame from 
one to another)
- Each virtual rtcan (rtcan0, rtcan1 ...) device has a matching peer 
(rtcan0s, rtcan1s ...)
('s' like 'slave' but I am opened to any other naming) another to 
communicate with.
That 'slave' device isautomatically created.
I say 'slave' in quotes because the word hides the symmetrical aspect, 
so it is likely unappropriate..

It is today fully tested, my question was if it could be of interest for 
the Xenomai mainline.
If Yes:
- some questions come, to my mind the most important one is if is a new 
driver, or a patch for the existing one,
to modify its behavior depending on a parameter. If it is a new one, 
what would be the appropriate name ?
- I would be happy to make it as a patch (not ready for that yet, and 
until the first questions are answered)

If No, I just apologize for the noise.

Cheers
Thierry

             reply	other threads:[~2012-10-04 12:15 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-04 12:15 Thierry Bultel [this message]
2012-10-04 12:36 ` [Xenomai] Modified rtcan_virt driver Gilles Chanteperdrix
2012-10-04 12:58   ` Thierry Bultel
2012-10-04 13:26     ` Gilles Chanteperdrix
2012-10-11  4:50       ` Jan Kiszka
2012-10-11  6:08         ` Thierry Bultel
2012-10-11  6:23           ` Jan Kiszka
2012-10-11  7:27             ` Thierry Bultel
2012-10-11  7:33               ` Jan Kiszka

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=506D7DFF.6040403@wanadoo.fr \
    --to=thierry.bultel@wanadoo.fr \
    --cc=xenomai@xenomai.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.