diff --git a/iscsi-scst/kernel/conn.c b/iscsi-scst/kernel/conn.c index 3b3fcc511..0b5462856 100644 --- a/iscsi-scst/kernel/conn.c +++ b/iscsi-scst/kernel/conn.c @@ -579,9 +579,9 @@ static void iscsi_write_space_ready(struct sock *sk) return; } -static void conn_rsp_timer_fn(unsigned long arg) +static void conn_rsp_timer_fn(struct timer_list *timer) { - struct iscsi_conn *conn = (struct iscsi_conn *)arg; + struct iscsi_conn *conn = container_of(timer, typeof(*conn), rsp_timer); struct iscsi_cmnd *cmnd; unsigned long j = jiffies; @@ -952,7 +952,7 @@ int iscsi_init_conn(struct iscsi_session *session, spin_lock_init(&conn->write_list_lock); INIT_LIST_HEAD(&conn->write_list); INIT_LIST_HEAD(&conn->write_timeout_list); - setup_timer(&conn->rsp_timer, conn_rsp_timer_fn, (unsigned long)conn); + timer_setup(&conn->rsp_timer, conn_rsp_timer_fn, 0); init_waitqueue_head(&conn->read_state_waitQ); init_completion(&conn->ready_to_free); INIT_LIST_HEAD(&conn->reinst_pending_cmd_list); diff --git a/iscsi-scst/kernel/isert-scst/isert_login.c b/iscsi-scst/kernel/isert-scst/isert_login.c index d1ed53f07..c367fc7bf 100644 --- a/iscsi-scst/kernel/isert-scst/isert_login.c +++ b/iscsi-scst/kernel/isert-scst/isert_login.c @@ -135,9 +135,10 @@ static void isert_close_conn_fn(struct work_struct *work) isert_close_connection(conn); } -static void isert_conn_timer_fn(unsigned long arg) +static void isert_conn_timer_fn(struct timer_list *timer) { - struct isert_conn_dev *conn_dev = (struct isert_conn_dev *)arg; + struct isert_conn_dev *conn_dev = container_of(timer, typeof(*conn_dev), + tmo_timer); struct iscsi_conn *conn = conn_dev->conn; TRACE_ENTRY(); @@ -171,10 +172,8 @@ static int add_new_connection(struct isert_listener_dev *dev, INIT_WORK(&conn->close_work, isert_close_conn_fn); #endif - init_timer(&conn_dev->tmo_timer); - conn_dev->tmo_timer.function = isert_conn_timer_fn; + timer_setup(&conn_dev->tmo_timer, isert_conn_timer_fn, 0); conn_dev->tmo_timer.expires = jiffies + 60 * HZ; - conn_dev->tmo_timer.data = (unsigned long)conn_dev; add_timer(&conn_dev->tmo_timer); conn_dev->timer_active = 1; wake_up(&dev->waitqueue); diff --git a/qla2x00t/qla_init.c b/qla2x00t/qla_init.c index 69bdaa297..410e3cc85 100644 --- a/qla2x00t/qla_init.c +++ b/qla2x00t/qla_init.c @@ -43,10 +43,9 @@ int qla24xx_update_fcport_fcp_prio(scsi_qla_host_t *, fc_port_t *); /* SRB Extensions ---------------------------------------------------------- */ -void -qla2x00_sp_timeout(unsigned long __data) +void qla2x00_sp_timeout(struct timer_list *timer) { - srb_t *sp = (srb_t *)__data; + srb_t *sp = container_of(timer, typeof(*sp), u.iocb_cmd.timer); struct srb_iocb *iocb; fc_port_t *fcport = sp->fcport; struct qla_hw_data *ha = fcport->vha->hw; diff --git a/qla2x00t/qla_inline.h b/qla2x00t/qla_inline.h index 1f9c75860..e73c3a8f4 100644 --- a/qla2x00t/qla_inline.h +++ b/qla2x00t/qla_inline.h @@ -171,10 +171,8 @@ done: static inline void qla2x00_init_timer(srb_t *sp, unsigned long tmo) { - init_timer(&sp->u.iocb_cmd.timer); + timer_setup(&sp->u.iocb_cmd.timer, qla2x00_sp_timeout, 0); sp->u.iocb_cmd.timer.expires = jiffies + tmo * HZ; - sp->u.iocb_cmd.timer.data = (unsigned long)sp; - sp->u.iocb_cmd.timer.function = qla2x00_sp_timeout; add_timer(&sp->u.iocb_cmd.timer); sp->free = qla2x00_sp_free; } diff --git a/qla2x00t/qla_os.c b/qla2x00t/qla_os.c index eb40c5405..d9f518d55 100644 --- a/qla2x00t/qla_os.c +++ b/qla2x00t/qla_os.c @@ -325,10 +325,8 @@ struct scsi_transport_template *qla2xxx_transport_vport_template = NULL; __inline__ void qla2x00_start_timer(scsi_qla_host_t *vha, void *func, unsigned long interval) { - init_timer(&vha->timer); + init_timer(&vha->timer, func, (unsigned long)vha); vha->timer.expires = jiffies + interval * HZ; - vha->timer.data = (unsigned long)vha; - vha->timer.function = (void (*)(unsigned long))func; add_timer(&vha->timer); vha->timer_active = 1; } diff --git a/scst/include/backport.h b/scst/include/backport.h index 88f5fa971..d06230ee4 100644 --- a/scst/include/backport.h +++ b/scst/include/backport.h @@ -680,6 +680,21 @@ struct t10_pi_tuple { }; #endif +/* */ + +#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 14, 0) +/* + * See also commit 686fef928bba ("timer: Prepare to change timer callback + * argument type"). + */ +#define timer_setup(_timer, _fn, _flags) do { \ + init_timer(_timer); \ + (_timer)->function = (void (*)(unsigned long))(_fn); \ + (_timer)->data = (unsigned long)(_timer); \ + (_timer)->flags = (_flags); \ +} while (0) +#endif + /* */ #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 24) diff --git a/scst/src/dev_handlers/scst_vdisk.c b/scst/src/dev_handlers/scst_vdisk.c index ae85318bf..1c5ca2233 100644 --- a/scst/src/dev_handlers/scst_vdisk.c +++ b/scst/src/dev_handlers/scst_vdisk.c @@ -3206,7 +3206,7 @@ find_page: /* * Not cached so create a new page. */ - page = page_cache_alloc_cold(mapping); + page = page_cache_alloc(mapping); if (!page) { error = -ENOMEM; goto err; diff --git a/scst/src/scst_lib.c b/scst/src/scst_lib.c index 850eb2a9b..b6a1f8ffd 100644 --- a/scst/src/scst_lib.c +++ b/scst/src/scst_lib.c @@ -1686,7 +1686,7 @@ static void scst_release_space(struct scst_cmd *cmd); static void scst_clear_reservation(struct scst_tgt_dev *tgt_dev); static int scst_alloc_add_tgt_dev(struct scst_session *sess, struct scst_acg_dev *acg_dev, struct scst_tgt_dev **out_tgt_dev); -static void scst_tgt_retry_timer_fn(unsigned long arg); +static void scst_tgt_retry_timer_fn(struct timer_list *timer); #ifdef CONFIG_SCST_DEBUG_TM static void tm_dbg_init_tgt_dev(struct scst_tgt_dev *tgt_dev); @@ -4116,9 +4116,7 @@ int scst_alloc_tgt(struct scst_tgt_template *tgtt, struct scst_tgt **tgt) t->tgt_supported_dif_block_sizes = tgtt->supported_dif_block_sizes; spin_lock_init(&t->tgt_lock); INIT_LIST_HEAD(&t->retry_cmd_list); - init_timer(&t->retry_timer); - t->retry_timer.data = (unsigned long)t; - t->retry_timer.function = scst_tgt_retry_timer_fn; + timer_setup(&t->retry_timer, scst_tgt_retry_timer_fn, 0); atomic_set(&t->tgt_dif_app_failed_tgt, 0); atomic_set(&t->tgt_dif_ref_failed_tgt, 0); atomic_set(&t->tgt_dif_guard_failed_tgt, 0); @@ -7586,9 +7584,9 @@ void scst_check_retries(struct scst_tgt *tgt) return; } -static void scst_tgt_retry_timer_fn(unsigned long arg) +static void scst_tgt_retry_timer_fn(struct timer_list *timer) { - struct scst_tgt *tgt = (struct scst_tgt *)arg; + struct scst_tgt *tgt = container_of(timer, typeof(*tgt), retry_timer); unsigned long flags; TRACE_RETRY("Retry timer expired (retry_cmds %d)", tgt->retry_cmds); diff --git a/srpt/src/ib_srpt.c b/srpt/src/ib_srpt.c index 3f42e7248..f2b3e2b3e 100644 --- a/srpt/src/ib_srpt.c +++ b/srpt/src/ib_srpt.c @@ -210,7 +210,7 @@ static bool srpt_set_ch_state(struct srpt_rdma_ch *ch, enum rdma_ch_state new) return changed; } -/** +/* * srpt_adjust_req_lim() - Adjust ch->req_lim and ch->req_lim_delta atomically. * * Returns the new value of ch->req_lim. @@ -230,7 +230,7 @@ static int srpt_adjust_req_lim(struct srpt_rdma_ch *ch, int req_lim_change, return req_lim; } -/** +/* * srpt_inc_req_lim() - Increase ch->req_lim and decrease ch->req_lim_delta. * * Returns one more than the previous value of ch->req_lim_delta. @@ -249,7 +249,7 @@ static int srpt_inc_req_lim(struct srpt_rdma_ch *ch) return req_lim_delta; } -/** +/* * srpt_undo_inc_req_lim() - Undo the effect of srpt_inc_req_lim. */ static int srpt_undo_inc_req_lim(struct srpt_rdma_ch *ch, int req_lim_delta) @@ -257,7 +257,7 @@ static int srpt_undo_inc_req_lim(struct srpt_rdma_ch *ch, int req_lim_delta) return srpt_adjust_req_lim(ch, -req_lim_delta, req_lim_delta - 1); } -/** +/* * srpt_event_handler() - Asynchronous IB event callback function. * * Callback function called by the InfiniBand core when an asynchronous IB @@ -316,7 +316,7 @@ static void srpt_event_handler(struct ib_event_handler *handler, } } -/** +/* * srpt_srq_event() - IB SRQ event callback function. */ static void srpt_srq_event(struct ib_event *event, void *ctx) @@ -341,7 +341,7 @@ static const char *get_ch_state_name(enum rdma_ch_state s) return "???"; } -/** +/* * srpt_qp_event() - IB QP event callback function. */ static void srpt_qp_event(struct ib_event *event, struct srpt_rdma_ch *ch) @@ -375,7 +375,7 @@ static void srpt_qp_event(struct ib_event *event, struct srpt_rdma_ch *ch) /** * srpt_set_ioc() - Helper function for initializing an IOUnitInfo structure. - * + * @c_list: I/O controller list. * @slot: one-based slot number. * @value: four-bit value. * @@ -397,7 +397,7 @@ static void srpt_set_ioc(u8 *c_list, u32 slot, u8 value) } } -/** +/* * srpt_get_class_port_info() - Copy ClassPortInfo to a management datagram. * * See also section 16.3.3.1 ClassPortInfo in the InfiniBand Architecture @@ -420,7 +420,7 @@ static void srpt_get_class_port_info(struct ib_dm_mad *mad) mad->mad_hdr.status = 0; } -/** +/* * srpt_get_iou() - Write IOUnitInfo to a management datagram. * * See also section 16.3.3.3 IOUnitInfo in the InfiniBand Architecture @@ -444,7 +444,7 @@ static void srpt_get_iou(struct ib_dm_mad *mad) mad->mad_hdr.status = 0; } -/** +/* * srpt_get_ioc() - Write IOControllerprofile to a management datagram. * * See also section 16.3.3.4 IOControllerProfile in the InfiniBand @@ -502,7 +502,7 @@ static void srpt_get_ioc(struct srpt_port *sport, u32 slot, mad->mad_hdr.status = 0; } -/** +/* * srpt_get_svc_entries() - Write ServiceEntries to a management datagram. * * See also section 16.3.3.5 ServiceEntries in the InfiniBand Architecture @@ -577,7 +577,7 @@ static void srpt_mgmt_method_get(struct srpt_port *sp, struct ib_mad *rq_mad, } } -/** +/* * srpt_mad_send_handler() - Post MAD-send callback function. */ static void srpt_mad_send_handler(struct ib_mad_agent *mad_agent, @@ -591,7 +591,7 @@ static void srpt_mad_send_handler(struct ib_mad_agent *mad_agent, ib_free_send_mad(mad_wc->send_buf); } -/** +/* * srpt_mad_recv_handler() - MAD reception callback function. */ static void srpt_mad_recv_handler(struct ib_mad_agent *mad_agent, @@ -669,7 +669,7 @@ err: ib_free_recv_mad(mad_wc); } -/** +/* * srpt_refresh_port() - Configure a HCA port. * * Enable InfiniBand management datagram processing, update the cached sm_lid, @@ -755,7 +755,7 @@ err_mod_port: return ret; } -/** +/* * srpt_unregister_mad_agent() - Unregister MAD callback functions. * * Note: It is safe to call this function more than once for the same device. @@ -780,7 +780,7 @@ static void srpt_unregister_mad_agent(struct srpt_device *sdev) } } -/** +/* * srpt_alloc_ioctx() - Allocate an SRPT I/O context structure. */ static struct srpt_ioctx *srpt_alloc_ioctx(struct srpt_device *sdev, @@ -821,7 +821,7 @@ err: return NULL; } -/** +/* * srpt_free_ioctx() - Free an SRPT I/O context structure. */ static void srpt_free_ioctx(struct srpt_device *sdev, struct srpt_ioctx *ioctx, @@ -835,7 +835,7 @@ static void srpt_free_ioctx(struct srpt_device *sdev, struct srpt_ioctx *ioctx, kfree(ioctx); } -/** +/* * srpt_alloc_ioctx_ring() - Allocate a ring of SRPT I/O context structures. * @sdev: Device to allocate the I/O context ring for. * @ring_size: Number of elements in the I/O context ring. @@ -875,7 +875,7 @@ out: return ring; } -/** +/* * srpt_free_ioctx_ring() - Free the ring of SRPT I/O context structures. */ static void srpt_free_ioctx_ring(struct srpt_ioctx **ioctx_ring, @@ -893,7 +893,7 @@ static void srpt_free_ioctx_ring(struct srpt_ioctx **ioctx_ring, kfree(ioctx_ring); } -/** +/* * srpt_set_cmd_state() - Set the state of a SCSI command. * @new: New state. * @@ -914,7 +914,7 @@ static enum srpt_command_state srpt_set_cmd_state(struct srpt_send_ioctx *ioctx, return previous; } -/** +/* * srpt_test_and_set_cmd_state() - Test and set the state of a command. * * Returns true if and only if the previous command state was equal to 'old'. @@ -936,7 +936,7 @@ static bool srpt_test_and_set_cmd_state(struct srpt_send_ioctx *ioctx, return previous == old; } -/** +/* * srpt_post_recv() - Post an IB receive request. */ static int srpt_post_recv(struct srpt_device *sdev, struct srpt_rdma_ch *ch, @@ -967,7 +967,7 @@ static int srpt_adjust_sq_wr_avail(struct srpt_rdma_ch *ch, int delta) return atomic_add_return(delta, &ch->sq_wr_avail); } -/** +/* * srpt_post_send() - Post an IB send request. * * Returns zero upon success and a non-zero value upon failure. @@ -1009,7 +1009,7 @@ out: return ret; } -/** +/* * srpt_zerolength_write() - Perform a zero-length RDMA write. * * A quote from the InfiniBand specification: C9-88: For an HCA responder @@ -1028,7 +1028,7 @@ static int srpt_zerolength_write(struct srpt_rdma_ch *ch) return ib_post_send(ch->qp, &wr, &bad_wr); } -/** +/* * srpt_get_desc_tbl() - Parse the data descriptors of an SRP_CMD request. * @ioctx: Pointer to the I/O context associated with the request. * @srp_cmd: Pointer to the SRP_CMD request data. @@ -1175,7 +1175,7 @@ out: return ret; } -/** +/* * srpt_init_ch_qp() - Initialize queue pair attributes. * * Initialized the attributes of queue pair 'qp' by allowing local write, @@ -1277,7 +1277,7 @@ out: return ret; } -/** +/* * srpt_ch_qp_err() - Set the channel queue pair state to 'error'. */ static int srpt_ch_qp_err(struct srpt_rdma_ch *ch) @@ -1295,7 +1295,7 @@ static int srpt_ch_qp_err(struct srpt_rdma_ch *ch) return ret; } -/** +/* * srpt_get_send_ioctx() - Obtain an I/O context for sending to the initiator. */ static struct srpt_send_ioctx *srpt_get_send_ioctx(struct srpt_rdma_ch *ch) @@ -1332,7 +1332,7 @@ static struct srpt_send_ioctx *srpt_get_send_ioctx(struct srpt_rdma_ch *ch) return ioctx; } -/** +/* * srpt_put_send_ioctx() - Free up resources. */ static void srpt_put_send_ioctx(struct srpt_send_ioctx *ioctx) @@ -1430,7 +1430,7 @@ static void srpt_abort_cmd(struct srpt_send_ioctx *ioctx, } } -/** +/* * srpt_handle_send_err_comp() - Process an IB_WC_SEND error completion. */ static void srpt_handle_send_err_comp(struct srpt_rdma_ch *ch, u64 wr_id, @@ -1475,7 +1475,7 @@ static void srpt_handle_send_err_comp(struct srpt_rdma_ch *ch, u64 wr_id, srpt_adjust_sq_wr_avail(ch, wr_avail_delta); } -/** +/* * srpt_handle_send_comp() - Process an IB send completion notification. */ static void srpt_handle_send_comp(struct srpt_rdma_ch *ch, @@ -1513,7 +1513,7 @@ static void srpt_handle_send_comp(struct srpt_rdma_ch *ch, srpt_adjust_sq_wr_avail(ch, wr_avail_delta); } -/** +/* * srpt_handle_rdma_comp() - Process an IB RDMA completion notification. */ static void srpt_handle_rdma_comp(struct srpt_rdma_ch *ch, @@ -1539,7 +1539,7 @@ static void srpt_handle_rdma_comp(struct srpt_rdma_ch *ch, } } -/** +/* * srpt_handle_rdma_err_comp() - Process an IB RDMA error completion. */ static void srpt_handle_rdma_err_comp(struct srpt_rdma_ch *ch, @@ -1694,7 +1694,7 @@ static int srpt_build_tskmgmt_rsp(struct srpt_rdma_ch *ch, return resp_len; } -/** +/* * srpt_handle_cmd() - Process SRP_CMD. */ static int srpt_handle_cmd(struct srpt_rdma_ch *ch, @@ -1761,7 +1761,7 @@ err: return -1; } -/** +/* * srpt_handle_tsk_mgmt() - Process an SRP_TSK_MGMT information unit. * * Each task management function is performed by calling one of the @@ -1971,7 +1971,7 @@ static void srpt_process_wait_list(struct srpt_rdma_ch *ch) ch->processing_wait_list = false; } -/** +/* * srpt_process_send_completion() - Process an IB send completion. * * Note: Although this has not yet been observed during tests, at least in @@ -2086,7 +2086,7 @@ static int srpt_process_completion(struct srpt_rdma_ch *ch, int budget, return processed; } -/** +/* * srpt_completion() - IB completion queue callback function. */ static void srpt_completion(struct ib_cq *cq, void *ctx) @@ -2192,7 +2192,7 @@ static int srpt_compl_thread(void *arg) return 0; } -/** +/* * srpt_create_ch_ib() - Create receive and send completion queues. */ static int srpt_create_ch_ib(struct srpt_rdma_ch *ch) @@ -2313,7 +2313,7 @@ static void srpt_destroy_ch_ib(struct srpt_rdma_ch *ch) ib_destroy_cq(ch->cq); } -/** +/* * srpt_close_ch() - Close an RDMA channel. * * Make sure all resources associated with the channel will be deallocated at @@ -2440,7 +2440,7 @@ static struct srpt_nexus *srpt_get_nexus(struct srpt_port *sport, } #if !defined(CONFIG_SCST_PROC) -/** +/* * srpt_enable_target - Set the "enabled" status of a target. */ static int srpt_enable_target(struct scst_tgt *scst_tgt, bool enable) @@ -2468,7 +2468,7 @@ out: return res; } -/** +/* * srpt_is_target_enabled - Report whether a target is enabled. */ static bool srpt_is_target_enabled(struct scst_tgt *scst_tgt) @@ -2497,7 +2497,7 @@ static u16 srpt_next_comp_vector(struct srpt_port *sport) return comp_vector; } -/** +/* * srpt_cm_req_recv() - Process the IB_CM_REQ_RECEIVED event. * * Ownership of the cm_id is transferred to the target session if this @@ -2668,7 +2668,7 @@ static int srpt_cm_req_recv(struct srpt_device *const sdev, rej->reason = cpu_to_be32(SRP_LOGIN_REJ_INSUFFICIENT_RESOURCES); ret = PTR_ERR(thread); pr_err("failed to create kernel thread: %d\n", ret); - goto unreg_ch; + goto release_channel; } mutex_lock(&sport->mutex); @@ -2774,7 +2774,7 @@ static int srpt_cm_req_recv(struct srpt_device *const sdev, goto out; -unreg_ch: +release_channel: scst_unregister_session(ch->sess, true, NULL); destroy_ib: @@ -2945,7 +2945,7 @@ static void srpt_check_timeout(struct srpt_rdma_ch *ch) } } -/** +/* * srpt_cm_rtu_recv() - Process RTU event. * * An RTU (ready to use) message indicates that the connection has been @@ -2975,7 +2975,7 @@ static void srpt_cm_rtu_recv(struct srpt_rdma_ch *ch) ch->sess_name, ch->qp->qp_num); } -/** +/* * srpt_cm_handler() - IB connection manager callback function. * * A non-zero return value will cause the caller destroy the CM ID. @@ -3077,7 +3077,7 @@ static int srpt_rdma_cm_handler(struct rdma_cm_id *cm_id, return ret; } -/** +/* * srpt_map_sg_to_ib_sge() - Map an SG list to an IB SGE list. */ static int srpt_map_sg_to_ib_sge(struct srpt_rdma_ch *ch, @@ -3270,7 +3270,7 @@ free_mem: return -ENOMEM; } -/** +/* * srpt_unmap_sg_to_ib_sge() - Unmap an IB SGE list. */ static void srpt_unmap_sg_to_ib_sge(struct srpt_rdma_ch *ch, @@ -3305,7 +3305,7 @@ static void srpt_unmap_sg_to_ib_sge(struct srpt_rdma_ch *ch, } } -/** +/* * srpt_perform_rdmas() - Perform IB RDMA. * * Returns zero upon success or a negative number upon failure. @@ -3447,7 +3447,7 @@ out: return ret; } -/** +/* * srpt_xfer_data() - Start data transfer from initiator to target. * * Returns 0, -EAGAIN or -EIO. @@ -3519,7 +3519,7 @@ out_unmap: goto out; } -/** +/* * srpt_pending_cmd_timeout() - SCST command HCA processing timeout callback. * * Called by the SCST core if no IB completion notification has been received @@ -3557,7 +3557,7 @@ static void srpt_pending_cmd_timeout(struct scst_cmd *cmd) srpt_abort_cmd(ioctx, SCST_CONTEXT_SAME); } -/** +/* * srpt_rdy_to_xfer() - Transfers data from initiator to target. * * Called by the SCST core to transfer data from the initiator to the target @@ -3584,7 +3584,7 @@ static int srpt_rdy_to_xfer(struct scst_cmd *cmd) } } -/** +/* * srpt_xmit_response() - Transmits the response to a SCSI command. * * Callback function called by the SCST core. Must not block. Must ensure that @@ -3675,7 +3675,7 @@ out: return ret; } -/** +/* * srpt_tsk_mgmt_done() - SCST callback function that sends back the response * for a task management request. * @@ -3719,7 +3719,7 @@ static void srpt_tsk_mgmt_done(struct scst_mgmt_cmd *mcmnd) } } -/** +/* * srpt_get_initiator_port_transport_id() - SCST TransportID callback function. * * See also SPC-3, section 7.5.4.5, TransportID for initiator ports using SRP. @@ -3760,7 +3760,7 @@ out: return res; } -/** +/* * srpt_on_free_cmd() - Free command-private data. * * Called by the SCST core. May be called in IRQ context. @@ -3815,7 +3815,7 @@ static bool srpt_ch_list_empty(struct srpt_port *sport) return res; } -/** +/* * srpt_release_sport() - Free channel resources associated with a target. */ static int srpt_release_sport(struct srpt_port *sport) @@ -3858,7 +3858,7 @@ static int srpt_release_sport(struct srpt_port *sport) return 0; } -/** +/* * srpt_release() - Free the resources associated with an SCST target. * * Callback function called by the SCST core from scst_unregister_target(). @@ -3879,7 +3879,7 @@ static int srpt_release(struct scst_tgt *scst_tgt) return 0; } -/** +/* * srpt_get_scsi_transport_version() - Returns the SCSI transport version. * This function is called from scst_pres.c, the code that implements * persistent reservation support. @@ -4250,7 +4250,7 @@ static void srpt_init_sport(struct srpt_port *sport, struct ib_device *ib_dev) cpumask_set_cpu(i, &sport->comp_v_mask); } -/** +/* * srpt_add_one() - Infiniband device addition callback function. */ static void srpt_add_one(struct ib_device *device) @@ -4428,7 +4428,7 @@ err: goto out; } -/** +/* * srpt_remove_one() - InfiniBand device removal callback function. */ #ifndef IB_CLIENT_REMOVE_TAKES_TWO_ARGS @@ -4504,7 +4504,7 @@ static struct ib_client srpt_client = { #ifdef CONFIG_SCST_PROC -/** +/* * srpt_register_procfs_entry() - Create SRPT procfs entries. * * Currently the only procfs entry created by this function is the @@ -4536,7 +4536,7 @@ static int srpt_register_procfs_entry(struct scst_tgt_template *tgt) return res; } -/** +/* * srpt_unregister_procfs_entry() - Unregister SRPT procfs entries. */ static void srpt_unregister_procfs_entry(struct scst_tgt_template *tgt) diff --git a/srpt/src/ib_srpt.h b/srpt/src/ib_srpt.h index 62a5eccd0..a956d1827 100644 --- a/srpt/src/ib_srpt.h +++ b/srpt/src/ib_srpt.h @@ -469,6 +469,7 @@ struct srpt_device { struct ib_event_handler event_handler; }; +#if 0 /** * struct srp_login_req_rdma - RDMA/CM login parameters. * @@ -489,3 +490,4 @@ struct srp_login_req_rdma { }; #endif /* IB_SRPT_H */ +#endif