浏览代码

pscsi: fix REPORT LUNS handling

We need to assign spc_emulate_report_luns to the execute_cmd callback
and not execute it directly.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Christoph Hellwig 13 年之前
父节点
当前提交
e6c4219b54
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      drivers/target/target_core_pscsi.c

+ 2 - 1
drivers/target/target_core_pscsi.c

@@ -1001,7 +1001,8 @@ static int pscsi_parse_cdb(struct se_cmd *cmd)
 	 */
 	switch (cdb[0]) {
 	case REPORT_LUNS:
-		return spc_emulate_report_luns(cmd);
+		cmd->execute_cmd = spc_emulate_report_luns;
+		return 0;
 	case READ_6:
 	case READ_10:
 	case READ_12: