From: Roger Quadros <rogerq@kernel.org>
To: Simon Horman <horms@kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Siddharth Vadapalli <s-vadapalli@ti.com>,
Nathan Chancellor <nathan@kernel.org>,
Nick Desaulniers <ndesaulniers@google.com>,
Bill Wendling <morbo@google.com>,
Justin Stitt <justinstitt@google.com>
Cc: netdev@vger.kernel.org, linux-omap@vger.kernel.org, llvm@lists.linux.dev
Subject: Re: [PATCH net-next 2/3] net: ethernet: ti: am65-cpsw: Use __be64 type for id_temp
Date: Thu, 12 Sep 2024 10:10:00 +0300 [thread overview]
Message-ID: <27c12575-e670-4355-8d12-d5b544ec16f2@kernel.org> (raw)
In-Reply-To: <20240910-ti-warn-v1-2-afd1e404abbe@kernel.org>
On 10/09/2024 10:17, Simon Horman wrote:
> The id_temp local variable in am65_cpsw_nuss_probe() is
> used to hold a 64-bit big-endian value as it is assigned using
> cpu_to_be64().
>
> It is read using memcpy(), where it is written as an identifier into a
> byte-array. So this can also be treated as big endian.
>
> As it's type is currently host byte order (u64), sparse flags
> an endian mismatch when compiling for little-endian systems:
>
> .../am65-cpsw-nuss.c:3454:17: warning: incorrect type in assignment (different base types)
> .../am65-cpsw-nuss.c:3454:17: expected unsigned long long [usertype] id_temp
> .../am65-cpsw-nuss.c:3454:17: got restricted __be64 [usertype]
>
> Address this by using __be64 as the type of id_temp.
>
> No functional change intended.
> Compile tested only.
>
> Signed-off-by: Simon Horman <horms@kernel.org>
Reviewed-by: Roger Quadros <rogerq@kernel.org>
next prev parent reply other threads:[~2024-09-12 7:10 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-10 7:17 [PATCH net-next 0/3] net: ethernet: ti: Address some warnings Simon Horman
2024-09-10 7:17 ` [PATCH net-next 1/3] net: ethernet: ti: am65-cpsw: Address __percpu Sparse warnings Simon Horman
2024-09-12 0:06 ` Jakub Kicinski
2024-09-12 9:58 ` Simon Horman
2024-09-12 15:45 ` Jakub Kicinski
2024-09-12 19:48 ` Simon Horman
2024-09-10 7:17 ` [PATCH net-next 2/3] net: ethernet: ti: am65-cpsw: Use __be64 type for id_temp Simon Horman
2024-09-10 8:42 ` Kalesh Anakkur Purayil
2024-09-12 7:10 ` Roger Quadros [this message]
2024-09-10 7:17 ` [PATCH net-next 3/3] net: ethernet: ti: cpsw_ale: Remove unused accessor functions Simon Horman
2024-09-12 7:07 ` Roger Quadros
2024-09-12 8:59 ` Simon Horman
2024-09-12 10:54 ` Roger Quadros
2024-09-12 11:27 ` Simon Horman
2024-09-12 13:29 ` Roger Quadros
2024-09-12 15:43 ` Simon Horman
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=27c12575-e670-4355-8d12-d5b544ec16f2@kernel.org \
--to=rogerq@kernel.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=justinstitt@google.com \
--cc=kuba@kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=llvm@lists.linux.dev \
--cc=morbo@google.com \
--cc=nathan@kernel.org \
--cc=ndesaulniers@google.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=s-vadapalli@ti.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox