From: Oliver Hartkopp <socketcan@hartkopp.net>
To: Aleksander Morgado <aleksander@aleksander.es>
Cc: Marc Kleine-Budde <mkl@pengutronix.de>,
Marek Vasut <marex@denx.de>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Wolfgang Grandegger <wg@grandegger.com>,
Andrew Lunn <andrew@lunn.ch>,
Andrey Vostrikov <andrey.vostrikov@cogentembedded.com>
Subject: Re: [RFC][PATCH] net: arinc429: Add ARINC-429 stack
Date: Mon, 02 Nov 2015 20:55:33 +0100 [thread overview]
Message-ID: <5637BFB5.6070706@hartkopp.net> (raw)
In-Reply-To: <CAAP7ucKOzP=HX4qJPhLN0c8nBHpCfzskBxtO09=K7HLLu_iT2w@mail.gmail.com>
On 11/02/2015 08:41 PM, Aleksander Morgado wrote:
> On Mon, Nov 2, 2015 at 12:14 PM, Oliver Hartkopp <socketcan@hartkopp.net> wrote:
>>
>> What about defining some overlay data structure to map ARINC-429 frames into
>> CAN frames?
>>
>> E.g. we could write the ARINC 32 bit data completely into data[0..3] and
>> additionally copy the 8 bit label information (or should it better be 10 bit
>> including the Source/Destination Identifiers?) additionally into the can_id.
>
> Note that the only bits which are always treated as non-data are the 8
> label bits (well, and the parity bit #31). The 2 SDI bits (#8, #9) may
> be used as data bits when a high resolution is needed, like Lat/Long
> encoded in binary words 310 and 311. I wouldn't make any assumption on
> what's on those 2 bits; i.e. they're not always "source/destination".
>
You definitely know these details better than me. That's why I'm asking.
Would hosting the 32 bit in the struct can_frame.data and just the 8 bit label
in struct can_frame.can_id offer the functionality you need?
Besides the arinc429_frame struct
struct arinc429_frame {
__u8 label; /* 8 bit label */
__u8 data[3]; /* Up-to 23 bits are valid. */
};
everything else roughly looks like copy&paste from PF_CAN with renaming.
So when we can fit the arinc frames into CAN frames and re-use the existing
CAN infrastructure - we are almost done.
Regards,
Oliver
prev parent reply other threads:[~2015-11-02 20:01 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-01 23:16 [RFC][PATCH] net: arinc429: Add ARINC-429 stack Marek Vasut
2015-11-02 9:47 ` Marc Kleine-Budde
2015-11-02 11:14 ` Oliver Hartkopp
2015-11-02 18:16 ` Marek Vasut
2015-11-02 20:15 ` Vostrikov Andrey
2015-11-02 20:25 ` Marek Vasut
2015-11-03 10:36 ` Aleksander Morgado
2015-11-03 11:36 ` Marc Kleine-Budde
2015-11-03 15:06 ` Aleksander Morgado
2015-11-03 15:15 ` Marc Kleine-Budde
2015-11-03 16:10 ` Aleksander Morgado
2015-11-03 17:32 ` Oliver Hartkopp
2015-11-03 17:41 ` Marek Vasut
2015-11-03 18:03 ` Oliver Hartkopp
2015-11-03 19:19 ` Marek Vasut
2015-11-03 19:28 ` Oliver Hartkopp
2015-11-03 21:43 ` Marek Vasut
2015-11-04 9:34 ` Aleksander Morgado
2015-11-04 13:54 ` Marek Vasut
2015-11-04 15:03 ` Vostrikov Andrey
2015-11-04 15:07 ` Marek Vasut
2015-11-04 15:18 ` Vostrikov Andrey
2015-11-04 15:19 ` Aleksander Morgado
2015-11-04 15:33 ` Marek Vasut
2015-11-04 15:45 ` Aleksander Morgado
2015-11-10 16:15 ` Marek Vasut
2015-11-18 16:38 ` Aleksander Morgado
2015-11-18 16:41 ` Marek Vasut
2015-11-03 20:26 ` Vostrikov Andrey
2015-11-03 21:24 ` Oliver Hartkopp
2015-11-03 21:41 ` Marek Vasut
2015-11-04 10:44 ` Oliver Hartkopp
2015-11-03 21:52 ` Vostrikov Andrey
2015-11-03 15:19 ` Marek Vasut
2015-11-03 16:18 ` Aleksander Morgado
2015-11-03 16:56 ` Aleksander Morgado
2015-11-03 17:33 ` Marek Vasut
2015-11-03 20:15 ` Vostrikov Andrey
2015-11-04 9:31 ` Aleksander Morgado
2015-11-03 16:47 ` Aleksander Morgado
2015-11-03 17:37 ` Marek Vasut
2015-11-03 17:01 ` Oliver Hartkopp
2015-11-04 9:51 ` Aleksander Morgado
2015-11-03 21:44 ` Marek Vasut
2015-11-02 19:41 ` Aleksander Morgado
2015-11-02 19:55 ` Oliver Hartkopp [this message]
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=5637BFB5.6070706@hartkopp.net \
--to=socketcan@hartkopp.net \
--cc=aleksander@aleksander.es \
--cc=andrew@lunn.ch \
--cc=andrey.vostrikov@cogentembedded.com \
--cc=davem@davemloft.net \
--cc=marex@denx.de \
--cc=mkl@pengutronix.de \
--cc=netdev@vger.kernel.org \
--cc=wg@grandegger.com \
/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).