linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mingming Cao <cmm@us.ibm.com>
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org, ext2-devel@lists.sourceforge.net,
	linux-fsdevel@vger.kernel.org
Subject: [PATCH 2/9] sector_t format string
Date: Wed, 09 Aug 2006 18:20:43 -0700	[thread overview]
Message-ID: <1155172843.3161.81.camel@localhost.localdomain> (raw)



Define SECTOR_FMT to print sector_t in proper format

Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
Acked-by: Andreas Dilger <adilger@clusterfs.com>


---

 linux-2.6.18-rc4-ming/include/asm-h8300/types.h   |    1 +
 linux-2.6.18-rc4-ming/include/asm-i386/types.h    |    1 +
 linux-2.6.18-rc4-ming/include/asm-mips/types.h    |    5 +++++
 linux-2.6.18-rc4-ming/include/asm-powerpc/types.h |    5 +++++
 linux-2.6.18-rc4-ming/include/asm-s390/types.h    |    5 +++++
 linux-2.6.18-rc4-ming/include/asm-sh/types.h      |    1 +
 linux-2.6.18-rc4-ming/include/asm-x86_64/types.h  |    1 +
 linux-2.6.18-rc4-ming/include/linux/types.h       |    1 +
 8 files changed, 20 insertions(+)

diff -puN include/asm-h8300/types.h~sector_fmt include/asm-h8300/types.h
--- linux-2.6.18-rc4/include/asm-h8300/types.h~sector_fmt	2006-08-09 15:41:47.912256609 -0700
+++ linux-2.6.18-rc4-ming/include/asm-h8300/types.h	2006-08-09 15:41:47.936256803 -0700
@@ -57,6 +57,7 @@ typedef u32 dma_addr_t;
 
 #define HAVE_SECTOR_T
 typedef u64 sector_t;
+#define SECTOR_FMT "%llu"
 
 #define HAVE_BLKCNT_T
 typedef u64 blkcnt_t;
diff -puN include/asm-i386/types.h~sector_fmt include/asm-i386/types.h
--- linux-2.6.18-rc4/include/asm-i386/types.h~sector_fmt	2006-08-09 15:41:47.915256633 -0700
+++ linux-2.6.18-rc4-ming/include/asm-i386/types.h	2006-08-09 15:41:47.937256811 -0700
@@ -59,6 +59,7 @@ typedef u64 dma64_addr_t;
 
 #ifdef CONFIG_LBD
 typedef u64 sector_t;
+#define SECTOR_FMT "%llu"
 #define HAVE_SECTOR_T
 #endif
 
diff -puN include/asm-mips/types.h~sector_fmt include/asm-mips/types.h
--- linux-2.6.18-rc4/include/asm-mips/types.h~sector_fmt	2006-08-09 15:41:47.918256657 -0700
+++ linux-2.6.18-rc4-ming/include/asm-mips/types.h	2006-08-09 15:41:47.938256819 -0700
@@ -95,6 +95,11 @@ typedef unsigned long phys_t;
 
 #ifdef CONFIG_LBD
 typedef u64 sector_t;
+#if (_MIPS_SZLONG == 64)
+#define SECTOR_FMT "%lu"
+#else
+#define SECTOR_FMT "%llu"
+#endif
 #define HAVE_SECTOR_T
 #endif
 
