diff mbox series

[1/2] target: Set response length for REPORT TARGET PORT GROUPS

Message ID 20181020164504.8644-1-roland@kernel.org (mailing list archive)
State New, archived
Headers show
Series [1/2] target: Set response length for REPORT TARGET PORT GROUPS | expand

Commit Message

Roland Dreier Oct. 20, 2018, 4:45 p.m. UTC
From: Roland Dreier <roland@purestorage.com>

One more place where we can return the length we actually fill in.

Signed-off-by: Roland Dreier <roland@purestorage.com>
---
 drivers/target/target_core_alua.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Christoph Hellwig Oct. 22, 2018, 8:56 a.m. UTC | #1
On Sat, Oct 20, 2018 at 09:45:04AM -0700, Roland Dreier wrote:
> From: Roland Dreier <roland@purestorage.com>
> 
> One more place where we can return the length we actually fill in.

Looks good,

Reviewed-by: Christoph Hellwig <hch@lst.de>
Martin K. Petersen Oct. 24, 2018, 1:18 a.m. UTC | #2
Roland,

> One more place where we can return the length we actually fill in.

Applied to 4.20/scsi-queue, thanks!
diff mbox series

Patch

diff --git a/drivers/target/target_core_alua.c b/drivers/target/target_core_alua.c
index e46ca968009c..4f134b0c3e29 100644
--- a/drivers/target/target_core_alua.c
+++ b/drivers/target/target_core_alua.c
@@ -268,7 +268,7 @@  target_emulate_report_target_port_groups(struct se_cmd *cmd)
 	}
 	transport_kunmap_data_sg(cmd);
 
-	target_complete_cmd(cmd, GOOD);
+	target_complete_cmd_with_length(cmd, GOOD, rd_len + 4);
 	return 0;
 }