aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomasz Chudy <Tomasz.Chudy@intel.com>2011-02-23 03:09:04 -0500
committerDan Williams <dan.j.williams@intel.com>2011-07-03 06:55:28 -0400
commit52b957c80c3be9bab2748b0ac59ed3c3e8ffe196 (patch)
tree93c18345f0274951cef053f419743179a99a6346
parent3c06c2839dac6db56a1e6bd11924db38eddfb2ed (diff)
isci: Add Support for new TC completion codes
Update the SCI Core to comprehend the changes in the TC completion codes from A0 to B0. Specifically, there isnew R_ER code differences for command and data FISes. Changes are as follows: 1) 0x16 now additionally indicates an R_ERR received for a COMMAND FIS being sent to a SATA target. 0x16 for SSP still indicates a NAK received for a COMMAND frame. Fix is to retry TC to be compliant with SATA spec or ensure proper error handling of return value (not spec compliant I don't believe). 2) 0x1B was previously called DONE_BREAK_RCVD for STP and DONE_LL_ABORT_ERR for SSP. Now it is universally called DONE_LL_ABORT_ERR. This is purely a superficial change. 3) 0x32 is no longer a reserved code. Now it indicates DONE_CMD_SDMA_ERR for STP/SSP. There was a fatal error on the SDMA for a command IU (includes Raw frames). Consider retry, but at a minimum gracefully fail the request. 4) 0x33 is no longer a reserved code. Now it indicates DONE_CMD_LL_ABORT_ERR for SSP. There was a break receivd during transmission of a command IU. Consider retry, but at a minimum gracefully fail the request. Signed-off-by: Tomasz Chudy <Tomasz.Chudy@intel.com> Signed-off-by: Jacek Danecki <Jacek.Danecki@intel.com> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
-rw-r--r--drivers/scsi/isci/core/scic_sds_stp_request.c2
-rw-r--r--drivers/scsi/isci/core/scu_completion_codes.h3
2 files changed, 5 insertions, 0 deletions
diff --git a/drivers/scsi/isci/core/scic_sds_stp_request.c b/drivers/scsi/isci/core/scic_sds_stp_request.c
index 0b6b0552186a..6d280c0a2fc3 100644
--- a/drivers/scsi/isci/core/scic_sds_stp_request.c
+++ b/drivers/scsi/isci/core/scic_sds_stp_request.c
@@ -1602,9 +1602,11 @@ static enum sci_status scic_sds_stp_request_udma_await_tc_completion_tc_completi
1602 /* 1602 /*
1603 * / @todo Check to see if any of these completion status need to wait for 1603 * / @todo Check to see if any of these completion status need to wait for
1604 * / the device to host register fis. */ 1604 * / the device to host register fis. */
1605 /* / @todo We can retry the command for SCU_TASK_DONE_CMD_LL_R_ERR - this comes only for B0 */
1605 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_INV_FIS_LEN): 1606 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_INV_FIS_LEN):
1606 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_MAX_PLD_ERR): 1607 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_MAX_PLD_ERR):
1607 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_LL_R_ERR): 1608 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_LL_R_ERR):
1609 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_CMD_LL_R_ERR):
1608 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_CRC_ERR): 1610 case SCU_MAKE_COMPLETION_STATUS(SCU_TASK_DONE_CRC_ERR):
1609 scic_sds_remote_device_suspend( 1611 scic_sds_remote_device_suspend(
1610 this_request->parent.target_device, 1612 this_request->parent.target_device,
diff --git a/drivers/scsi/isci/core/scu_completion_codes.h b/drivers/scsi/isci/core/scu_completion_codes.h
index 17ee4c8b9122..c8b329c695f9 100644
--- a/drivers/scsi/isci/core/scu_completion_codes.h
+++ b/drivers/scsi/isci/core/scu_completion_codes.h
@@ -228,6 +228,7 @@
228#define SCU_TASK_DONE_CHECK_RESPONSE ((u32)0x14) 228#define SCU_TASK_DONE_CHECK_RESPONSE ((u32)0x14)
229#define SCU_TASK_DONE_GEN_RESPONSE ((u32)0x15) 229#define SCU_TASK_DONE_GEN_RESPONSE ((u32)0x15)
230#define SCU_TASK_DONE_NAK_CMD_ERR ((u32)0x16) 230#define SCU_TASK_DONE_NAK_CMD_ERR ((u32)0x16)
231#define SCU_TASK_DONE_CMD_LL_R_ERR ((u32)0x16)
231#define SCU_TASK_DONE_LL_R_ERR ((u32)0x17) 232#define SCU_TASK_DONE_LL_R_ERR ((u32)0x17)
232#define SCU_TASK_DONE_ACK_NAK_TO ((u32)0x17) 233#define SCU_TASK_DONE_ACK_NAK_TO ((u32)0x17)
233#define SCU_TASK_DONE_LL_PERR ((u32)0x18) 234#define SCU_TASK_DONE_LL_PERR ((u32)0x18)
@@ -264,6 +265,8 @@
264#define SCU_TASK_DONE_REG_ERR ((u32)0x2E) 265#define SCU_TASK_DONE_REG_ERR ((u32)0x2E)
265#define SCU_TASK_DONE_SDB_ERR ((u32)0x2F) 266#define SCU_TASK_DONE_SDB_ERR ((u32)0x2F)
266#define SCU_TASK_DONE_TASK_ABORT ((u32)0x30) 267#define SCU_TASK_DONE_TASK_ABORT ((u32)0x30)
268#define SCU_TASK_DONE_CMD_SDMA_ERR ((U32)0x32)
269#define SCU_TASK_DONE_CMD_LL_ABORT_ERR ((U32)0x33)
267#define SCU_TASK_OPEN_REJECT_WRONG_DESTINATION ((u32)0x34) 270#define SCU_TASK_OPEN_REJECT_WRONG_DESTINATION ((u32)0x34)
268#define SCU_TASK_OPEN_REJECT_RESERVED_ABANDON_1 ((u32)0x35) 271#define SCU_TASK_OPEN_REJECT_RESERVED_ABANDON_1 ((u32)0x35)
269#define SCU_TASK_OPEN_REJECT_RESERVED_ABANDON_2 ((u32)0x36) 272#define SCU_TASK_OPEN_REJECT_RESERVED_ABANDON_2 ((u32)0x36)