diff -puN include/asm-powerpc/types.h~sector_fmt include/asm-powerpc/types.h
--- linux-2.6.18-rc4/include/asm-powerpc/types.h~sector_fmt	2006-08-09 15:41:47.921256681 -0700
+++ linux-2.6.18-rc4-ming/include/asm-powerpc/types.h	2006-08-09 15:41:47.938256819 -0700
@@ -99,6 +99,11 @@ typedef struct {
 
 #ifdef CONFIG_LBD
 typedef u64 sector_t;
+#ifdef __powerpc64__
+#define SECTOR_FMT "%lu"
+#else
+#define SECTOR_FMT "%llu"
+#endif
 #define HAVE_SECTOR_T
 #endif
 
diff -puN include/asm-s390/types.h~sector_fmt include/asm-s390/types.h
--- linux-2.6.18-rc4/include/asm-s390/types.h~sector_fmt	2006-08-09 15:41:47.924256706 -0700
+++ linux-2.6.18-rc4-ming/include/asm-s390/types.h	2006-08-09 15:41:47.939256827 -0700
@@ -89,6 +89,11 @@ typedef union {
 
 #ifdef CONFIG_LBD
 typedef u64 sector_t;
+#ifndef __s390x__
+#define SECTOR_FMT "%llu"
+#else
+#define SECTOR_FMT "%lu"
+#endif
 #define HAVE_SECTOR_T
 #endif
 
diff -puN include/asm-sh/types.h~sector_fmt include/asm-sh/types.h
--- linux-2.6.18-rc4/include/asm-sh/types.h~sector_fmt	2006-08-09 15:41:47.927256730 -0700
+++ linux-2.6.18-rc4-ming/include/asm-sh/types.h	2006-08-09 15:41:47.939256827 -0700
@@ -54,6 +54,7 @@ typedef u32 dma_addr_t;
 
 #ifdef CONFIG_LBD
 typedef u64 sector_t;
+#define SECTOR_FMT "%llu"
 #define HAVE_SECTOR_T
 #endif
 
diff -puN include/asm-x86_64/types.h~sector_fmt include/asm-x86_64/types.h
--- linux-2.6.18-rc4/include/asm-x86_64/types.h~sector_fmt	2006-08-09 15:41:47.931256762 -0700
+++ linux-2.6.18-rc4-ming/include/asm-x86_64/types.h	2006-08-09 15:41:47.940256835 -0700
@@ -49,6 +49,7 @@ typedef u64 dma64_addr_t;
 typedef u64 dma_addr_t;
 
 typedef u64 sector_t;
+#define SECTOR_FMT "%llu"
 #define HAVE_SECTOR_T
 
 #endif /* __ASSEMBLY__ */
diff -puN include/linux/types.h~sector_fmt include/linux/types.h
--- linux-2.6.18-rc4/include/linux/types.h~sector_fmt	2006-08-09 15:41:47.934256787 -0700
+++ linux-2.6.18-rc4-ming/include/linux/types.h	2006-08-09 15:41:47.940256835 -0700
@@ -134,6 +134,7 @@ typedef		__s64		int64_t;
  */
 #ifndef HAVE_SECTOR_T
 typedef unsigned long sector_t;
+#define SECTOR_FMT "%lu"
 #endif
 
 #ifndef HAVE_BLKCNT_T

_



             reply	other threads:[~2006-08-10  1:20 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-10  1:20 Mingming Cao [this message]
2006-08-10  6:40 ` [PATCH 2/9] sector_t format string Andrew Morton
2006-08-10 11:05   ` Roman Zippel
2006-08-10 12:02     ` Jeff Garzik
2006-08-10 12:24       ` Roman Zippel
2006-08-10 12:25         ` Jeff Garzik
2006-08-10 12:30           ` Roman Zippel
2006-08-10 12:33             ` Jeff Garzik
2006-08-10 13:08               ` Roman Zippel
2006-08-10 13:14                 ` Jeff Garzik
2006-08-10 13:27                   ` Roman Zippel
2006-08-10 13:30                     ` Jeff Garzik
2006-08-10 13:52                       ` Roman Zippel
2006-08-10 14:04                         ` [Ext2-devel] " Eric Sandeen
2006-08-10 14:19                           ` Roman Zippel
2006-08-10 14:21                             ` Jeff Garzik
2006-08-10 14:35                               ` Roman Zippel
2006-08-10 14:06                         ` Jeff Garzik
2006-08-10 14:24                           ` Roman Zippel
2006-08-10 14:26                             ` Jeff Garzik
2006-08-10 14:41                               ` Roman Zippel
2006-08-10 16:24                     ` John Stoffel
2006-08-10 16:43                       ` Roman Zippel
2006-08-10 16:54                       ` Andrew Morton
2006-08-10 17:24                         ` Roman Zippel
2006-08-10 15:31   ` [Ext2-devel] " Theodore Tso
2006-08-10 16:37     ` Roman Zippel
2006-08-10 21:59       ` [Ext2-devel] " Mingming Cao
2006-08-10 19:17   ` Joel Becker
2006-08-10 19:44     ` Alexey Dobriyan
2006-08-10 19:57       ` Andrew Morton
2006-08-10 20:41         ` Alexey Dobriyan
2006-08-10 20:17       ` Jeff Mahoney
2006-08-11  5:57         ` Jan Engelhardt
2006-08-11  8:31           ` Bernd Petrovitsch
2006-08-11  9:07             ` Jan Engelhardt
2006-08-11 14:48           ` Jeff Mahoney
2006-08-11  0:59   ` Mingming Cao
2006-08-11  2:11     ` Eric Sandeen
2006-08-11 22:06     ` Mingming Cao

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1155172843.3161.81.camel@localhost.localdomain \
    --to=cmm@us.ibm.com \
    --cc=akpm@osdl.org \
    --cc=ext2-devel@lists.sourceforge.net \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).