From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: Maximilian Heyne <mheyne@amazon.de>
Cc: Kashyap Desai <kashyap.desai@broadcom.com>,
Sumit Saxena <sumit.saxena@broadcom.com>,
Shivasharan S <shivasharan.srikanteshwara@broadcom.com>,
"James E.J. Bottomley" <jejb@linux.ibm.com>,
"Martin K. Petersen" <martin.petersen@oracle.com>,
James Bottomley <JBottomley@Parallels.com>,
Adam Radford <aradford@gmail.com>,
Christoph Hellwig <hch@infradead.org>,
<megaraidlinux.pdl@broadcom.com>, <linux-scsi@vger.kernel.org>,
<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] scsi: megaraid: Fix uninitialized mbox in mega_cmd_done
Date: Wed, 31 May 2023 18:38:12 -0400 [thread overview]
Message-ID: <yq1v8g8b0e8.fsf@ca-mkp.ca.oracle.com> (raw)
In-Reply-To: <20230531133259.55619-1-mheyne@amazon.de> (Maximilian Heyne's message of "Wed, 31 May 2023 13:32:59 +0000")
Hi Maximilian!
> This is similar to commit 7a2ae008a53c ("scsi: megaraid: Fix
> mega_cmd_done() CMDID_INT_CMDS").
That's supposed to be commit 75cb113cd43f, right?
> When cmdid == CMDID_INT_CMDS and status != 0 then mbox is still NULL
> but is dereferenced below.
Is this actually a valid scenario, though? The mbox is only dereferenced
if there is status returned from an attached device. And I am guessing
that a controller-internal command does not talk to any attached device.
Thus status should always be 0 for CMDID_INT_CMDS. I don't have the
megaraid firmware manual so this is pure guesswork on my part. But you
would think we would have come across an invalid deref since the
original 2014 commit made the offending change.
--
Martin K. Petersen Oracle Linux Engineering
next prev parent reply other threads:[~2023-05-31 22:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-31 13:32 [PATCH] scsi: megaraid: Fix uninitialized mbox in mega_cmd_done Maximilian Heyne
2023-05-31 22:38 ` Martin K. Petersen [this message]
2023-06-01 7:23 ` Maximilian Heyne
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=yq1v8g8b0e8.fsf@ca-mkp.ca.oracle.com \
--to=martin.petersen@oracle.com \
--cc=JBottomley@Parallels.com \
--cc=aradford@gmail.com \
--cc=hch@infradead.org \
--cc=jejb@linux.ibm.com \
--cc=kashyap.desai@broadcom.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=megaraidlinux.pdl@broadcom.com \
--cc=mheyne@amazon.de \
--cc=shivasharan.srikanteshwara@broadcom.com \
--cc=sumit.saxena@broadcom.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