All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lorenzo Bianconi <lorenzo.bianconi@oss.qualcomm.com>
To: Maxime Chevallier <maxime.chevallier@bootlin.com>
Cc: "Andrew Lunn" <andrew+netdev@lunn.ch>,
	"Jakub Kicinski" <kuba@kernel.org>,
	davem@davemloft.net, "Eric Dumazet" <edumazet@google.com>,
	"Paolo Abeni" <pabeni@redhat.com>,
	"Simon Horman" <horms@kernel.org>,
	"Maxime Coquelin" <mcoquelin.stm32@gmail.com>,
	"Alexandre Torgue" <alexandre.torgue@foss.st.com>,
	"Russell King" <linux@armlinux.org.uk>,
	thomas.petazzoni@bootlin.com,
	"Alexis Lothoré" <alexis.lothore@bootlin.com>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH net-next] net: stmmac: selftests: Add missing endianness conversions
Date: Tue, 3 Nov 2026 16:09:22 +0100	[thread overview]
Message-ID: <aun5IpJsYPwrnBYB@lore-desk> (raw)
In-Reply-To: <20261103122249.951523-1-maxime.chevallier@bootlin.com>

[-- Attachment #1: Type: text/plain, Size: 2393 bytes --]

> The kbuild bot found some endianness issues in the stmmac ethtool
> selftests [1] let's address these.
> 
> In practice these missing conversions didn't cause any issue, as the
> masks / values on which the conversions were missing were either always
> 0 or ~0, so skipping the byte swaps lead to the same value being passed
> anyway.
> 
> [1]: https://lore.kernel.org/oe-kbuild-all/202611010511.Mk620DTd-lkp@intel.com/
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>

Reviewed-by: Lorenzo Bianconi <lorenzo.bianconi@oss.qualcomm.com>

> ---
> This isn't worth sending to net, I've dropped the Fixes / Reported-by /
> Closes tags, let me know if I should add'em back.
> 
> There are more of these endianness warnings in other places, but they
> require a bit more attention. This'll be addressed at a later point, I
> don't think we have many big-endian stmmac setups anyways.
> 
>  drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c
> index 40811df8f2b7..df696e2c1528 100644
> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c
> @@ -1216,7 +1216,7 @@ static int stmmac_test_rxp(struct stmmac_priv *priv)
>  	sel->offshift = 0;
>  	sel->keys[0].off = 6;
>  	sel->keys[0].val = htonl(0xdeadbeef);
> -	sel->keys[0].mask = ~0x0;
> +	sel->keys[0].mask = htonl(~0x0);
>  
>  	ret = stmmac_tc_setup_cls_u32(priv, priv, &cls_u32);
>  	if (ret)
> @@ -1463,8 +1463,8 @@ static int __stmmac_test_l3filt(struct stmmac_priv *priv, u32 dst, u32 src,
>  
>  	key.src = htonl(src);
>  	key.dst = htonl(dst);
> -	mask.src = src_mask;
> -	mask.dst = dst_mask;
> +	mask.src = htonl(src_mask);
> +	mask.dst = htonl(dst_mask);
>  
>  	cls->rule = rule;
>  
> @@ -1594,8 +1594,8 @@ static int __stmmac_test_l4filt(struct stmmac_priv *priv, u32 dst, u32 src,
>  	keys.key.dst = htons(dst);
>  	/* Match the full IP proto field */
>  	masks.bmask.ip_proto = 0xff;
> -	masks.mask.src = src_mask;
> -	masks.mask.dst = dst_mask;
> +	masks.mask.src = htons(src_mask);
> +	masks.mask.dst = htons(dst_mask);
>  
>  	cls->rule = rule;
>  
> -- 
> 2.56.0
> 
> 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

      parent reply	other threads:[~2026-11-03 15:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-03 12:22 [PATCH net-next] net: stmmac: selftests: Add missing endianness conversions Maxime Chevallier
2026-11-03 13:57 ` Nicolai Buchwitz
2026-11-03 15:09 ` Lorenzo Bianconi [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=aun5IpJsYPwrnBYB@lore-desk \
    --to=lorenzo.bianconi@oss.qualcomm.com \
    --cc=alexandre.torgue@foss.st.com \
    --cc=alexis.lothore@bootlin.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=thomas.petazzoni@bootlin.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 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.