From: zhuwei <zhuwei@sangfor.com.cn>
To: Don.Brace@microchip.com
Cc: dinghui@sangfor.com.cn, zengzhicong@sangfor.com.cn,
James.Bottomley@hansenpartnership.com,
martin.petersen@oracle.com, storagedev@microchip.com,
linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
stable@vger.kernel.org
Subject: Re: [PATCH] scsi: smartpqi: Fix the race condition between pqi_tmf_worker and pqi_sdev_destroy
Date: Sat, 10 May 2025 09:15:13 +0800 [thread overview]
Message-ID: <a497880a-e6a3-409d-8c4e-d5086459ce3a@sangfor.com.cn> (raw)
In-Reply-To: <SJ2PR11MB8369E480AEB019041B756254E18AA@SJ2PR11MB8369.namprd11.prod.outlook.com>
On 2025/5/9 23:19, Don.Brace@microchip.com wrote:
>
> ---------- Forwarded message ---------
> From: Zhu Wei <zhuwei@sangfor.com.cn>
> Date: Thu, May 8, 2025 at 7:57 AM
> Subject: [PATCH] scsi: smartpqi: Fix the race condition between pqi_tmf_worker and pqi_sdev_destroy
> To: <don.brace@microchip.com>, <kevin.barnett@microchip.com>
> Cc: <dinghui@sangfor.com.cn>, <zengzhicong@sangfor.com.cn>, <James.Bottomley@hansenpartnership.com>, <martin.petersen@oracle.com>, <storagedev@microchip.com>, <linux-scsi@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <stable@vger.kernel.org>, Zhu Wei <zhuwei@sangfor.com.cn>
>
>
> There is a race condition between pqi_sdev_destroy and pqi_tmf_worker.
> After pqi_free_device is released, pqi_tmf_worker will still use device.
>
> Don: Thank-you for your patch, however we recently applied a similar patch to our internal repo.
> Don: But more checking is done for removed devices.
> Don: When this patch has been tested internally, we will post it up for review.
> Don: I will add a Reported-By tag with your name.
Ok, hope smartpqi gets better.
> Don: So Nak.
>
>
>
> kasan report:
> [ 1933.765810] ==================================================================
> [ 1933.771862] scsi 15:0:20:0: Direct-Access ATA WDC WUH722222AL WTS2 PQ: 0 ANSI: 6
> [ 1933.779190] BUG: KASAN: use-after-free in pqi_device_wait_for_pending_io+0x9e/0x600 [smartpqi]
> ......
> --
> 2.43.0
>
prev parent reply other threads:[~2025-05-10 5:51 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-08 12:50 [PATCH] scsi: smartpqi: Fix the race condition between pqi_tmf_worker and pqi_sdev_destroy Zhu Wei
2025-05-08 13:04 ` kernel test robot
[not found] ` <CAF=wSYo0=US5Rj8Qbo7tbPLTtEVR-E=q4w07jCvU3nMroZBKmA@mail.gmail.com>
2025-05-09 15:19 ` Don.Brace
2025-05-10 1:15 ` zhuwei [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=a497880a-e6a3-409d-8c4e-d5086459ce3a@sangfor.com.cn \
--to=zhuwei@sangfor.com.cn \
--cc=Don.Brace@microchip.com \
--cc=James.Bottomley@hansenpartnership.com \
--cc=dinghui@sangfor.com.cn \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=stable@vger.kernel.org \
--cc=storagedev@microchip.com \
--cc=zengzhicong@sangfor.com.cn \
/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