Thread View: linux.kernel.netdev
1 messages
1 total messages
Started by Lorenzo Bianconi
Tue, 03 Nov 2026 15:09
Re: [PATCH net-next] net: stmmac: selftests: Add missing endianness conversions
Author: Lorenzo Bianconi
Date: Tue, 03 Nov 2026 15:09
Date: Tue, 03 Nov 2026 15:09
87 lines
18238 bytes
18238 bytes
--IxJjiVHShnjx8PxM Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable > The kbuild bot found some endianness issues in the stmmac ethtool > selftests [1] let's address these. >=20 > 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. >=20 > [1]: https://lore.kernel.org/oe-kbuild-all/202611010511.Mk620DTd-lkp@inte= l.com/ >=20 > 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. >=20 > 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. >=20 > drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) >=20 > diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_selftests.c b/dri= vers/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 =3D 0; > sel->keys[0].off =3D 6; > sel->keys[0].val =3D htonl(0xdeadbeef); > - sel->keys[0].mask =3D ~0x0; > + sel->keys[0].mask =3D htonl(~0x0); > =20 > ret =3D 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, > =20 > key.src =3D htonl(src); > key.dst =3D htonl(dst); > - mask.src =3D src_mask; > - mask.dst =3D dst_mask; > + mask.src =3D htonl(src_mask); > + mask.dst =3D htonl(dst_mask); > =20 > cls->rule =3D rule; > =20 > @@ -1594,8 +1594,8 @@ static int __stmmac_test_l4filt(struct stmmac_priv = *priv, u32 dst, u32 src, > keys.key.dst =3D htons(dst); > /* Match the full IP proto field */ > masks.bmask.ip_proto =3D 0xff; > - masks.mask.src =3D src_mask; > - masks.mask.dst =3D dst_mask; > + masks.mask.src =3D htons(src_mask); > + masks.mask.dst =3D htons(dst_mask); > =20 > cls->rule =3D rule; > =20 > --=20 > 2.56.0 >=20 >=20 --IxJjiVHShnjx8PxM Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQTquNwa3Txd3rGGn7Y6cBh0uS2trAUCaun5IgAKCRA6cBh0uS2t rEreAP9RquFj7WKKDysqBVQoJ6e0dVIsW1UM/4cQsoIBq2aelwD/T9/Pdxsxz96+ bqDDg/n0YBnH3cZXcJCfxoB/tOAA1g0= =hOaE -----END PGP SIGNATURE----- --IxJjiVHShnjx8PxM--
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads