{PATCH 3/5] Cleanup: Shorten the declaration name of kdump_sub_header.

Ken'ichi Ohmichi oomichi at mxs.nes.nec.co.jp
Tue Oct 13 01:20:15 EDT 2009


{PATCH 3/5] Cleanup: Shorten the declaration name of kdump_sub_header.

Signed-off-by: Ken'ichi Ohmichi <oomichi at mxs.nes.nec.co.jp>
---
diff -rpuN a/makedumpfile.c b/makedumpfile.c
--- a/makedumpfile.c	2009-10-13 12:18:10.000000000 +0900
+++ b/makedumpfile.c	2009-10-13 12:19:21.000000000 +0900
@@ -5439,7 +5439,7 @@ write_kdump_header(void)
 {
 	size_t size;
 	struct disk_dump_header *dh = info->dump_header;
-	struct kdump_sub_header sub_dump_header;
+	struct kdump_sub_header kh;
 
 	if (info->flag_elf_dumpfile)
 		return FALSE;
@@ -5450,7 +5450,7 @@ write_kdump_header(void)
 	strcpy(dh->signature, KDUMP_SIGNATURE);
 	dh->header_version = 2;
 	dh->block_size     = info->page_size;
-	dh->sub_hdr_size   = divideup(sizeof(sub_dump_header), dh->block_size);
+	dh->sub_hdr_size   = divideup(sizeof(kh), dh->block_size);
 	dh->max_mapnr      = info->max_mapnr;
 	dh->nr_cpus        = 1;
 	dh->bitmap_blocks  = divideup(info->len_bitmap, dh->block_size);
@@ -5465,15 +5465,15 @@ write_kdump_header(void)
 	 * Write sub header
 	 */
 	size = sizeof(struct kdump_sub_header);
-	memset(&sub_dump_header, 0, size);
-	sub_dump_header.phys_base  = info->phys_base;
-	sub_dump_header.dump_level = info->dump_level;
+	memset(&kh, 0, size);
+	kh.phys_base  = info->phys_base;
+	kh.dump_level = info->dump_level;
 	if (info->flag_split) {
-		sub_dump_header.split = 1;
-		sub_dump_header.start_pfn = info->split_start_pfn;
-		sub_dump_header.end_pfn   = info->split_end_pfn;
+		kh.split = 1;
+		kh.start_pfn = info->split_start_pfn;
+		kh.end_pfn   = info->split_end_pfn;
 	}
-	if (!write_buffer(info->fd_dumpfile, dh->block_size, &sub_dump_header,
+	if (!write_buffer(info->fd_dumpfile, dh->block_size, &kh,
 	    size, info->name_dumpfile))
 		return FALSE;
 



More information about the kexec mailing list