From: Mike Frysinger Date: Fri, 20 Jan 2012 14:07:20 -0500 Subject: [U-Boot] [PATCH 1/3] cmd_mem: replace custom PRINTF() with debug() Message-ID: <1327086442-18016-1-git-send-email-vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Signed-off-by: Mike Frysinger --- common/cmd_mem.c | 12 +++--------- 1 files changed, 3 insertions(+), 9 deletions(-) diff --git a/common/cmd_mem.c b/common/cmd_mem.c index 9ad932c..5121b22 100644 --- a/common/cmd_mem.c +++ b/common/cmd_mem.c @@ -35,12 +35,6 @@ #include #include -#ifdef CMD_MEM_DEBUG -#define PRINTF(fmt,args...) printf (fmt ,##args) -#else -#define PRINTF(fmt,args...) -#endif - static int mod_mem(cmd_tbl_t *, int, int, int, char * const []); /* Display values from last command. @@ -681,7 +675,7 @@ int do_mem_mtest (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #if defined(CONFIG_SYS_ALT_MEMTEST) printf ("Testing %08x ... %08x:\n", (uint)start, (uint)end); - PRINTF("%s:%d: start 0x%p end 0x%p\n", + debug("%s:%d: start 0x%p end 0x%p\n", __FUNCTION__, __LINE__, start, end); for (;;) { @@ -698,7 +692,7 @@ int do_mem_mtest (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) } printf("Iteration: %6d\r", iterations); - PRINTF("\n"); + debug("\n"); iterations++; /* @@ -789,7 +783,7 @@ int do_mem_mtest (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) pattern = (vu_long) 0xaaaaaaaa; anti_pattern = (vu_long) 0x55555555; - PRINTF("%s:%d: length = 0x%.8lx\n", + debug("%s:%d: length = 0x%.8lx\n", __FUNCTION__, __LINE__, len); /* -- 1.7.7.3