From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Colin King <colin.king@canonical.com>
Cc: QLogic-Storage-Upstream@qlogic.com,
"James E . J . Bottomley" <jejb@linux.ibm.com>,
"Martin K . Petersen" <martin.petersen@oracle.com>,
linux-scsi@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scsi: bnx2fc: fix incorrect cast to u64 on shift operation
Date: Tue, 14 May 2019 17:12:30 +0000 [thread overview]
Message-ID: <yq18sv9dkox.fsf@oracle.com> (raw)
In-Reply-To: <20190504164829.26631-1-colin.king@canonical.com> (Colin King's message of "Sat, 4 May 2019 17:48:29 +0100")
Colin,
> Currently an int is being shifted and the result is being cast to a
> u64 which leads to undefined behaviour if the shift is more than 31
> bits. Fix this by casting the integer value 1 to u64 before the shift
> operation.
Applied to 5.2/scsi-fixes, thanks!
--
Martin K. Petersen Oracle Linux Engineering
WARNING: multiple messages have this Message-ID (diff)
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Colin King <colin.king@canonical.com>
Cc: QLogic-Storage-Upstream@qlogic.com,
"James E . J . Bottomley" <jejb@linux.ibm.com>,
"Martin K . Petersen" <martin.petersen@oracle.com>,
linux-scsi@vger.kernel.org, kernel-janitors@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scsi: bnx2fc: fix incorrect cast to u64 on shift operation
Date: Tue, 14 May 2019 13:12:30 -0400 [thread overview]
Message-ID: <yq18sv9dkox.fsf@oracle.com> (raw)
In-Reply-To: <20190504164829.26631-1-colin.king@canonical.com> (Colin King's message of "Sat, 4 May 2019 17:48:29 +0100")
Colin,
> Currently an int is being shifted and the result is being cast to a
> u64 which leads to undefined behaviour if the shift is more than 31
> bits. Fix this by casting the integer value 1 to u64 before the shift
> operation.
Applied to 5.2/scsi-fixes, thanks!
--
Martin K. Petersen Oracle Linux Engineering
next prev parent reply other threads:[~2019-05-14 17:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-04 16:48 [PATCH] scsi: bnx2fc: fix incorrect cast to u64 on shift operation Colin King
2019-05-04 16:48 ` Colin King
2019-05-08 8:56 ` Saurav Kashyap
2019-05-08 8:56 ` Saurav Kashyap
2019-05-08 9:35 ` Christophe JAILLET
2019-05-08 9:35 ` Christophe JAILLET
2019-05-14 17:12 ` Martin K. Petersen [this message]
2019-05-14 17:12 ` 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=yq18sv9dkox.fsf@oracle.com \
--to=martin.petersen@oracle.com \
--cc=QLogic-Storage-Upstream@qlogic.com \
--cc=colin.king@canonical.com \
--cc=jejb@linux.ibm.com \
--cc=kernel-janitors@vger.kernel.org \
--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.