[Crash-utility] [PATCH 06/11] sadump: debug messages at the beginning of open_disk() and add_disk()

HATAYAMA Daisuke d.hatayama at jp.fujitsu.com
Thu Oct 20 10:42:44 UTC 2011


These are useful to check initialization processing for each disk.

Signed-off-by: HATAYAMA Daisuke <d.hatayama at jp.fujitsu.com>
---

 sadump.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
-------------- next part --------------
diff --git a/sadump.c b/sadump.c
index d98db41..8572596 100644
--- a/sadump.c
+++ b/sadump.c
@@ -465,6 +465,9 @@ add_disk(char *file)
 	diskid = sd->sd_list_len - 1;
 	this_disk = sd->sd_list[diskid];
 
+	if (CRASHDEBUG(1))
+		error(INFO, "sadump: add disk #%d\n", diskid+1);
+
 	ph = malloc(sd->block_size);
 	if (!ph) {
 		error(INFO, "sadump: cannot malloc block_size buffer\n");
@@ -590,6 +593,9 @@ open_disk(char *file)
 
 	sd->sd_list_len++;
 
+	if (CRASHDEBUG(1))
+		error(INFO, "sadump: open disk #%d\n", sd->sd_list_len);
+
 	if (sd->sd_list_len > sd->diskset_header->disk_num) {
 		error(INFO, "sadump: too many diskset arguments; "
 		      "this diskset consists of %d disks\n",


More information about the Crash-utility mailing list