Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1663406
| From | John Garry <john.garry@huawei.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v5 03/23] scsi: hisi_sas: optimise the usage of hisi_hba.lock |
| Date | 2017-06-12 12:30 +0200 |
| Message-ID | <tRuLE-Ua-17@gated-at.bofh.it> (permalink) |
| References | <tQVux-3Ps-5@gated-at.bofh.it> <tRsTw-8al-13@gated-at.bofh.it> <tRu8V-p0-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 12/06/2017 10:45, Arnd Bergmann wrote: > On Mon, Jun 12, 2017 at 10:26 AM, John Garry <john.garry@huawei.com> wrote: >> On 10/06/2017 21:44, kbuild test robot wrote: >> >> >> I don't think that reusing flags variable is in error, as there would be no >> nested spinlock at this point within the function. >> >> If it is not recommended or not permitted to reuse flags variable for >> separate spinlocks, then that can be changed - I don't know. > > No, look again: coccinelle is right as the locks are nested in > https://github.com/0day-ci/linux/blob/bf95e9cccde4af4ed2012a6ec44d48b545d5ffed/drivers/scsi/hisi_sas/hisi_sas_main.c#L1208 > > dq->lock is already held and you acquire task->task_state_lock in > line 1208, which overwrites the flags. > > Arnd Hi Arnd, Ah, now I see. The error message mislead me, as I straight away checked hisi_sas_task_prep() which does the same locking and also reuses flags for spinlock_irqsave(), but it's safe here. But, as you pointed out, the problem is in hisi_sas_internal_abort_task_exec(). A thought: it would be useful if coccinelle printed explicitly the function name which has the warning/error. Thanks, John > > . >
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH v5 00/23] hisi_sas: hip08 support John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 23/23] scsi: hisi_sas: modify internal abort dev flow for v3 hw John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 01/23] scsi: hisi_sas: fix timeout check in hisi_sas_internal_task_abort() John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 19/23] scsi: hisi_sas: add v3 code to send internal abort command John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 18/23] scsi: hisi_sas: add v3 code for itct setup and free John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 02/23] scsi: hisi_sas: define hisi_sas_device.device_id as int John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 20/23] scsi: hisi_sas: add get_wideport_bitmap_v3_hw() John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 08/23] scsi: hisi_sas: create hisi_sas_get_fw_info() John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 16/23] scsi: hisi_sas: add v3 code to send SMP frame John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 14/23] scsi: hisi_sas: add v3 cq interrupt handler John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 04/23] scsi: hisi_sas: relocate get_ata_protocol() John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 07/23] scsi: hisi_sas: add pci_dev in hisi_hba struct John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 15/23] scsi: hisi_sas: add v3 code to send SSP frame John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 09/23] scsi: hisi_sas: add skeleton v3 hw driver John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 17/23] scsi: hisi_sas: add v3 code to send ATA frame John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 11/23] scsi: hisi_sas: add v3 hw init John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 05/23] scsi: hisi_sas: relocate sata_done_v2_hw() John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
[PATCH v5 03/23] scsi: hisi_sas: optimise the usage of hisi_hba.lock John Garry <john.garry@huawei.com> - 2017-06-09 16:00 +0200
Re: [PATCH v5 03/23] scsi: hisi_sas: optimise the usage of hisi_hba.lock kbuild test robot <lkp@intel.com> - 2017-06-10 22:50 +0200
Re: [PATCH v5 03/23] scsi: hisi_sas: optimise the usage of hisi_hba.lock John Garry <john.garry@huawei.com> - 2017-06-12 10:30 +0200
Re: [PATCH v5 03/23] scsi: hisi_sas: optimise the usage of hisi_hba.lock Arnd Bergmann <arnd@arndb.de> - 2017-06-12 11:50 +0200
Re: [PATCH v5 03/23] scsi: hisi_sas: optimise the usage of hisi_hba.lock John Garry <john.garry@huawei.com> - 2017-06-12 12:30 +0200
csiph-web