Skip to content

Commit d3ffaef

Browse files
saurabh-sengardavem330
authored andcommitted
net: rds: changing the return type from int to void
as result of function rds_iw_flush_mr_pool is nowhere checked, changing its return type from int to void. also removing the unused variable rc as there is nothing to return Signed-off-by: Saurabh Sengar <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 64cf370 commit d3ffaef

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

net/rds/iw_rdma.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ struct rds_iw_mr_pool {
7575
int max_pages;
7676
};
7777

78-
static int rds_iw_flush_mr_pool(struct rds_iw_mr_pool *pool, int free_all);
78+
static void rds_iw_flush_mr_pool(struct rds_iw_mr_pool *pool, int free_all);
7979
static void rds_iw_mr_pool_flush_worker(struct work_struct *work);
8080
static int rds_iw_init_fastreg(struct rds_iw_mr_pool *pool, struct rds_iw_mr *ibmr);
8181
static int rds_iw_map_fastreg(struct rds_iw_mr_pool *pool,
@@ -479,14 +479,13 @@ void rds_iw_sync_mr(void *trans_private, int direction)
479479
* If the number of MRs allocated exceeds the limit, we also try
480480
* to free as many MRs as needed to get back to this limit.
481481
*/
482-
static int rds_iw_flush_mr_pool(struct rds_iw_mr_pool *pool, int free_all)
482+
static void rds_iw_flush_mr_pool(struct rds_iw_mr_pool *pool, int free_all)
483483
{
484484
struct rds_iw_mr *ibmr, *next;
485485
LIST_HEAD(unmap_list);
486486
LIST_HEAD(kill_list);
487487
unsigned long flags;
488488
unsigned int nfreed = 0, ncleaned = 0, unpinned = 0;
489-
int ret = 0;
490489

491490
rds_iw_stats_inc(s_iw_rdma_mr_pool_flush);
492491

@@ -538,7 +537,6 @@ static int rds_iw_flush_mr_pool(struct rds_iw_mr_pool *pool, int free_all)
538537
atomic_sub(nfreed, &pool->item_count);
539538

540539
mutex_unlock(&pool->flush_lock);
541-
return ret;
542540
}
543541

544542
static void rds_iw_mr_pool_flush_worker(struct work_struct *work)

0 commit comments

Comments
 (0)