From 7beb5f7878aa2773badde63fd3dd81d3396e5723 Mon Sep 17 00:00:00 2001 From: batt Date: Thu, 12 Aug 2010 15:02:43 +0000 Subject: [PATCH] Overhaul kdump(). git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4174 38d2e660-2303-0410-9eaa-f027e97ec537 --- bertos/drv/kdebug.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/bertos/drv/kdebug.c b/bertos/drv/kdebug.c index cb04f70b..9c210343 100644 --- a/bertos/drv/kdebug.c +++ b/bertos/drv/kdebug.c @@ -274,8 +274,14 @@ void kdump(const void *_buf, size_t len) { const unsigned char *buf = (const unsigned char *)_buf; + kprintf("Dumping buffer at addr [%p], %z bytes", buf, len); + size_t i=0; while (len--) - kprintf("%02X", *buf++); + { + if ((i % 16) == 0) + kputs("\n"); + kprintf("%02X ", *buf++); + } kputchar('\n'); } -- 2.25.1