All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Michael Margolin <mrgolin@amazon.com>
Cc: leon@kernel.org, linux-rdma@vger.kernel.org, sleybo@amazon.com,
	matua@amazon.com, gal.pressman@linux.dev,
	kernel test robot <lkp@intel.com>,
	Yehuda Yitschak <yehuday@amazon.com>,
	Yonatan Nachum <ynachum@amazon.com>
Subject: Re: [PATCH] RDMA/efa: Fix node guid compiler warning
Date: Tue, 24 Sep 2024 15:00:30 -0300	[thread overview]
Message-ID: <20240924180030.GM9417@nvidia.com> (raw)
In-Reply-To: <20240924121603.16006-1-mrgolin@amazon.com>

On Tue, Sep 24, 2024 at 12:16:03PM +0000, Michael Margolin wrote:
> The GUID is received in big-endian so align types accordingly to avoid
> compiler warnings.
> 
> Closes: https://lore.kernel.org/oe-kbuild-all/202409032113.bvyVfsNp-lkp@intel.com/
> 
> Fixes: 04e36fd27a2a ("RDMA/efa: Add support for node guid")
> Reported-by: kernel test robot <lkp@intel.com>
> Reviewed-by: Yehuda Yitschak <yehuday@amazon.com>
> Reviewed-by: Yonatan Nachum <ynachum@amazon.com>
> Signed-off-by: Michael Margolin <mrgolin@amazon.com>
> ---
>  drivers/infiniband/hw/efa/efa_com_cmd.c | 2 +-
>  drivers/infiniband/hw/efa/efa_com_cmd.h | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/infiniband/hw/efa/efa_com_cmd.c b/drivers/infiniband/hw/efa/efa_com_cmd.c
> index 5a774925cdea..5754da4e6ff8 100644
> --- a/drivers/infiniband/hw/efa/efa_com_cmd.c
> +++ b/drivers/infiniband/hw/efa/efa_com_cmd.c
> @@ -465,7 +465,7 @@ int efa_com_get_device_attr(struct efa_com_dev *edev,
>  	result->db_bar = resp.u.device_attr.db_bar;
>  	result->max_rdma_size = resp.u.device_attr.max_rdma_size;
>  	result->device_caps = resp.u.device_attr.device_caps;
> -	result->guid = resp.u.device_attr.guid;
> +	result->guid = (__force __be64)resp.u.device_attr.guid;

That can't be right, use the proper conversion function, or the proper
type..

Jason

  reply	other threads:[~2024-09-24 18:00 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-24 12:16 [PATCH] RDMA/efa: Fix node guid compiler warning Michael Margolin
2024-09-24 18:00 ` Jason Gunthorpe [this message]
2024-09-26 12:56   ` Margolin, Michael
2024-09-26 13:25     ` Margolin, Michael
2024-09-26 14:54       ` Jason Gunthorpe
2024-09-26 20:03         ` Margolin, Michael
2024-09-26 22:34           ` Jason Gunthorpe
2024-10-02 12:30             ` Margolin, Michael
2024-10-02 13:04               ` Jason Gunthorpe
2024-10-06 13:19 ` Leon Romanovsky

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=20240924180030.GM9417@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=gal.pressman@linux.dev \
    --cc=leon@kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=matua@amazon.com \
    --cc=mrgolin@amazon.com \
    --cc=sleybo@amazon.com \
    --cc=yehuday@amazon.com \
    --cc=ynachum@amazon.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.