nvmet: remove unsupported command noise
Subsystems (2)
Keith Busch
maintainerPATCH 1/1 nvmet: remove unsupported command noise
Nothing can stop a host from submitting invalid commands. The target just needs to respond with an appropriate status, but that's not a target error. Demote invalid command messages to the debug level so these events don't spam the kernel logs.
--- drivers/nvme/target/admin-cmd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/nvme/target/admin-cmd.c +3 -3
@@ -307,7 +307,7 @@ static void nvmet_execute_get_log_page(struct nvmet_req *req)case NVME_LOG_ANA :return nvmet_execute_get_log_page_ana (req); } -pr_err ("unhandled lid %d on qid %d\n" , +pr_debug ("unhandled lid %d on qid %d\n" , req->cmd->get_log_page.lid, req->sq->qid); req->error_loc = offsetof(struct nvme_get_log_page_command , lid);nvmet_req_complete (req,NVME_SC_INVALID_FIELD |NVME_SC_DNR );
@@ -659,7 +659,7 @@ static void nvmet_execute_identify(struct nvmet_req *req)return nvmet_execute_identify_desclist (req); } -pr_err ("unhandled identify cns %d on qid %d\n" , +pr_debug ("unhandled identify cns %d on qid %d\n" , req->cmd->identify.cns, req->sq->qid); req->error_loc = offsetof(struct nvme_identify , cns);nvmet_req_complete (req,NVME_SC_INVALID_FIELD |NVME_SC_DNR );
@@ -977,7 +977,7 @@ u16 nvmet_parse_admin_cmd(struct nvmet_req *req)return 0 ; } -pr_err ("unhandled cmd %d on qid %d\n" , cmd->common.opcode, +pr_debug ("unhandled cmd %d on qid %d\n" , cmd->common.opcode, req->sq->qid); req->error_loc = offsetof(struct nvme_common_command , opcode);return NVME_SC_INVALID_OPCODE |NVME_SC_DNR ;
Signature · 7 lines
2.25.4 _______________________________________________ Linux-nvme mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-nvme
Quoted 45 lines · Keith Busch
Nothing can stop a host from submitting invalid commands. The target just needs to respond with an appropriate status, but that's not a target error. Demote invalid command messages to the debug level so these events don't spam the kernel logs.
Reported-by Yi Zhang <[email protected]>Signed-off-by Keith Busch <[email protected]>---
drivers/nvme/target/admin-cmd.c| 6 +++---1 file changed, 3 insertions(+), 3 deletions(-)drivers/nvme/target/admin-cmd.c +3
-3@@ -307,7 +307,7 @@ static void nvmet_execute_get_log_page(struct nvmet_req *req)case NVME_LOG_ANA :return nvmet_execute_get_log_page_ana (req); } -pr_err ("unhandled lid %d on qid %d\n" , +pr_debug ("unhandled lid %d on qid %d\n" , req->cmd->get_log_page.lid, req->sq->qid); req->error_loc = offsetof(struct nvme_get_log_page_command , lid);nvmet_req_complete (req,NVME_SC_INVALID_FIELD |NVME_SC_DNR );@@ -659,7 +659,7 @@ static void nvmet_execute_identify(struct nvmet_req *req)return nvmet_execute_identify_desclist (req); } -pr_err ("unhandled identify cns %d on qid %d\n" , +pr_debug ("unhandled identify cns %d on qid %d\n" , req->cmd->identify.cns, req->sq->qid); req->error_loc = offsetof(struct nvme_identify , cns);nvmet_req_complete (req,NVME_SC_INVALID_FIELD |NVME_SC_DNR );@@ -977,7 +977,7 @@ u16 nvmet_parse_admin_cmd(struct nvmet_req *req)return 0 ; } -pr_err ("unhandled cmd %d on qid %d\n" , cmd->common.opcode, +pr_debug ("unhandled cmd %d on qid %d\n" , cmd->common.opcode, req->sq->qid); req->error_loc = offsetof(struct nvme_common_command , opcode);return NVME_SC_INVALID_OPCODE |NVME_SC_DNR ;Signature · 1 line
2.25.4
_______________________________________________
Linux-nvme mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-nvme
Quoted 7 lines · Keith Busch
Nothing can stop a host from submitting invalid commands. The target just needs to respond with an appropriate status, but that's not a target error. Demote invalid command messages to the debug level so these events don't spam the kernel logs.
Reported-by Yi Zhang <[email protected]>Signed-off-by Keith Busch <[email protected]>
Looks good.
_______________________________________________
Linux-nvme mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-nvme
Thanks,
applied to nvme-5.13.
_______________________________________________
Linux-nvme mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-nvme