Re: [Linuxptp-devel] [PATCH v6 00/11] Profile support for IEEE C37.238-2011 and IEEE C37.238-2017

2023-02-22 Thread Magnus Armholt via Linuxptp-devel
Hi, Could you please provide an example how to use linux vlan interfaces in order to live up to the required behaviour by the Power profile 2011 (receive 802.1Q tagged and untagged frames, send tagged frames - configurable VID, default 4). I tried to achieve this with linux vlan interfaces but

Re: [Linuxptp-devel] [PATCH v4 00/11] Profile support for IEEE C37.238-2011 and IEEE C37.238-2017

2023-01-30 Thread Magnus Armholt via Linuxptp-devel
Hi, Good work on adding power profile support. On a general level, power profile 2011 states that VLAN IDs should be used. "All IEEE C37.238 messages shall be mapped into IEEE 802.1Q-tagged Ethernet frames with configurable priority and configurable VLAN ID. The default priority shall be 4. The

Re: [Linuxptp-devel] [PATCH 1/1] Add configurable VLAN tags for Ethernet

2023-01-29 Thread Magnus Armholt via Linuxptp-devel
Hi, The linux VLAN interface was a good idea and we tried it. We are using the 1588 power profile 2011, and it states that the device should receive untagged frames and frames with the configured VLAN ID, (and send with the configured VLAN ID). This requirement to receive both untagged and confi

Re: [Linuxptp-devel] [PATCH] remove C99 style loop variable declarations

2022-11-17 Thread Magnus Armholt via Linuxptp-devel
Nothing to complain about the patch, thanks for looking after the code base! > LinuxPTP source still prefers to keep with the GNU C89 convention of > variables being at the top of the function. Newer versions of GCC have > begun defaulting to a newer C standard, which explains how these slipped in

Re: [Linuxptp-devel] [PATCH v5] Strip Parallel Redundancy Protocol (PRP) trailer

2022-09-19 Thread Magnus Armholt via Linuxptp-devel
Hi, Sorry to keep polling about this. Is there something more I can do for this patch, or is it just to wait? BR, Magnus Armholt > -Original Message- > From: Magnus Armholt via Linuxptp-devel de...@lists.sourceforge.net> > Sent: tiistai 30. elokuuta 2022 21.25 > To:

Re: [Linuxptp-devel] [PATCH v5] Strip Parallel Redundancy Protocol (PRP) trailer

2022-08-30 Thread Magnus Armholt via Linuxptp-devel
Hi, Any more review comments related to this patch or is there a chance it could be accepted? BR, Magnus Armholt > -Original Message- > From: Magnus Armholt > Sent: tiistai 9. elokuuta 2022 8.26 > To: linuxptp-devel@lists.sourceforge.net > Cc: Magnus Armholt > Subject: [PATCH v5] Stri

Re: [Linuxptp-devel] [PATCH 1/1 v3] Strip PRP trailer

2022-07-14 Thread Magnus Armholt via Linuxptp-devel
> > Is it necessary to return the padding length here? If I understand it > > correctly it's not specific to PRP. It's just the original Ethernet > > minimum length of 64 plus 6 bytes for the trailer. If you remove the > > padding_len variable, the function can be simplified a bit. > > > In my t

Re: [Linuxptp-devel] [PATCH 1/1 v3] Strip PRP trailer

2022-07-14 Thread Magnus Armholt via Linuxptp-devel
Hi, > Just some minor coding style issues. Please order the declarations by length > (reverse christmas tree) and write hdr as "*hdr" instead of > "* hdr". Thanks for pointing out the coding style, will fix it. > > Is it necessary to return the padding length here? If I understand it > correctl

Re: [Linuxptp-devel] [PATCH 1/1] Strip PRP trailer

2022-06-30 Thread Magnus Armholt via Linuxptp-devel
> > > > + unsigned short suffix_id = ntohs(*(unsigned short*)(ptr + > > > > + (cnt > > > > + - 2))); > > > > > > This seems to be parsing the frame from the end. Couldn't that > > > randomly match a non-PRP frame, even if you consider the length > > > check > > below? > > > > > > To me it would

Re: [Linuxptp-devel] [PATCH 1/1] Strip PRP trailer

2022-06-30 Thread Magnus Armholt via Linuxptp-devel
> > > + unsigned short suffix_id = ntohs(*(unsigned short*)(ptr + (cnt > > > + - 2))); > > > > This seems to be parsing the frame from the end. Couldn't that > > randomly match a non-PRP frame, even if you consider the length check > below? > > > > To me it would make more sense to start after

Re: [Linuxptp-devel] [PATCH 1/1] Strip PRP trailer

2022-06-29 Thread Magnus Armholt via Linuxptp-devel
Thanks for taking the time to review the patch! > > +static int has_prp_trailer(unsigned char *ptr, int cnt) { > > + if (cnt < PRP_TRAILER_LEN) > > + return -1; > > + //verify suffix first since it is the best identifier > > Please use C-style comments. > Will do > > +

[Linuxptp-devel] PATCH[1/1] Strip PRP trailer

2022-06-29 Thread Magnus Armholt via Linuxptp-devel
0001-Strip-PRP-trailer.patch Description: 0001-Strip-PRP-trailer.patch ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel