lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID:
 <BN8PR03MB5073B710F5040EAC06595AE2B4B42@BN8PR03MB5073.namprd03.prod.outlook.com>
Date: Wed, 9 Apr 2025 03:12:53 +0000
From: "Ng, Boon Khai" <boon.khai.ng@...era.com>
To: Andrew Lunn <andrew@...n.ch>
CC: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	"linux-stm32@...md-mailman.stormreply.com"
	<linux-stm32@...md-mailman.stormreply.com>,
	"linux-arm-kernel@...ts.infradead.org"
	<linux-arm-kernel@...ts.infradead.org>, "linux-kernel@...r.kernel.org"
	<linux-kernel@...r.kernel.org>, "bpf@...r.kernel.org" <bpf@...r.kernel.org>,
	Andrew Lunn <andrew+netdev@...n.ch>, "David S . Miller"
	<davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski
	<kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, Maxime Coquelin
	<mcoquelin.stm32@...il.com>, Alexandre Torgue <alexandre.torgue@...s.st.com>,
	Russell King <linux@...linux.org.uk>, Alexei Starovoitov <ast@...nel.org>,
	Daniel Borkmann <daniel@...earbox.net>, Jesper Dangaard Brouer
	<hawk@...nel.org>, John Fastabend <john.fastabend@...il.com>, "Gerlach,
 Matthew" <matthew.gerlach@...era.com>, "Ang, Tien Sung"
	<tien.sung.ang@...era.com>, "Tham, Mun Yew" <mun.yew.tham@...era.com>, "G
 Thomas, Rohan" <rohan.g.thomas@...era.com>
Subject: RE: [PATCH net-next v3 2/2] net: stmmac: dwxgmac2: Add support for
 HW-accelerated VLAN stripping

> This appears to be identical to dwmac4_wrback_get_rx_vlan_tci() ?
> 
> Can it be moved into the shared code, or am i missing something?
> 
>         Andrew

Hi Andrew thanks for the quick response.

For the dwmac4 IP it has the following format at the 
Receive Normal Descriptor 0 (RDES0)

           31                                                                                                0
              ------------------------------------- -----------------------------------
RDES0 |   Inner VLAN TAG [31:16]   | Outer VLAN TAG [31:16   |
              ------------------------------------- -----------------------------------

While for dwxgmac2 IP it has the following format at the RDES0
Depending on the Tunneled Frame bit (TNP)

For Non-Tunneled Frame (TNP=0)
           31                                                                                                0
              ------------------------------------- -----------------------------------
RDES0 |   Inner VLAN TAG [31:16 ]  | Outer VLAN TAG [31:16]   |
              ------------------------------------- -----------------------------------

For Tunneled Frame (TNP=1)
           31                                        8 7                          3 2                  0
              -------------------------------- ----------------------- ----------------
RDES0 |   VNID/VSID                    |    Reserved         | OL2L3         |
              -------------------------------- ----------------------- ----------------

While the logic for handling Tunneled Frame and Non-Tunneled
Frame is not yet implemented in the 
dwxgmac2_wrback_get_rx_vlan_tci() function, I believe it is
prudent to maintain separate functions within their respective
descriptor driver files, (dwxgmac2_descs.c and dwmac4_descs.c)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