From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Elena Afanasova <eafanasova@gmail.com>,
hare@suse.com, pbonzini@redhat.com, fam@euphon.net,
qemu-block@nongnu.org
Cc: qemu-trivial@nongnu.org, qemu-devel@nongnu.org
Subject: Re: [PATCH] hw/scsi: remove dead code
Date: Mon, 12 Oct 2020 15:35:26 +0200 [thread overview]
Message-ID: <98c5390e-aabd-82e8-e596-a53c90754ccf@redhat.com> (raw)
In-Reply-To: <ea41618a040224242fced25fc3d09d3b1f75a06a.camel@gmail.com>
Hi Elena,
On 10/12/20 3:32 PM, Elena Afanasova wrote:
> Since MEGASAS_MAX_SGE is defined to be 128 the following if statement can be removed.
> Spotted by PVS-Studio.
>
> Signed-off-by: Elena Afanasova <eafanasova@gmail.com>
> ---
> hw/scsi/megasas.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c
> index e24c12d7ee..6dcaad55fa 100644
> --- a/hw/scsi/megasas.c
> +++ b/hw/scsi/megasas.c
> @@ -2393,8 +2393,6 @@ static void megasas_scsi_realize(PCIDevice *dev, Error **errp)
> }
> if (s->fw_sge >= MEGASAS_MAX_SGE - MFI_PASS_FRAME_SIZE) {
> s->fw_sge = MEGASAS_MAX_SGE - MFI_PASS_FRAME_SIZE;
> - } else if (s->fw_sge >= 128 - MFI_PASS_FRAME_SIZE) {
> - s->fw_sge = 128 - MFI_PASS_FRAME_SIZE;
See previous discussion:
https://www.mail-archive.com/qemu-devel@nongnu.org/msg668850.html
> } else {
> s->fw_sge = 64 - MFI_PASS_FRAME_SIZE;
> }
>
prev parent reply other threads:[~2020-10-12 13:36 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-12 13:32 [PATCH] hw/scsi: remove dead code Elena Afanasova
2020-10-12 13:35 ` Philippe Mathieu-Daudé [this message]
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=98c5390e-aabd-82e8-e596-a53c90754ccf@redhat.com \
--to=philmd@redhat.com \
--cc=eafanasova@gmail.com \
--cc=fam@euphon.net \
--cc=hare@suse.com \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).