From 166cae20dd797dcb25fc550269792f15704d9c58 Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Wed, 18 Oct 2017 00:10:48 +0900 Subject: mtd: replace MTDDEBUG() with pr_debug() In old days, the MTD subsystem in Linux had debug facility like DEBUG(MTD_DEBUG_LEVEL1, ...). They were all replaced with pr_debug() until Linux 3.2. See Linux commit 289c05222172 ("mtd: replace DEBUG() with pr_debug()"). U-Boot still uses similar macros. Covert all of them for easier sync. Done with the help of Coccinelle. The semantic patch I used is as follows: // @@ expression e1, e2; @@ -MTDDEBUG(e1, e2) +pr_debug(e2) @@ expression e1, e2; @@ -MTDDEBUG(e1, e2, +pr_debug(e2, ...) // Signed-off-by: Masahiro Yamada --- drivers/mtd/onenand/onenand_bbt.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'drivers/mtd/onenand/onenand_bbt.c') diff --git a/drivers/mtd/onenand/onenand_bbt.c b/drivers/mtd/onenand/onenand_bbt.c index 20507004ed..cde342aaec 100644 --- a/drivers/mtd/onenand/onenand_bbt.c +++ b/drivers/mtd/onenand/onenand_bbt.c @@ -160,9 +160,8 @@ static int onenand_isbad_bbt(struct mtd_info *mtd, loff_t offs, int allowbbt) block = (int) (onenand_block(this, offs) << 1); res = (bbm->bbt[block >> 3] >> (block & 0x06)) & 0x03; - MTDDEBUG (MTD_DEBUG_LEVEL2, - "onenand_isbad_bbt: bbt info for offs 0x%08x: (block %d) 0x%02x\n", - (unsigned int)offs, block >> 1, res); + pr_debug("onenand_isbad_bbt: bbt info for offs 0x%08x: (block %d) 0x%02x\n", + (unsigned int)offs, block >> 1, res); switch ((int)res) { case 0x00: -- cgit