Spring cleanup
Subsystems (5)
cover Spring cleanup
From: Leon Romanovsky <[email protected]>
Bunch of cleanup in RDMA subsystem.
Leon Romanovsky (2):
RDMA: Fix kernel-doc compilation warnings
RDMA: Delete not-used static inline functions
drivers/infiniband/hw/cxgb4/iw_cxgb4.h | 11 ------ drivers/infiniband/hw/cxgb4/t4.h | 33 ----------------- drivers/infiniband/hw/hfi1/chip.c | 4 +-- drivers/infiniband/hw/hfi1/chip.h | 5 --- drivers/infiniband/hw/hfi1/driver.c | 2 +- drivers/infiniband/hw/hfi1/exp_rcv.c | 6 ++-- drivers/infiniband/hw/hfi1/hfi.h | 6 ---- drivers/infiniband/hw/hfi1/init.c | 3 +- drivers/infiniband/hw/hfi1/msix.c | 12 +++---- drivers/infiniband/hw/hfi1/netdev_rx.c | 2 +- drivers/infiniband/hw/hfi1/sdma.c | 2 +- drivers/infiniband/hw/hfi1/verbs_txreq.h | 5 --- drivers/infiniband/hw/i40iw/i40iw.h | 9 ----- drivers/infiniband/hw/i40iw/i40iw_cm.c | 4 +-- drivers/infiniband/hw/i40iw/i40iw_hmc.c | 4 +-- drivers/infiniband/hw/i40iw/i40iw_main.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_osdep.h | 22 ------------ drivers/infiniband/hw/i40iw/i40iw_puda.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_utils.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 4 +-- drivers/infiniband/hw/i40iw/i40iw_virtchnl.c | 2 +- drivers/infiniband/hw/qib/qib.h | 26 -------------- drivers/infiniband/hw/qib/qib_common.h | 7 ---- drivers/infiniband/hw/qib/qib_file_ops.c | 5 +-- drivers/infiniband/hw/qib/qib_iba6120.c | 2 +- drivers/infiniband/hw/qib/qib_iba7220.c | 4 +-- drivers/infiniband/hw/qib/qib_iba7322.c | 4 +-- drivers/infiniband/hw/qib/qib_init.c | 2 +- drivers/infiniband/hw/vmw_pvrdma/pvrdma.h | 10 ------ drivers/infiniband/hw/vmw_pvrdma/pvrdma_qp.c | 2 +- .../infiniband/hw/vmw_pvrdma/pvrdma_verbs.h | 35 ------------------- drivers/infiniband/sw/siw/iwarp.h | 13 ------- drivers/infiniband/sw/siw/siw_mem.h | 5 --- 33 files changed, 36 insertions(+), 221 deletions(-)
--
2.30.2
PATCH 1/2 RDMA: Fix kernel-doc compilation warnings
From: Leon Romanovsky <[email protected]>
This patch fixes bunch of kernel-doc compilation warnings like below:
drivers/infiniband/hw/i40iw/i40iw_cm.c:4372: warning: expecting prototype for i40iw_ifdown_notify(). Prototype was for i40iw_if_notify() instead
--- drivers/infiniband/hw/hfi1/chip.c | 4 ++-- drivers/infiniband/hw/hfi1/driver.c | 2 +- drivers/infiniband/hw/hfi1/exp_rcv.c | 6 +++--- drivers/infiniband/hw/hfi1/init.c | 3 ++- drivers/infiniband/hw/hfi1/msix.c | 12 ++++++------ drivers/infiniband/hw/hfi1/netdev_rx.c | 2 +- drivers/infiniband/hw/hfi1/sdma.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_cm.c | 4 ++-- drivers/infiniband/hw/i40iw/i40iw_hmc.c | 4 ++-- drivers/infiniband/hw/i40iw/i40iw_main.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_puda.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_utils.c | 2 +- drivers/infiniband/hw/i40iw/i40iw_verbs.c | 4 ++-- drivers/infiniband/hw/i40iw/i40iw_virtchnl.c | 2 +- drivers/infiniband/hw/qib/qib_file_ops.c | 5 +++-- drivers/infiniband/hw/qib/qib_iba6120.c | 2 +- drivers/infiniband/hw/qib/qib_iba7220.c | 4 ++-- drivers/infiniband/hw/qib/qib_iba7322.c | 4 ++-- drivers/infiniband/hw/qib/qib_init.c | 2 +- drivers/infiniband/hw/vmw_pvrdma/pvrdma_qp.c | 2 +- 20 files changed, 36 insertions(+), 34 deletions(-)
drivers/infiniband/hw/hfi1/chip.c +2 -2
@@ -1322,7 +1322,7 @@ CNTR_ELEM(#name, \ access_ibp_##cntr)/** -* hfi_addr_from_offset - return addr for readq/writeq +* hfi1_addr_from_offset - return addr for readq/writeq * @dd: the dd device * @offset: the offset of the CSR within bar0 *
@@ -8316,7 +8316,7 @@ static void is_interrupt(struct hfi1_devdata *dd, unsigned int source) }/** -* gerneral_interrupt() - General interrupt handler +* general_interrupt - General interrupt handler * @irq: MSIx IRQ vector * @data: hfi1 devdata *
drivers/infiniband/hw/hfi1/driver.c +1 -1
@@ -1026,7 +1026,7 @@ static bool __set_armed_to_active(struct hfi1_packet *packet) }/** -* armed to active - the fast path for armed to active +* set_armed_to_active - the fast path for armed to active * @packet: the packet structure * * Return true if packet processing needs to bail.
drivers/infiniband/hw/hfi1/exp_rcv.c +3 -3
@@ -49,7 +49,7 @@#include "trace.h" /** -* exp_tid_group_init - initialize exp_tid_set +* hfi1_exp_tid_set_init - initialize exp_tid_set * @set: the set */ static void hfi1_exp_tid_set_init (struct exp_tid_set *set)
@@ -70,7 +70,7 @@ void hfi1_exp_tid_group_init(struct hfi1_ctxtdata *rcd) }/** -* alloc_ctxt_rcv_groups - initialize expected receive groups +* hfi1_alloc_ctxt_rcv_groups - initialize expected receive groups * @rcd: the context to add the groupings to */ int hfi1_alloc_ctxt_rcv_groups (struct hfi1_ctxtdata *rcd)
@@ -100,7 +100,7 @@ int hfi1_alloc_ctxt_rcv_groups(struct hfi1_ctxtdata *rcd) }/** -* free_ctxt_rcv_groups - free expected receive groups +* hfi1_free_ctxt_rcv_groups - free expected receive groups * @rcd: the context to free * * The routine dismantles the expect receive linked
drivers/infiniband/hw/hfi1/init.c +2 -1
@@ -1852,7 +1852,8 @@ int hfi1_create_rcvhdrq(struct hfi1_devdata *dd, struct hfi1_ctxtdata *rcd) }/** -* allocate eager buffers, both kernel and user contexts. +* hfi1_setup_eagerbufs - llocate eager buffers, both kernel and user +* contexts. * @rcd: the context we are setting up. * * Allocate the eager TID buffers and program them into hip.
drivers/infiniband/hw/hfi1/msix.c +6 -6
@@ -206,7 +206,7 @@ int msix_request_rcd_irq(struct hfi1_ctxtdata *rcd) }/** -* msix_request_rcd_irq() - Helper function for RCVAVAIL IRQs +* msix_netdev_request_rcd_irq - Helper function for RCVAVAIL IRQs * for netdev context * @rcd: valid netdev contexti */
@@ -221,7 +221,7 @@ int msix_netdev_request_rcd_irq(struct hfi1_ctxtdata *rcd) }/** -* msix_request_smda_ira() - Helper for getting SDMA IRQ resources +* msix_request_sdma_irq - Helper for getting SDMA IRQ resources * @sde: valid sdma engine * */
@@ -243,7 +243,7 @@ int msix_request_sdma_irq(struct sdma_engine *sde) }/** -* msix_request_general_irq(void) - Helper for getting general IRQ +* msix_request_general_irq - Helper for getting general IRQ * resources * @dd: valid device data */
@@ -269,7 +269,7 @@ int msix_request_general_irq(struct hfi1_devdata *dd) }/** -* enable_sdma_src() - Helper to enable SDMA IRQ srcs +* enable_sdma_srcs - Helper to enable SDMA IRQ srcs * @dd: valid devdata structure * @i: index of SDMA engine */
@@ -349,7 +349,7 @@ void msix_free_irq(struct hfi1_devdata *dd, u8 msix_intr) }/** -* hfi1_clean_up_msix_interrupts() - Free all MSIx IRQ resources +* msix_clean_up_interrupts - Free all MSIx IRQ resources * @dd: valid device data data structure * * Free the MSIx and associated PCI resources, if they have been allocated.
@@ -372,7 +372,7 @@ void msix_clean_up_interrupts(struct hfi1_devdata *dd) }/** -* msix_netdev_syncrhonize_irq() - netdev IRQ synchronize +* msix_netdev_synchronize_irq - netdev IRQ synchronize * @dd: valid devdata */ void msix_netdev_synchronize_irq (struct hfi1_devdata *dd)
drivers/infiniband/hw/hfi1/netdev_rx.c +1 -1
@@ -464,7 +464,7 @@ void *hfi1_netdev_get_data(struct hfi1_devdata *dd, int id) }/** -* hfi1_netdev_get_first_dat - Gets first entry with greater or equal id. +* hfi1_netdev_get_first_data - Gets first entry with greater or equal id. * * @dd: hfi1 dev data * @start_id: requested integer id up to INT_MAX
drivers/infiniband/hw/hfi1/sdma.c +1 -1
@@ -1285,7 +1285,7 @@ int sdma_map_init(struct hfi1_devdata *dd, u8 port, u8 num_vls, u8 *vl_engines) }/** -* sdma_clean() Clean up allocated memory +* sdma_clean - Clean up allocated memory * @dd: struct hfi1_devdata * @num_engines: num sdma engines *
drivers/infiniband/hw/i40iw/i40iw_cm.c +2 -2
@@ -905,7 +905,7 @@ static int i40iw_send_mpa_reject(struct i40iw_cm_node *cm_node, }/** -* recv_mpa - process an IETF MPA frame +* i40iw_parse_mpa - process an IETF MPA frame * @cm_node: connection's node * @buffer: Data pointer * @type: to return accept or reject
@@ -4360,7 +4360,7 @@ void i40iw_cm_teardown_connections(struct i40iw_device *iwdev, u32 *ipaddr, }/** -* i40iw_ifdown_notify - process an ifdown on an interface +* i40iw_if_notify - process an ifdown on an interface * @iwdev: device pointer * @netdev: network interface device structure * @ipaddr: Pointer to IPv4 or IPv6 address
drivers/infiniband/hw/i40iw/i40iw_hmc.c +2 -2
@@ -285,7 +285,7 @@ static enum i40iw_status_code i40iw_hmc_finish_add_sd_reg(struct i40iw_sc_dev *d }/** -* i40iw_create_iw_hmc_obj - allocate backing store for hmc objects +* i40iw_sc_create_hmc_obj - allocate backing store for hmc objects * @dev: pointer to the device structure * @info: pointer to i40iw_hmc_iw_create_obj_info struct *
@@ -434,7 +434,7 @@ static enum i40iw_status_code i40iw_finish_del_sd_reg(struct i40iw_sc_dev *dev, }/** -* i40iw_del_iw_hmc_obj - remove pe hmc objects +* i40iw_sc_del_hmc_obj - remove pe hmc objects * @dev: pointer to the device structure * @info: pointer to i40iw_hmc_del_obj_info struct * @reset: true if called before reset
drivers/infiniband/hw/i40iw/i40iw_main.c +1 -1
@@ -251,7 +251,7 @@ static void i40iw_destroy_cqp(struct i40iw_device *iwdev, bool free_hwcqp) }/** -* i40iw_disable_irqs - disable device interrupts +* i40iw_disable_irq - disable device interrupts * @dev: hardware control device structure * @msix_vec: msix vector to disable irq * @dev_id: parameter to pass to free_irq (used during irq setup)
drivers/infiniband/hw/i40iw/i40iw_puda.c +1 -1
@@ -1000,7 +1000,7 @@ static void i40iw_ilq_putback_rcvbuf(struct i40iw_sc_qp *qp, u32 wqe_idx) }/** -* i40iw_ieq_get_fpdu - given length return fpdu length +* i40iw_ieq_get_fpdu_length - given length return fpdu length * @length: length if fpdu */ static u16 i40iw_ieq_get_fpdu_length (u16 length)
drivers/infiniband/hw/i40iw/i40iw_utils.c +1 -1
@@ -890,7 +890,7 @@ void i40iw_terminate_done(struct i40iw_sc_qp *qp, int timeout_occurred) }/** -* i40iw_terminate_imeout - timeout happened +* i40iw_terminate_timeout - timeout happened * @t: points to iwarp qp */ static void i40iw_terminate_timeout (struct timer_list *t)
drivers/infiniband/hw/i40iw/i40iw_verbs.c +2 -2
@@ -647,7 +647,7 @@ static struct ib_qp *i40iw_create_qp(struct ib_pd *ibpd, }/** -* i40iw_query - query qp attributes +* i40iw_query_qp - query qp attributes * @ibqp: qp pointer * @attr: attributes pointer * @attr_mask: Not used
@@ -1846,7 +1846,7 @@ static struct ib_mr *i40iw_get_dma_mr(struct ib_pd *pd, int acc) }/** -* i40iw_del_mem_list - Deleting pbl list entries for CQ/QP +* i40iw_del_memlist - Deleting pbl list entries for CQ/QP * @iwmr: iwmr for IB's user page addresses * @ucontext: ptr to user context */
drivers/infiniband/hw/i40iw/i40iw_virtchnl.c +1 -1
@@ -333,7 +333,7 @@ static void pf_cqp_get_hmc_fcn_callback(struct i40iw_sc_dev *dev, void *callback }/** -* pf_add_hmc_obj - Callback for Add HMC Object +* pf_add_hmc_obj_callback - Callback for Add HMC Object * @work_vf_dev: pointer to the VF Device */ static void pf_add_hmc_obj_callback (void *work_vf_dev)
drivers/infiniband/hw/qib/qib_file_ops.c +3 -2
@@ -1758,7 +1758,8 @@ static int qib_do_user_init(struct file *fp, }/** -* unlock_exptid - unlock any expected TID entries context still had in use +* unlock_expected_tids - unlock any expected TID entries context still had +* in use * @rcd: ctxt * * We don't actually update the chip here, because we do a bulk update
@@ -2247,7 +2248,7 @@ static ssize_t qib_write_iter(struct kiocb *iocb, struct iov_iter *from)if (!iter_is_iovec (from) || !from->nr_segs || !pq)return -EINVAL ; - +return qib_user_sdma_writev (rcd, pq, from->iov, from->nr_segs); }
drivers/infiniband/hw/qib/qib_iba6120.c +1 -1
@@ -2609,7 +2609,7 @@ static void qib_chk_6120_errormask(struct qib_devdata *dd) }/** -* qib_get_faststats - get word counters from chip before they overflow +* qib_get_6120_faststats - get word counters from chip before they overflow * @t: contains a pointer to the qlogic_ib device qib_devdata * * This needs more work; in particular, decision on whether we really
drivers/infiniband/hw/qib/qib_iba7220.c +2 -2
@@ -2236,7 +2236,7 @@ static void qib_7220_tidtemplate(struct qib_devdata *dd) }/** -* qib_init_7220_get_base_info - set chip-specific flags for user code +* qib_7220_get_base_info - set chip-specific flags for user code * @rcd: the qlogic_ib ctxt * @kinfo: qib_base_info pointer *
@@ -4411,7 +4411,7 @@ static void writescratch(struct qib_devdata *dd, u32 val)#define VALID_TS_RD_REG_MASK 0xBF/** -* qib_7220_tempsense_read - read register of temp sensor via TWSI +* qib_7220_tempsense_rd - read register of temp sensor via TWSI * @dd: the qlogic_ib device * @regnum: register to read from *
drivers/infiniband/hw/qib/qib_iba7322.c +2 -2
@@ -2513,7 +2513,7 @@ static int qib_7322_bringup_serdes(struct qib_pportdata *ppd) }/** -* qib_7322_quiet_serdes - set serdes to txidle +* qib_7322_mini_quiet_serdes - set serdes to txidle * @ppd: the qlogic_ib device * Called when driver is being unloaded */
@@ -3859,7 +3859,7 @@ static void qib_7322_tidtemplate(struct qib_devdata *dd) }/** -* qib_init_7322_get_base_info - set chip-specific flags for user code +* qib_7322_get_base_info - set chip-specific flags for user code * @rcd: the qlogic_ib ctxt * @kinfo: qib_base_info pointer *
drivers/infiniband/hw/qib/qib_init.c +1 -1
@@ -1609,7 +1609,7 @@ int qib_create_rcvhdrq(struct qib_devdata *dd, struct qib_ctxtdata *rcd) }/** -* allocate eager buffers, both kernel and user contexts. +* qib_setup_eagerbufs - allocate eager buffers, both kernel and user contexts. * @rcd: the context we are setting up. * * Allocate the eager TID buffers and program them into hip.
drivers/infiniband/hw/vmw_pvrdma/pvrdma_qp.c +1 -1
@@ -882,7 +882,7 @@ int pvrdma_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr, }/** -* pvrdma_post_receive - post receive work request entries on a QP +* pvrdma_post_recv - post receive work request entries on a QP * @ibqp: the QP * @wr: the work request list to post * @bad_wr: the first bad WR returned
Signature · 1 line
2.30.2
PATCH 2/2 RDMA: Delete not-used static inline functions
In reply to Leon RomanovskyFrom: Leon Romanovsky <[email protected]>
Perform mass deletion of static inline functions that are not used.
--- drivers/infiniband/hw/cxgb4/iw_cxgb4.h | 11 ------ drivers/infiniband/hw/cxgb4/t4.h | 33 ----------------- drivers/infiniband/hw/hfi1/chip.h | 5 --- drivers/infiniband/hw/hfi1/hfi.h | 6 ---- drivers/infiniband/hw/hfi1/verbs_txreq.h | 5 --- drivers/infiniband/hw/i40iw/i40iw.h | 9 ----- drivers/infiniband/hw/i40iw/i40iw_osdep.h | 22 ------------ drivers/infiniband/hw/qib/qib.h | 26 -------------- drivers/infiniband/hw/qib/qib_common.h | 7 ---- drivers/infiniband/hw/vmw_pvrdma/pvrdma.h | 10 ------ .../infiniband/hw/vmw_pvrdma/pvrdma_verbs.h | 35 ------------------- drivers/infiniband/sw/siw/iwarp.h | 13 ------- drivers/infiniband/sw/siw/siw_mem.h | 5 --- 13 files changed, 187 deletions(-)
drivers/infiniband/hw/cxgb4/iw_cxgb4.h +0 -11
@@ -341,11 +341,6 @@ static inline struct c4iw_dev *to_c4iw_dev(struct ib_device *ibdev) return container_of(ibdev, struct c4iw_dev, ibdev); } -static inline struct c4iw_dev *rdev_to_c4iw_dev (struct c4iw_rdev *rdev) -{ - return container_of(rdev, struct c4iw_dev, rdev); -} -static inline struct c4iw_cq *get_chp (struct c4iw_dev *rhp,u32 cqid) {return xa_load (&rhp->cqs, cqid);
@@ -659,12 +654,6 @@ static inline u32 c4iw_ib_to_tpt_access(int a)FW_RI_MEM_ACCESS_LOCAL_READ ; } -static inline u32 c4iw_ib_to_tpt_bind_access (int acc) -{ -return (acc &IB_ACCESS_REMOTE_WRITE ?FW_RI_MEM_ACCESS_REM_WRITE :0 ) | - (acc &IB_ACCESS_REMOTE_READ ?FW_RI_MEM_ACCESS_REM_READ :0 ); -} -enum c4iw_mmid_state {C4IW_STAG_STATE_VALID ,C4IW_STAG_STATE_INVALID
drivers/infiniband/hw/cxgb4/t4.h +0 -33
@@ -487,11 +487,6 @@ static inline int t4_rq_empty(struct t4_wq *wq)return wq->rq.in_use ==0 ; } -static inline int t4_rq_full (struct t4_wq *wq) -{ -return wq->rq.in_use == (wq->rq.size -1 ); -} -static inline u32 t4_rq_avail (struct t4_wq *wq) {return wq->rq.size -1 - wq->rq.in_use;
@@ -534,11 +529,6 @@ static inline int t4_sq_empty(struct t4_wq *wq)return wq->sq.in_use ==0 ; } -static inline int t4_sq_full (struct t4_wq *wq) -{ -return wq->sq.in_use == (wq->sq.size -1 ); -} -static inline u32 t4_sq_avail (struct t4_wq *wq) {return wq->sq.size -1 - wq->sq.in_use;
@@ -679,11 +669,6 @@ static inline void t4_enable_wq_db(struct t4_wq *wq) wq->rq.queue[wq->rq.size].status.db_off =0 ; } -static inline int t4_wq_db_enabled (struct t4_wq *wq) -{ -return !wq->rq.queue[wq->rq.size].status.db_off; -} -enum t4_cq_flags {CQ_ARMED =1 , };
@@ -817,19 +802,6 @@ static inline int t4_next_hw_cqe(struct t4_cq *cq, struct t4_cqe **cqe)return ret; } -static inline struct t4_cqe *t4_next_sw_cqe (struct t4_cq *cq) -{ -if (cq->sw_in_use == cq->size) { -pr_warn ("%s cxgb4 sw cq overflow cqid %u\n" , - __func__, cq->cqid); - cq->error =1 ; -return NULL ; - } -if (cq->sw_in_use) -return &cq->sw_queue[cq->sw_cidx]; -return NULL ; -} -static inline int t4_next_cqe (struct t4_cq *cq,struct t4_cqe **cqe) {int ret =0 ;
@@ -843,11 +815,6 @@ static inline int t4_next_cqe(struct t4_cq *cq, struct t4_cqe **cqe)return ret; } -static inline int t4_cq_in_error (struct t4_cq *cq) -{ -return *cq->qp_errp; -} -static inline void t4_set_cq_in_error (struct t4_cq *cq) { *cq->qp_errp =1 ;
drivers/infiniband/hw/hfi1/chip.h +0 -5
@@ -822,11 +822,6 @@ int acquire_lcb_access(struct hfi1_devdata *dd, int sleep_ok);int release_lcb_access (struct hfi1_devdata *dd,int sleep_ok);#define LCB_START DC_LCB_CSRS#define LCB_END DC_8051_CSRS/* next block is 8051 */ -static inline int is_lcb_offset (u32 offset) -{ -return (offset >=LCB_START && offset <LCB_END ); -} -extern uint num_vls;extern uint disable_integrity;
drivers/infiniband/hw/hfi1/hfi.h +0 -6
@@ -717,12 +717,6 @@ static inline void incr_cntr64(u64 *cntr) (*cntr)++; } -static inline void incr_cntr32 (u32 *cntr) -{ -if (*cntr < (u32)-1LL ) - (*cntr)++; -} -#define MAX_NAME_SIZE 64struct hfi1_msix_entry {enum irq_type type;
drivers/infiniband/hw/hfi1/verbs_txreq.h +0 -5
@@ -99,11 +99,6 @@ static inline struct verbs_txreq *get_txreq(struct hfi1_ibdev *dev,return tx; } -static inline struct sdma_txreq *get_sdma_txreq (struct verbs_txreq *tx) -{ -return &tx->txreq; -} -static inline struct verbs_txreq *get_waiting_verbs_txreq (struct iowait_work *w) {struct sdma_txreq *stx;
drivers/infiniband/hw/i40iw/i40iw.h +0 -9
@@ -504,15 +504,6 @@ static inline void i40iw_free_resource(struct i40iw_device *iwdev,spin_unlock_irqrestore (&iwdev->resource_lock, flags); } -/** -* to_iwhdl - Get the handler from the device pointer -* @iwdev: device pointer -**/ -static inline struct i40iw_handler *to_iwhdl (struct i40iw_device *iw_dev) -{ - return container_of(iw_dev, struct i40iw_handler, device); -} -struct i40iw_handler *i40iw_find_netdev (struct net_device *netdev);/**
drivers/infiniband/hw/i40iw/i40iw_osdep.h +0 -22
@@ -50,17 +50,6 @@ static inline void set_64bit_val(u64 *wqe_words, u32 byte_index, u64 value) wqe_words[byte_index >>3 ] = value; } -/** -* set_32bit_val - set 32 value to hw wqe -* @wqe_words: wqe addr to write -* @byte_index: index in wqe -* @value: value to write -**/ -static inline void set_32bit_val (u32 *wqe_words,u32 byte_index,u32 value) -{ - wqe_words[byte_index >>2 ] = value; -} -/** * get_64bit_val - read 64 bit value from wqe * @wqe_words: wqe addr
@@ -72,17 +61,6 @@ static inline void get_64bit_val(u64 *wqe_words, u32 byte_index, u64 *value) *value = wqe_words[byte_index >>3 ]; } -/** -* get_32bit_val - read 32 bit value from wqe -* @wqe_words: wqe addr -* @byte_index: index to reaad from -* @value: return 32 bit value -**/ -static inline void get_32bit_val (u32 *wqe_words,u32 byte_index,u32 *value) -{ - *value = wqe_words[byte_index >>2 ]; -} -struct i40iw_dma_mem {void *va;dma_addr_t pa;
drivers/infiniband/hw/qib/qib.h +0 -26
@@ -1303,11 +1303,6 @@ int qib_sdma_verbs_send(struct qib_pportdata *, struct rvt_sge_state *,/* ppd->sdma_lock should be locked before calling this. */ int qib_sdma_make_progress (struct qib_pportdata *dd); -static inline int qib_sdma_empty (const struct qib_pportdata *ppd) -{ -return ppd->sdma_descq_added == ppd->sdma_descq_removed; -} -/* must be called under qib_sdma_lock */ static inline u16 qib_sdma_descq_freecnt (const struct qib_pportdata *ppd) {
@@ -1364,27 +1359,6 @@ static inline u32 qib_get_rcvhdrtail(const struct qib_ctxtdata *rcd) *((volatile __le64 *)rcd->rcvhdrtail_kvaddr)); /* DMA'ed */ } -static inline u32 qib_get_hdrqtail (const struct qib_ctxtdata *rcd) -{ -const struct qib_devdata *dd = rcd->dd; -u32 hdrqtail; - -if (dd->flags &QIB_NODMA_RTAIL ) { -__le32 *rhf_addr; -u32 seq; - - rhf_addr = (__le32 *) rcd->rcvhdrq + - rcd->head + dd->rhf_offset; - seq =qib_hdrget_seq (rhf_addr); - hdrqtail = rcd->head; -if (seq == rcd->seq_cnt) - hdrqtail++; - }else - hdrqtail =qib_get_rcvhdrtail (rcd); - -return hdrqtail; -} -/* * sysfs interface. */
drivers/infiniband/hw/qib/qib_common.h +0 -7
@@ -795,11 +795,4 @@ static inline __u32 qib_hdrget_use_egr_buf(const __le32 *rbuf) {return __le32_to_cpu (rbuf[0 ]) &QLOGIC_IB_RHF_L_USE_EGR ; } - -static inline __u32 qib_hdrget_qib_ver (__le32 hdrword) -{ -return (__le32_to_cpu (hdrword) >>QLOGIC_IB_I_VERS_SHIFT ) & -QLOGIC_IB_I_VERS_MASK ; -} -#endif /* _QIB_COMMON_H */
drivers/infiniband/hw/vmw_pvrdma/pvrdma.h +0 -10
@@ -344,11 +344,6 @@ static inline enum ib_port_state pvrdma_port_state_to_ib(return (enum ib_port_state )state; } -static inline int ib_port_cap_flags_to_pvrdma (int flags) -{ -return flags &PVRDMA_MASK (PVRDMA_PORT_CAP_FLAGS_MAX ); -} -static inline int pvrdma_port_cap_flags_to_ib (int flags) {return flags;
@@ -410,11 +405,6 @@ static inline enum pvrdma_qp_type ib_qp_type_to_pvrdma(enum ib_qp_type type)return (enum pvrdma_qp_type )type; } -static inline enum ib_qp_type pvrdma_qp_type_to_ib (enum pvrdma_qp_type type) -{ -return (enum ib_qp_type )type; -} -static inline enum pvrdma_qp_state ib_qp_state_to_pvrdma (enum ib_qp_state state) {return (enum pvrdma_qp_state )state;
drivers/infiniband/hw/vmw_pvrdma/pvrdma_verbs.h +0 -35
@@ -70,30 +70,6 @@ enum pvrdma_mtu { PVRDMA_MTU_4096 = 5, }; -static inline int pvrdma_mtu_enum_to_int (enum pvrdma_mtu mtu) -{ -switch (mtu) { -case PVRDMA_MTU_256 :return 256 ; -case PVRDMA_MTU_512 :return 512 ; -case PVRDMA_MTU_1024 :return 1024 ; -case PVRDMA_MTU_2048 :return 2048 ; -case PVRDMA_MTU_4096 :return 4096 ; -default :return -1 ; - } -} - -static inline enum pvrdma_mtu pvrdma_mtu_int_to_enum (int mtu) -{ -switch (mtu) { -case 256 :return PVRDMA_MTU_256 ; -case 512 :return PVRDMA_MTU_512 ; -case 1024 :return PVRDMA_MTU_1024 ; -case 2048 :return PVRDMA_MTU_2048 ; -case 4096 : -default :return PVRDMA_MTU_4096 ; - } -} -enum pvrdma_port_state {PVRDMA_PORT_NOP =0 ,PVRDMA_PORT_DOWN =1 ,
@@ -138,17 +114,6 @@ enum pvrdma_port_width { PVRDMA_WIDTH_12X = 8, }; -static inline int pvrdma_width_enum_to_int (enum pvrdma_port_width width) -{ -switch (width) { -case PVRDMA_WIDTH_1X :return 1 ; -case PVRDMA_WIDTH_4X :return 4 ; -case PVRDMA_WIDTH_8X :return 8 ; -case PVRDMA_WIDTH_12X :return 12 ; -default :return -1 ; - } -} -enum pvrdma_port_speed {PVRDMA_SPEED_SDR =1 ,PVRDMA_SPEED_DDR =2 ,
drivers/infiniband/sw/siw/iwarp.h +0 -13
@@ -114,13 +114,6 @@ static inline u8 __ddp_get_version(struct iwarp_ctrl *ctrl)return be16_to_cpu (ctrl->ddp_rdmap_ctrl &DDP_MASK_VERSION ) >>8 ; } -static inline void __ddp_set_version (struct iwarp_ctrl *ctrl,u8 version) -{ - ctrl->ddp_rdmap_ctrl = - (ctrl->ddp_rdmap_ctrl & ~DDP_MASK_VERSION ) | - (cpu_to_be16 ((u16 )version <<8 ) &DDP_MASK_VERSION ); -} -static inline u8 __rdmap_get_version (struct iwarp_ctrl *ctrl) {__be16 ver = ctrl->ddp_rdmap_ctrl &RDMAP_MASK_VERSION ;
@@ -128,12 +121,6 @@ static inline u8 __rdmap_get_version(struct iwarp_ctrl *ctrl)return be16_to_cpu (ver) >>6 ; } -static inline void __rdmap_set_version (struct iwarp_ctrl *ctrl,u8 version) -{ - ctrl->ddp_rdmap_ctrl = (ctrl->ddp_rdmap_ctrl & ~RDMAP_MASK_VERSION ) | - (cpu_to_be16 (version <<6 ) &RDMAP_MASK_VERSION ); -} -static inline u8 __rdmap_get_opcode (struct iwarp_ctrl *ctrl) {return be16_to_cpu (ctrl->ddp_rdmap_ctrl &RDMAP_MASK_OPCODE );
drivers/infiniband/sw/siw/siw_mem.h +0 -5
@@ -29,11 +29,6 @@ static inline void siw_mem_put(struct siw_mem *mem)kref_put (&mem->ref, siw_free_mem); } -static inline struct siw_mr *siw_mem2mr (struct siw_mem *m) -{ - return container_of(m, struct siw_mr, mem); -} -static inline void siw_unref_mem_sgl (struct siw_mem **mem,unsigned int num_sge) {while (num_sge) {
Signature · 1 line
2.30.2
Quoted 7 lines · Leon Romanovsky
From: Leon Romanovsky <[email protected]>
Bunch of cleanup in RDMA subsystem.
Leon Romanovsky (2):
RDMA: Fix kernel-doc compilation warnings
RDMA: Delete not-used static inline functions
Applied to for-next
How did you find the unused static inline functions?
Thanks,
Jason
Quoted 5 lines · Jason Gunthorpe
Quoted 4 lines · Leon Romanovsky
From: Leon Romanovsky <[email protected]>
Bunch of cleanup in RDMA subsystem.
Quoted 7 lines
Quoted 3 lines
Leon Romanovsky (2):
RDMA: Fix kernel-doc compilation warnings
RDMA: Delete not-used static inline functionsApplied to for-next
How did you find the unused static inline functions?
Accidentally spotted such in pvrdma and later wrote one liner to create me a list of functions to delete.
Thanks
Quoted 3 lines
Thanks,
Jason
Quoted 6 lines · Leon Romanovsky
Quoted 5 lines · Jason Gunthorpe
Quoted 4 lines · Leon Romanovsky
From: Leon Romanovsky <[email protected]>
Bunch of cleanup in RDMA subsystem.
Quoted 8 lines
Quoted 6 lines
Quoted 3 lines
Leon Romanovsky (2):
RDMA: Fix kernel-doc compilation warnings
RDMA: Delete not-used static inline functionsApplied to for-next
How did you find the unused static inline functions?
Accidentally spotted such in pvrdma and later wrote one liner to create me a list of functions to delete.
Thanks for removing these.
Quoted 4 lines
Thanks
Quoted 2 lines
Thanks,
Jason