Skip to contentSkip to conversation

i3c/master: cmd_v1: Fix the exit criteria for the daa procedure

PATCH In review Billy Tsai 2 participants 3 messages Aug 23, 2024 – Aug 26, 2024 I3C

lore
Share & tools
lore

Billy Tsai

author
#0 lore raw

PATCH 1/1 i3c/master: cmd_v1: Fix the exit criteria for the daa procedure

The exit criteria for the DAA should check if the data length is equal to 1, instead of checking if the response status is equal to 1.

---
 drivers/i3c/master/mipi-i3c-hci/cmd_v1.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/i3c/master/mipi-i3c-hci/cmd_v1.c +1 -1
index d97c3175e0e2..6a781f89b0e4 100644
@@ -339,7 +339,7 @@ static int hci_cmd_v1_daa(struct i3c_hci *hci)
 			break;
 		}
 		if (RESP_STATUS(xfer[0].response) == RESP_ERR_NACK &&
-		    RESP_STATUS(xfer[0].response) == 1) {
+		    RESP_DATA_LENGTH(xfer->response) == 1) {
 			ret = 0;  /* no more devices to be assigned */
 			break;
 		}
Signature · 1 line
2.25.1
#1 lore raw

Hi

Quoted 13 lines · Billy Tsai

The exit criteria for the DAA should check if the data length is equal to 1, instead of checking if the response status is equal to 1.

---
  drivers/i3c/master/mipi-i3c-hci/cmd_v1.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/i3c/master/mipi-i3c-hci/cmd_v1.c +0 -0
index d97c3175e0e2..6a781f89b0e4 100644

drivers/i3c/master/mipi-i3c-hci/cmd_v1.c static int hci_cmd_v1_daa(struct i3c_hci *hci) · line 345

Quoted 8 lines
drivers/i3c/master/mipi-i3c-hci/cmd_v1.c +1 -1
@@ -339,7 +339,7 @@ static int hci_cmd_v1_daa(struct i3c_hci *hci)
  			break;
  		}
  		if (RESP_STATUS(xfer[0].response) == RESP_ERR_NACK &&
-		    RESP_STATUS(xfer[0].response) == 1) {
+		    RESP_DATA_LENGTH(xfer->response) == 1) {
  			ret = 0;  /* no more devices to be assigned */
  			break;
  		}

Did you accidentally resend this from a local tree? Is this the same than your commit cbf871e6d8ce ("i3c/master: cmd_v1: Fix the exit criteria for the daa procedure")?

author
#2 lore raw
Quoted 8 lines
Quoted 8 lines

The exit criteria for the DAA should check if the data length is equal to 1, instead of checking if the response status is equal to 1.

---
  drivers/i3c/master/mipi-i3c-hci/cmd_v1.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 16 lines

drivers/i3c/master/mipi-i3c-hci/cmd_v1.c static int hci_cmd_v1_daa(struct i3c_hci *hci) · line 345

Quoted 13 lines
drivers/i3c/master/mipi-i3c-hci/cmd_v1.c +1 -1
index d97c3175e0e2..6a781f89b0e4 100644
@@ -339,7 +339,7 @@ static int hci_cmd_v1_daa(struct i3c_hci *hci)
                       break;
               }
               if (RESP_STATUS(xfer[0].response) == RESP_ERR_NACK &&
-                 RESP_STATUS(xfer[0].response) == 1) {
+                 RESP_DATA_LENGTH(xfer->response) == 1) {
                       ret = 0;  /* no more devices to be assigned */
                       break;
               }

Did you accidentally resend this from a local tree? Is this the same than your commit cbf871e6d8ce ("i3c/master: cmd_v1: Fix the exit criteria for the daa procedure")?

Sorry, I have re-sent the previous patch from my local machine.