[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250109175200.GP7706@kernel.org>
Date: Thu, 9 Jan 2025 17:52:00 +0000
From: Simon Horman <horms@...nel.org>
To: Luo Jie <quic_luoj@...cinc.com>
Cc: 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>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Lei Wei <quic_leiwei@...cinc.com>,
Suruchi Agarwal <quic_suruchia@...cinc.com>,
Pavithra R <quic_pavir@...cinc.com>,
Jonathan Corbet <corbet@....net>, Kees Cook <kees@...nel.org>,
"Gustavo A. R. Silva" <gustavoars@...nel.org>,
Philipp Zabel <p.zabel@...gutronix.de>,
linux-arm-msm@...r.kernel.org, netdev@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-doc@...r.kernel.org, linux-hardening@...r.kernel.org,
quic_kkumarcs@...cinc.com, quic_linchen@...cinc.com,
srinivas.kandagatla@...aro.org, bartosz.golaszewski@...aro.org,
john@...ozen.org
Subject: Re: [PATCH net-next v2 07/14] net: ethernet: qualcomm: Initialize
PPE queue settings
On Wed, Jan 08, 2025 at 09:47:14PM +0800, Luo Jie wrote:
> Configure unicast and multicast hardware queues for the PPE
> ports to enable packet forwarding between the ports.
>
> Each PPE port is assigned with a range of queues. The queue ID
> selection for a packet is decided by the queue base and queue
> offset that is configured based on the internal priority and
> the RSS hash value of the packet.
>
> Signed-off-by: Luo Jie <quic_luoj@...cinc.com>
> ---
> drivers/net/ethernet/qualcomm/ppe/ppe_config.c | 357 ++++++++++++++++++++++++-
> drivers/net/ethernet/qualcomm/ppe/ppe_config.h | 63 +++++
> drivers/net/ethernet/qualcomm/ppe/ppe_regs.h | 21 ++
> 3 files changed, 440 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/qualcomm/ppe/ppe_config.c b/drivers/net/ethernet/qualcomm/ppe/ppe_config.c
...
> @@ -673,6 +701,111 @@ static struct ppe_scheduler_port_config ppe_port_sch_config[] = {
> },
> };
>
> +/* The scheduler resource is applied to each PPE port, The resource
> + * includes the unicast & multicast queues, flow nodes and DRR nodes.
> + */
> +static struct ppe_port_schedule_resource ppe_scheduler_res[] = {
> + { .ucastq_start = 0,
> + .ucastq_end = 63,
> + .mcastq_start = 256,
> + .ucastq_end = 271,
Hi Luo Jie,
This appears to duplicate the initialisation of .ucastq_end.
Should the line above initialise .mcastq_end instead?
Likewise for other elements of this array.
Flagged by W=1 builds with both clang-19 and gcc-14.
> + .flow_id_start = 0,
> + .flow_id_end = 0,
> + .l0node_start = 0,
> + .l0node_end = 7,
> + .l1node_start = 0,
> + .l1node_end = 0,
> + },
> + { .ucastq_start = 144,
> + .ucastq_end = 159,
> + .mcastq_start = 272,
> + .ucastq_end = 275,
> + .flow_id_start = 36,
> + .flow_id_end = 39,
> + .l0node_start = 48,
> + .l0node_end = 63,
> + .l1node_start = 8,
> + .l1node_end = 11,
> + },
...
> +};
...
Powered by blists - more mailing lists