Skip to contentSkip to conversation

RDMA: Delete DEBUG code

PATCH Applied Leon Romanovsky 2 participants 2 messages Aug 19, 2019 – Aug 20, 2019 InfiniBand

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 RDMA: Delete DEBUG code

From: Leon Romanovsky <[email protected]>

There is no need to keep DEBUG defines for out-of-the tree testing.

---
 drivers/infiniband/core/fmr_pool.c | 13 -------------
 include/rdma/ib_verbs.h            |  3 ---
 2 files changed, 16 deletions(-)
drivers/infiniband/core/fmr_pool.c +0 -13
index 7d841b689a1e..e08aec427027 100644
@@ -148,13 +148,6 @@ static void ib_fmr_batch_release(struct ib_fmr_pool *pool)
 		hlist_del_init(&fmr->cache_node);
 		fmr->remap_count = 0;
 		list_add_tail(&fmr->fmr->list, &fmr_list);
-
-#ifdef DEBUG
-		if (fmr->ref_count !=0) {
-			pr_warn(PFX "Unmapping FMR 0x%08x with ref count %d\n",
-				fmr, fmr->ref_count);
-		}
-#endif
 	}
 
 	list_splice_init(&pool->dirty_list, &unmap_list);
@@ -496,12 +489,6 @@ void ib_fmr_pool_unmap(struct ib_pool_fmr *fmr)
 		}
 	}
 
-#ifdef DEBUG
-	if (fmr->ref_count < 0)
-		pr_warn(PFX "FMR %p has ref count %d < 0\n",
-			fmr, fmr->ref_count);
-#endif
-
 	spin_unlock_irqrestore(&pool->pool_lock, flags);
 }
 EXPORT_SYMBOL(ib_fmr_pool_unmap);
include/rdma/ib_verbs.h +0 -3
index 18a34888bbca..73529a10ea36 100644
@@ -98,9 +98,6 @@ void ibdev_info(const struct ib_device *ibdev, const char *format, ...);
 #if defined(CONFIG_DYNAMIC_DEBUG)
 #define ibdev_dbg(__dev, format, args...)                       \
 	dynamic_ibdev_dbg(__dev, format, ##args)
-#elif defined(DEBUG)
-#define ibdev_dbg(__dev, format, args...)                       \
-	ibdev_printk(KERN_DEBUG, __dev, format, ##args)
 #else
 __printf(2, 3) __cold
 static inline
Signature · 1 line
2.20.1