cxlflash: Remove unnecessary scsi_block_requests
authorMatthew R. Ochs <mrochs@linux.vnet.ibm.com>
Wed, 21 Oct 2015 20:14:32 +0000 (15:14 -0500)
committerJames Bottomley <JBottomley@Odin.com>
Fri, 30 Oct 2015 08:16:52 +0000 (17:16 +0900)
The host reset handler is called with I/O already blocked, thus
there is no need to explicitly block and unblock I/O in the handler.

Signed-off-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com>
Signed-off-by: Manoj N. Kumar <manoj@linux.vnet.ibm.com>
Reviewed-by: Brian King <brking@linux.vnet.ibm.com>
Reviewed-by: Tomas Henzl <thenzl@redhat.com>
Signed-off-by: James Bottomley <JBottomley@Odin.com>
drivers/scsi/cxlflash/main.c

index 89bd4c3..441e897 100644 (file)
@@ -1966,7 +1966,6 @@ static int cxlflash_eh_host_reset_handler(struct scsi_cmnd *scp)
        switch (cfg->state) {
        case STATE_NORMAL:
                cfg->state = STATE_RESET;
        switch (cfg->state) {
        case STATE_NORMAL:
                cfg->state = STATE_RESET;
-               scsi_block_requests(cfg->host);
                cxlflash_mark_contexts_error(cfg);
                rcr = afu_reset(cfg);
                if (rcr) {
                cxlflash_mark_contexts_error(cfg);
                rcr = afu_reset(cfg);
                if (rcr) {
@@ -1975,7 +1974,6 @@ static int cxlflash_eh_host_reset_handler(struct scsi_cmnd *scp)
                } else
                        cfg->state = STATE_NORMAL;
                wake_up_all(&cfg->reset_waitq);
                } else
                        cfg->state = STATE_NORMAL;
                wake_up_all(&cfg->reset_waitq);
-               scsi_unblock_requests(cfg->host);
                break;
        case STATE_RESET:
                wait_event(cfg->reset_waitq, cfg->state != STATE_RESET);
                break;
        case STATE_RESET:
                wait_event(cfg->reset_waitq, cfg->state != STATE_RESET);