Re: [PATCH 14/24] libsas: prevent double completion of scmds from eh

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 17-12-2011 6:34, Dan Williams wrote:

We invoke task->task_done() to free the task in the eh case, but at this
point we are prepared for scsi_eh_flush_done_q() to finish off the scmd.

Introduce sas_end_task() to capture the final response status from the
lldd and free the task.

Also take the opportunity to kill this warning.
drivers/scsi/libsas/sas_scsi_host.c: In function ‘sas_end_task’:
drivers/scsi/libsas/sas_scsi_host.c:102:3: warning: case value ‘2’ not in enumerated type ‘enum exec_status’ [-Wswitch]

   Perhaps this a material for a separate patch...

Signed-off-by: Dan Williams<dan.j.williams@xxxxxxxxx>
---
  drivers/scsi/libsas/sas_scsi_host.c |   61 +++++++++++++++++++----------------
  include/scsi/libsas.h               |    5 ++-
  2 files changed, 37 insertions(+), 29 deletions(-)

diff --git a/include/scsi/libsas.h b/include/scsi/libsas.h
index 6064f82..b6b0b99 100644
--- a/include/scsi/libsas.h
+++ b/include/scsi/libsas.h
@@ -443,7 +443,10 @@ enum service_response {
  };

  enum exec_status {
-	/* The SAM_STAT_.. codes fit in the lower 6 bits */
+	/* The SAM_STAT_.. codes fit in the lower 6 bits, alias some of
+	 * them here to silence 'case value not in enumerated type' warnings
+	 */
+	__SAM_STAT_CHECK_CONDITION = SAM_STAT_CHECK_CONDITION,

   Looks like you forgot to change the problematic *case* itself...

MBR, Sergei
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux