Message ID | 20231023215638.3405959-6-bvanassche@acm.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Improve write performance for zoned UFS devices​ | expand |
On 10/24/23 06:53, Bart Van Assche wrote: > This patch prepares for using the host pointer directly in > scsi_eh_flush_done_q() in a later patch. > > Cc: Martin K. Petersen <martin.petersen@oracle.com> > Cc: Damien Le Moal <dlemoal@kernel.org> > Signed-off-by: Bart Van Assche <bvanassche@acm.org> Acked-by: Damien Le Moal <dlemoal@kernel.org>
On 23/10/2023 22:53, Bart Van Assche wrote: "Add an argument to scsi_eh_flush_done_q()" - that's too vague. I'd have "Pass shost pointer to scsi_eh_flush_done_q()". And I have to admit that it is painful to help review when only cc'ed explicitly on a single patch. Thanks, John
On 10/24/23 02:26, John Garry wrote: > On 23/10/2023 22:53, Bart Van Assche wrote: > "Add an argument to scsi_eh_flush_done_q()" - that's too vague. I'd have > "Pass shost pointer to scsi_eh_flush_done_q()". Thanks for having taken a look. I will change the subject. > And I have to admit that it is painful to help review when only cc'ed > explicitly on a single patch. The linux-scsi mailing list has been Cc-ed. I assume that you are subscribed to that mailing list. BTW, I'm using "scripts/get_maintainer.pl" to build a Cc-list. Unfortunately git send-email does not make it easy to combine the cc-lists of individual patches into one cc-list for all patches :-( Thanks, Bart.
On 24/10/2023 18:17, Bart Van Assche wrote: > > The linux-scsi mailing list has been Cc-ed. I assume that you are > subscribed to that mailing list. I am subscribed. However I have a rule set up which filters anything linux-scsi to a dedicated subfolder unless I am explicitly included in the mail "to" or "cc" list. I guess that many contributors do something similar. So this means that for this series patches end up in different folders and it becomes a bit harder to track. > > BTW, I'm using "scripts/get_maintainer.pl" to build a Cc-list. > Unfortunately git send-email does not make it easy to combine the > cc-lists of individual patches into one cc-list for all patches
diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c index 4cf4f57e57b8..9a1a06a8e5db 100644 --- a/drivers/ata/libata-eh.c +++ b/drivers/ata/libata-eh.c @@ -738,7 +738,7 @@ void ata_scsi_port_error_handler(struct Scsi_Host *host, struct ata_port *ap) spin_unlock_irqrestore(ap->lock, flags); ata_eh_release(ap); - scsi_eh_flush_done_q(&ap->eh_done_q); + scsi_eh_flush_done_q(host, &ap->eh_done_q); /* clean up */ spin_lock_irqsave(ap->lock, flags); diff --git a/drivers/scsi/libsas/sas_scsi_host.c b/drivers/scsi/libsas/sas_scsi_host.c index 9047cfcd1072..dd4fb97fdc4b 100644 --- a/drivers/scsi/libsas/sas_scsi_host.c +++ b/drivers/scsi/libsas/sas_scsi_host.c @@ -730,7 +730,7 @@ void sas_scsi_recover_host(struct Scsi_Host *shost) /* now link into libata eh --- if we have any ata devices */ sas_ata_strategy_handler(shost); - scsi_eh_flush_done_q(&ha->eh_done_q); + scsi_eh_flush_done_q(shost, &ha->eh_done_q); /* check if any new eh work was scheduled during the last run */ spin_lock_irq(&ha->lock); diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c index c67cdcdc3ba8..7390131e7f0a 100644 --- a/drivers/scsi/scsi_error.c +++ b/drivers/scsi/scsi_error.c @@ -2188,9 +2188,10 @@ EXPORT_SYMBOL_GPL(scsi_eh_ready_devs); /** * scsi_eh_flush_done_q - finish processed commands or retry them. + * @shost: SCSI host pointer. * @done_q: list_head of processed commands. */ -void scsi_eh_flush_done_q(struct list_head *done_q) +void scsi_eh_flush_done_q(struct Scsi_Host *shost, struct list_head *done_q) { struct scsi_cmnd *scmd, *next; @@ -2265,7 +2266,7 @@ static void scsi_unjam_host(struct Scsi_Host *shost) if (shost->eh_deadline != -1) shost->last_reset = 0; spin_unlock_irqrestore(shost->host_lock, flags); - scsi_eh_flush_done_q(&eh_done_q); + scsi_eh_flush_done_q(shost, &eh_done_q); } /** diff --git a/include/scsi/scsi_eh.h b/include/scsi/scsi_eh.h index 1ae08e81339f..d2807d799fda 100644 --- a/include/scsi/scsi_eh.h +++ b/include/scsi/scsi_eh.h @@ -11,7 +11,8 @@ struct Scsi_Host; extern void scsi_eh_finish_cmd(struct scsi_cmnd *scmd, struct list_head *done_q); -extern void scsi_eh_flush_done_q(struct list_head *done_q); +extern void scsi_eh_flush_done_q(struct Scsi_Host *shost, + struct list_head *done_q); extern void scsi_report_bus_reset(struct Scsi_Host *, int); extern void scsi_report_device_reset(struct Scsi_Host *, int, int); extern int scsi_block_when_processing_errors(struct scsi_device *);
This patch prepares for using the host pointer directly in scsi_eh_flush_done_q() in a later patch. Cc: Martin K. Petersen <martin.petersen@oracle.com> Cc: Damien Le Moal <dlemoal@kernel.org> Signed-off-by: Bart Van Assche <bvanassche@acm.org> --- drivers/ata/libata-eh.c | 2 +- drivers/scsi/libsas/sas_scsi_host.c | 2 +- drivers/scsi/scsi_error.c | 5 +++-- include/scsi/scsi_eh.h | 3 ++- 4 files changed, 7 insertions(+), 5 deletions(-)