mirror of
https://github.com/SCST-project/scst.git
synced 2026-10-22 06:02:33 +00:00
isert-scst: Remove empty completion and abort helpers
Manual source review found that isert_task_abort() and isert_data_in_sent() only return zero, and every caller discards that result. Remove the helpers, declarations and calls, including the completion branch used solely to reach the empty helper. Keep PDU completion and DMA unmapping in their existing order.
This commit is contained in:
@@ -284,11 +284,6 @@ int isert_close_connection(struct iscsi_conn *iscsi_conn)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int isert_task_abort(struct iscsi_cmnd *cmnd)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void *isert_get_priv(struct iscsi_conn *iscsi_conn)
|
||||
{
|
||||
struct isert_conn *isert_conn = container_of(iscsi_conn,
|
||||
|
||||
@@ -70,7 +70,6 @@ int isert_send_data_in(struct iscsi_cmnd *cmd, struct iscsi_cmnd *rsp);
|
||||
int isert_send_status(struct iscsi_cmnd *rsp);
|
||||
|
||||
int isert_close_connection(struct iscsi_conn *iscsi_conn);
|
||||
int isert_task_abort(struct iscsi_cmnd *cmnd);
|
||||
void isert_free_connection(struct iscsi_conn *iscsi_conn);
|
||||
|
||||
void isert_release_tx_pdu(struct iscsi_cmnd *iscsi_pdu);
|
||||
@@ -82,7 +81,6 @@ int isert_conn_established(struct iscsi_conn *iscsi_conn,
|
||||
int isert_login_req_rx(struct iscsi_cmnd *login_req);
|
||||
int isert_pdu_rx(struct iscsi_cmnd *pdu);
|
||||
int isert_data_out_ready(struct iscsi_cmnd *cmd);
|
||||
int isert_data_in_sent(struct iscsi_cmnd *cmd);
|
||||
int isert_pdu_sent(struct iscsi_cmnd *pdu);
|
||||
void isert_pdu_err(struct iscsi_cmnd *pdu);
|
||||
|
||||
|
||||
@@ -426,18 +426,9 @@ static void isert_send_completion_handler(struct isert_wr *wr)
|
||||
{
|
||||
struct isert_cmnd *isert_pdu = wr->pdu;
|
||||
struct iscsi_cmnd *iscsi_pdu = &isert_pdu->iscsi;
|
||||
struct iscsi_cmnd *iscsi_req_pdu = iscsi_pdu->parent_req;
|
||||
|
||||
TRACE_ENTRY();
|
||||
|
||||
if (iscsi_req_pdu && iscsi_req_pdu->bufflen) {
|
||||
struct isert_cmnd *isert_req_pdu =
|
||||
container_of(iscsi_req_pdu, struct isert_cmnd, iscsi);
|
||||
|
||||
if (isert_req_pdu->is_rstag_valid)
|
||||
isert_data_in_sent(iscsi_req_pdu);
|
||||
}
|
||||
|
||||
isert_pdu_sent(iscsi_pdu);
|
||||
|
||||
TRACE_EXIT();
|
||||
@@ -465,8 +456,6 @@ static void isert_rdma_wr_completion_handler(struct isert_wr *wr)
|
||||
ib_dma_unmap_sg(ib_dev, isert_buf->sg, isert_buf->sg_cnt,
|
||||
isert_buf->dma_dir);
|
||||
isert_buf->sg_cnt = 0;
|
||||
|
||||
isert_data_in_sent(&wr->pdu->iscsi);
|
||||
}
|
||||
|
||||
SCST_KUNIT_VISIBLE
|
||||
|
||||
@@ -359,11 +359,6 @@ int isert_data_out_ready(struct iscsi_cmnd *cmnd)
|
||||
return res;
|
||||
}
|
||||
|
||||
int isert_data_in_sent(struct iscsi_cmnd *din)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void isert_pdu_err(struct iscsi_cmnd *pdu)
|
||||
{
|
||||
struct iscsi_conn *conn = pdu->conn;
|
||||
|
||||
@@ -438,7 +438,6 @@ static void isert_dev_disconnect(struct iscsi_conn *iscsi_conn)
|
||||
dev->state = CS_DISCONNECTED;
|
||||
dev->conn = NULL;
|
||||
if (dev->login_req) {
|
||||
isert_task_abort(dev->login_req);
|
||||
spin_lock(&dev->pdu_lock);
|
||||
dev->login_req = NULL;
|
||||
spin_unlock(&dev->pdu_lock);
|
||||
|
||||
Reference in New Issue
Block a user