Re: [PATCH net-next v3] net: qrtr: fix endian handling of confirm_rx field

From: Simon Horman

Date: Fri Mar 27 2026 - 05:51:34 EST


On Thu, Mar 26, 2026 at 08:17:52AM +0100, Alexander Wilhelm wrote:
> Convert confirm_rx to little endian when enqueueing and convert it back on
> receive. This fixes control flow on big endian hosts, little endian is
> unaffected.
>
> On transmit, store confirm_rx as __le32 using cpu_to_le32(). On receive,
> apply le32_to_cpu() before using the value. !! ensures the value is 0 or 1
> in native endianness, so the conversion isn’t strictly required here, but
> it is kept for consistency and clarity.
>
> Reviewed-by: Manivannan Sadhasivam <mani@xxxxxxxxxx>
> Signed-off-by: Alexander Wilhelm <alexander.wilhelm@xxxxxxxxxxxx>
> ---
> Changes in v3:
> - Rebase on latest net-next tree
> - Remove "Fixes" tag
> - Link to v2: https://lore.kernel.org/r/20260324-b4-qrtr-fix-confirm_rx-on-big-endian-v2-1-674fb3f4865b@xxxxxxxxxxxx
>
> Changes in v2:
> - Rebase on latest net tree
> - Improve commit message
> - Link to v1: https://lore.kernel.org/r/20260320-qrtr-fix-confirm_rx-on-big-endian-v1-1-e1a337dc1a38@xxxxxxxxxxxx

Thanks for the updates.

Reviewed-by: Simon Horman <horms@xxxxxxxxxx>