Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1313278 > unrolled thread
| Started by | Johannes Thumshirn <jthumshirn@suse.de> |
|---|---|
| First post | 2016-01-20 16:10 +0100 |
| Last post | 2016-01-27 03:40 +0100 |
| Articles | 5 — 5 participants |
Back to article view | Back to linux.kernel
[PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl Johannes Thumshirn <jthumshirn@suse.de> - 2016-01-20 16:10 +0100
Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl Tomas Henzl <thenzl@redhat.com> - 2016-01-20 17:10 +0100
Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl "Matthew R. Ochs" <mrochs@linux.vnet.ibm.com> - 2016-01-20 17:20 +0100
Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl Sebastian Herbszt <herbszt@gmx.de> - 2016-01-20 23:00 +0100
Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl "Martin K. Petersen" <martin.petersen@oracle.com> - 2016-01-27 03:40 +0100
| From | Johannes Thumshirn <jthumshirn@suse.de> |
|---|---|
| Date | 2016-01-20 16:10 +0100 |
| Subject | [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl |
| Message-ID | <qT2yu-8hL-23@gated-at.bofh.it> |
This removes a redundant code block that will either be executed if the
ENABLE_FCP_RING_POLLING flag is set in phba->cfg_poll or not. The code is just
duplicated in both cases, hence we unify it again.
This probably is a left over from some sort of refactoring.
Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
---
drivers/scsi/lpfc/lpfc_scsi.c | 17 -----------------
1 file changed, 17 deletions(-)
diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi.c
index 152b3c8..3bd0be6 100644
--- a/drivers/scsi/lpfc/lpfc_scsi.c
+++ b/drivers/scsi/lpfc/lpfc_scsi.c
@@ -4139,23 +4139,6 @@ lpfc_scsi_cmd_iocb_cmpl(struct lpfc_hba *phba, struct lpfc_iocbq *pIocbIn,
/* The sdev is not guaranteed to be valid post scsi_done upcall. */
cmd->scsi_done(cmd);
- if (phba->cfg_poll & ENABLE_FCP_RING_POLLING) {
- spin_lock_irqsave(&phba->hbalock, flags);
- lpfc_cmd->pCmd = NULL;
- spin_unlock_irqrestore(&phba->hbalock, flags);
-
- /*
- * If there is a thread waiting for command completion
- * wake up the thread.
- */
- spin_lock_irqsave(shost->host_lock, flags);
- if (lpfc_cmd->waitq)
- wake_up(lpfc_cmd->waitq);
- spin_unlock_irqrestore(shost->host_lock, flags);
- lpfc_release_scsi_buf(phba, lpfc_cmd);
- return;
- }
-
spin_lock_irqsave(&phba->hbalock, flags);
lpfc_cmd->pCmd = NULL;
spin_unlock_irqrestore(&phba->hbalock, flags);
--
2.7.0
[toc] | [next] | [standalone]
| From | Tomas Henzl <thenzl@redhat.com> |
|---|---|
| Date | 2016-01-20 17:10 +0100 |
| Subject | Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl |
| Message-ID | <qT3uy-vq-31@gated-at.bofh.it> |
| In reply to | #1313278 |
On 20.1.2016 16:08, Johannes Thumshirn wrote:
> This removes a redundant code block that will either be executed if the
> ENABLE_FCP_RING_POLLING flag is set in phba->cfg_poll or not. The code is just
> duplicated in both cases, hence we unify it again.
>
> This probably is a left over from some sort of refactoring.
>
> Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: Tomas Henzl <thenzl@redhat.com>
Tomas
> ---
> drivers/scsi/lpfc/lpfc_scsi.c | 17 -----------------
> 1 file changed, 17 deletions(-)
>
> diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi.c
> index 152b3c8..3bd0be6 100644
> --- a/drivers/scsi/lpfc/lpfc_scsi.c
> +++ b/drivers/scsi/lpfc/lpfc_scsi.c
> @@ -4139,23 +4139,6 @@ lpfc_scsi_cmd_iocb_cmpl(struct lpfc_hba *phba, struct lpfc_iocbq *pIocbIn,
> /* The sdev is not guaranteed to be valid post scsi_done upcall. */
> cmd->scsi_done(cmd);
>
> - if (phba->cfg_poll & ENABLE_FCP_RING_POLLING) {
> - spin_lock_irqsave(&phba->hbalock, flags);
> - lpfc_cmd->pCmd = NULL;
> - spin_unlock_irqrestore(&phba->hbalock, flags);
> -
> - /*
> - * If there is a thread waiting for command completion
> - * wake up the thread.
> - */
> - spin_lock_irqsave(shost->host_lock, flags);
> - if (lpfc_cmd->waitq)
> - wake_up(lpfc_cmd->waitq);
> - spin_unlock_irqrestore(shost->host_lock, flags);
> - lpfc_release_scsi_buf(phba, lpfc_cmd);
> - return;
> - }
> -
> spin_lock_irqsave(&phba->hbalock, flags);
> lpfc_cmd->pCmd = NULL;
> spin_unlock_irqrestore(&phba->hbalock, flags);
[toc] | [prev] | [next] | [standalone]
| From | "Matthew R. Ochs" <mrochs@linux.vnet.ibm.com> |
|---|---|
| Date | 2016-01-20 17:20 +0100 |
| Message-ID | <qT3Ee-yP-13@gated-at.bofh.it> |
| In reply to | #1313278 |
Reviewed-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com>
[toc] | [prev] | [next] | [standalone]
| From | Sebastian Herbszt <herbszt@gmx.de> |
|---|---|
| Date | 2016-01-20 23:00 +0100 |
| Subject | Re: [PATCH] lpfc: Remove redundant code block in lpfc_scsi_cmd_iocb_cmpl |
| Message-ID | <qT8Xg-3WS-3@gated-at.bofh.it> |
| In reply to | #1313278 |
Johannes Thumshirn wrote: > This removes a redundant code block that will either be executed if the > ENABLE_FCP_RING_POLLING flag is set in phba->cfg_poll or not. The code is just > duplicated in both cases, hence we unify it again. > > This probably is a left over from some sort of refactoring. > > Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Sebastian Herbszt <herbszt@gmx.de>
[toc] | [prev] | [next] | [standalone]
| From | "Martin K. Petersen" <martin.petersen@oracle.com> |
|---|---|
| Date | 2016-01-27 03:40 +0100 |
| Message-ID | <qVobv-53J-1@gated-at.bofh.it> |
| In reply to | #1313278 |
>>>>> "Johannes" == Johannes Thumshirn <jthumshirn@suse.de> writes: Johannes> This removes a redundant code block that will either be Johannes> executed if the ENABLE_FCP_RING_POLLING flag is set in Johannes> phba->cfg_poll or not. The code is just duplicated in both Johannes> cases, hence we unify it again. Johannes> This probably is a left over from some sort of refactoring. James/Dick: Please review. -- Martin K. Petersen Oracle Linux Engineering
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web