All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: QLogic-Storage-Upstream@cavium.com,
	"James E.J. Bottomley" <jejb@linux.vnet.ibm.com>,
	"Martin K. Petersen" <martin.petersen@oracle.com>,
	Arnd Bergmann <arnd@arndb.de>, Ram Amrani <Ram.Amrani@cavium.com>,
	Chad Dupuis <Chad.Dupuis@cavium.com>,
	Tomer Tayar <Tomer.Tayar@cavium.com>, "Mintz\,
	Yuval" <Yuval.Mintz@cavium.com>,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] qedf: fix wrong le16 conversion
Date: Thu, 23 Mar 2017 10:19:03 -0400	[thread overview]
Message-ID: <yq1r31odqjs.fsf@oracle.com> (raw)
In-Reply-To: <20170320084947.1031363-1-arnd@arndb.de> (Arnd Bergmann's message of "Mon, 20 Mar 2017 09:49:27 +0100")

Arnd Bergmann <arnd@arndb.de> writes:

> gcc points out that we are converting a 16-bit integer into a 32-bit
> little-endian type and assigning that to 16-bit little-endian
> will end up with a zero:
>
> drivers/scsi/qedf/drv_fcoe_fw_funcs.c: In function 'init_initiator_rw_fcoe_task':
> include/uapi/linux/byteorder/big_endian.h:32:26: error: large integer implicitly truncated to unsigned type [-Werror=overflow]
>   t_st_ctx->read_write.rx_id = cpu_to_le32(FCOE_RX_ID);
>
> The correct solution appears to be to just use a 16-bit byte swap instead.
>
> Fixes: be086e7c53f1 ("qed*: Utilize Firmware 8.15.3.0")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  drivers/scsi/qedf/drv_fcoe_fw_funcs.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Dave: Since you queued the firmware patch, mind taking this fix through
your tree?

-- 
Martin K. Petersen	Oracle Linux Engineering

WARNING: multiple messages have this Message-ID (diff)
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: QLogic-Storage-Upstream@cavium.com,
	"James E.J. Bottomley" <jejb@linux.vnet.ibm.com>,
	"Martin K. Petersen" <martin.petersen@oracle.com>,
	Arnd Bergmann <arnd@arndb.de>, Ram Amrani <Ram.Amrani@cavium.com>,
	Chad Dupuis <Chad.Dupuis@cavium.com>,
	Tomer Tayar <Tomer.Tayar@cavium.com>,
	"Mintz, Yuval" <Yuval.Mintz@cavium.com>,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] qedf: fix wrong le16 conversion
Date: Thu, 23 Mar 2017 10:19:03 -0400	[thread overview]
Message-ID: <yq1r31odqjs.fsf@oracle.com> (raw)
In-Reply-To: <20170320084947.1031363-1-arnd@arndb.de> (Arnd Bergmann's message of "Mon, 20 Mar 2017 09:49:27 +0100")

Arnd Bergmann <arnd@arndb.de> writes:

> gcc points out that we are converting a 16-bit integer into a 32-bit
> little-endian type and assigning that to 16-bit little-endian
> will end up with a zero:
>
> drivers/scsi/qedf/drv_fcoe_fw_funcs.c: In function 'init_initiator_rw_fcoe_task':
> include/uapi/linux/byteorder/big_endian.h:32:26: error: large integer implicitly truncated to unsigned type [-Werror=overflow]
>   t_st_ctx->read_write.rx_id = cpu_to_le32(FCOE_RX_ID);
>
> The correct solution appears to be to just use a 16-bit byte swap instead.
>
> Fixes: be086e7c53f1 ("qed*: Utilize Firmware 8.15.3.0")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
>  drivers/scsi/qedf/drv_fcoe_fw_funcs.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Dave: Since you queued the firmware patch, mind taking this fix through
your tree?

-- 
Martin K. Petersen	Oracle Linux Engineering

  parent reply	other threads:[~2017-03-23 14:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-20  8:49 [PATCH] qedf: fix wrong le16 conversion Arnd Bergmann
2017-03-20 13:40 ` Chad Dupuis
2017-03-23 14:19 ` Martin K. Petersen [this message]
2017-03-23 14:19   ` Martin K. Petersen
2017-03-23 18:56   ` David Miller
2017-03-23 20:07     ` Martin K. Petersen

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=yq1r31odqjs.fsf@oracle.com \
    --to=martin.petersen@oracle.com \
    --cc=Chad.Dupuis@cavium.com \
    --cc=QLogic-Storage-Upstream@cavium.com \
    --cc=Ram.Amrani@cavium.com \
    --cc=Tomer.Tayar@cavium.com \
    --cc=Yuval.Mintz@cavium.com \
    --cc=arnd@arndb.de \
    --cc=davem@davemloft.net \
    --cc=jejb@linux.vnet.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    /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.