From: Bart Van Assche <bvanassche@acm.org>
To: Liao Chen <liaochen4@huawei.com>,
GR-QLogic-Storage-Upstream@marvell.com,
linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: skashyap@marvell.com, jhasan@marvell.com,
James.Bottomley@HansenPartnership.com,
martin.petersen@oracle.com
Subject: Re: [PATCH -next v2] scsi: qedf: Remove dead code
Date: Tue, 24 Sep 2024 12:38:04 -0700 [thread overview]
Message-ID: <a811008e-4b30-4267-bb74-6957b461b918@acm.org> (raw)
In-Reply-To: <20240921062956.2027563-1-liaochen4@huawei.com>
On 9/20/24 11:29 PM, Liao Chen wrote:
> If container_of() is used correctly, its result is never NULL. Remove
> the code that depends on container_of() returning a NULL pointer.
>
> Signed-off-by: Liao Chen <liaochen4@huawei.com>
> ---
> drivers/scsi/qedf/qedf_main.c | 5 -----
> 1 file changed, 5 deletions(-)
>
> diff --git a/drivers/scsi/qedf/qedf_main.c b/drivers/scsi/qedf/qedf_main.c
> index cf13148ba281..df756f3eef3e 100644
> --- a/drivers/scsi/qedf/qedf_main.c
> +++ b/drivers/scsi/qedf/qedf_main.c
> @@ -4018,11 +4018,6 @@ void qedf_stag_change_work(struct work_struct *work)
> struct qedf_ctx *qedf =
> container_of(work, struct qedf_ctx, stag_work.work);
>
> - if (!qedf) {
> - QEDF_ERR(&qedf->dbg_ctx, "qedf is NULL");
> - return;
> - }
> -
> if (test_bit(QEDF_IN_RECOVERY, &qedf->flags)) {
> QEDF_ERR(&qedf->dbg_ctx,
> "Already is in recovery, hence not calling software context reset.\n");
The merge window is open so this is not the best time to send patches
that are not fixes for issues discovered during the merge window.
Anyway:
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
next prev parent reply other threads:[~2024-09-24 19:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-21 6:29 Liao Chen
2024-09-24 19:38 ` Bart Van Assche [this message]
2024-10-04 1:38 ` 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=a811008e-4b30-4267-bb74-6957b461b918@acm.org \
--to=bvanassche@acm.org \
--cc=GR-QLogic-Storage-Upstream@marvell.com \
--cc=James.Bottomley@HansenPartnership.com \
--cc=jhasan@marvell.com \
--cc=liaochen4@huawei.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=skashyap@marvell.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
all inboxes | Powered by JetHome®