Question regarding async event in target.
by Sreeni (Sreenivasa) Busam (Stellus)
Hello,
I am looking at how to register async events from initiator to target and handle SSD controller errors in the NVMF target. From the code in NVMF, I see there is only 1 async request. Is it not possible to have multiple async requests registered from initiator and handled between initiator and target?
Please let me know how to setup multiple requests at the same time. If you know how different controller errors can be handled, let me know.
spdk_nvmf_session_async_event_request(struct spdk_nvmf_request *req)
{
struct spdk_nvmf_session *session = req->conn->sess;
struct spdk_nvme_cpl *rsp = &req->rsp->nvme_cpl;
assert(session->vcdata.aerl + 1 == 1);
if (session->aer_req != NULL) {
SPDK_TRACELOG(SPDK_TRACE_NVMF, "AERL exceeded\n");
rsp->status.sct = SPDK_NVME_SCT_COMMAND_SPECIFIC;
rsp->status.sc = SPDK_NVME_SC_ASYNC_EVENT_REQUEST_LIMIT_EXCEEDED;
return SPDK_NVMF_REQUEST_EXEC_STATUS_COMPLETE;
}
session->aer_req = req;
I appreciate your help.
Thank you,
Sreeni