mtd/drivers/mtd/nand diskonchip.c,1.30,1.31

Kalev Lember kalev at infradead.org
Mon Aug 9 03:20:56 EDT 2004


Update of /home/cvs/mtd/drivers/mtd/nand
In directory phoenix.infradead.org:/tmp/cvs-serv3391

Modified Files:
	diskonchip.c 
Log Message:
Pretty-print the OsakVersion field
(port of Dan Brown's code from docfdisk.c)



Index: diskonchip.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/nand/diskonchip.c,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -r1.30 -r1.31
--- diskonchip.c	26 Jul 2004 16:00:50 -0000	1.30
+++ diskonchip.c	9 Aug 2004 07:20:53 -0000	1.31
@@ -1125,13 +1125,17 @@
 			 "    NoOfBDTLPartitions    = %d\n"
 			 "    BlockMultiplerBits    = %d\n"
 			 "    FormatFlgs            = %d\n"
-			 "    OsakVersion           = 0x%x\n"
+			 "    OsakVersion           = %d.%d.%d.%d\n"
 			 "    PercentUsed           = %d\n",
 		mh->bootRecordID, mh->NoOfBootImageBlocks,
 		mh->NoOfBinaryPartitions,
 		mh->NoOfBDTLPartitions,
 		mh->BlockMultiplierBits, mh->FormatFlags,
-		mh->OsakVersion, mh->PercentUsed);
+		((unsigned char *) &mh->OsakVersion)[0] & 0xf,
+		((unsigned char *) &mh->OsakVersion)[1] & 0xf,
+		((unsigned char *) &mh->OsakVersion)[2] & 0xf,
+		((unsigned char *) &mh->OsakVersion)[3] & 0xf,
+		mh->PercentUsed);
 //#endif
 
 	vshift = this->phys_erase_shift + mh->BlockMultiplierBits;





More information about the linux-mtd-cvs mailing list