From: Guixin Liu <kanie@linux.alibaba.com>
To: kashyap.desai@broadcom.com, sumit.saxena@broadcom.com,
shivasharan.srikanteshwara@broadcom.com, jejb@linux.ibm.com,
martin.petersen@oracle.com
Cc: megaraidlinux.pdl@broadcom.com, linux-scsi@vger.kernel.org
Subject: Re: [PATCH] scsi: megaraid_sas: fix double kfree
Date: Mon, 8 Aug 2022 10:37:36 +0800 [thread overview]
Message-ID: <5e0b3b8a-7728-9fda-d952-411d0fa1938d@linux.alibaba.com> (raw)
In-Reply-To: <1659424729-46502-1-git-send-email-kanie@linux.alibaba.com>
Hi,
Gentle ping.
在 2022/8/2 15:18, Guixin Liu 写道:
> When alloc log_to_span fail, call kfree(instance->ctrl_context) first,
> then jump to megasas_free_ctrl_mem() in megasas_init_fw(), call
> kfree(instance->ctrl_context) second.
>
> Signed-off-by: Guixin Liu <kanie@linux.alibaba.com>
> ---
> drivers/scsi/megaraid/megaraid_sas_fusion.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/scsi/megaraid/megaraid_sas_fusion.c b/drivers/scsi/megaraid/megaraid_sas_fusion.c
> index 5b5885d..3e9b2b0 100644
> --- a/drivers/scsi/megaraid/megaraid_sas_fusion.c
> +++ b/drivers/scsi/megaraid/megaraid_sas_fusion.c
> @@ -5311,7 +5311,6 @@ void megasas_fusion_ocr_wq(struct work_struct *work)
> if (!fusion->log_to_span) {
> dev_err(&instance->pdev->dev, "Failed from %s %d\n",
> __func__, __LINE__);
> - kfree(instance->ctrl_context);
> return -ENOMEM;
> }
> }
next prev parent reply other threads:[~2022-08-08 2:37 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-02 7:18 [PATCH] scsi: megaraid_sas: fix double kfree Guixin Liu
2022-08-08 2:37 ` Guixin Liu [this message]
2022-08-09 7:37 ` Sumit Saxena
2022-08-12 2:13 ` 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=5e0b3b8a-7728-9fda-d952-411d0fa1938d@linux.alibaba.com \
--to=kanie@linux.alibaba.com \
--cc=jejb@linux.ibm.com \
--cc=kashyap.desai@broadcom.com \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=megaraidlinux.pdl@broadcom.com \
--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