From: Christoph Hellwig <hch@lst.de>
To: xfs@oss.sgi.com
Subject: [PATCH 08/13] xfsprogs: move __be*/__le* types and __arch_pack to xfs_arch.h
Date: Fri, 3 Jul 2015 12:12:16 +0200 [thread overview]
Message-ID: <1435918341-10128-9-git-send-email-hch@lst.de> (raw)
In-Reply-To: <1435918341-10128-1-git-send-email-hch@lst.de>
These are defines and typedefs only needed for the XFS on disk format,
so there is no need to have the available for every user of xfs.h.
Signed-off-by: Christoph Hellwig <hch@lst.de>
---
include/platform_defs.h.in | 23 -----------------------
include/xfs_arch.h | 23 +++++++++++++++++++++++
2 files changed, 23 insertions(+), 23 deletions(-)
diff --git a/include/platform_defs.h.in b/include/platform_defs.h.in
index 529c0a6..81741c4 100644
--- a/include/platform_defs.h.in
+++ b/include/platform_defs.h.in
@@ -50,22 +50,6 @@ typedef unsigned long long int __u64;
typedef signed long long int __s64;
#endif
-#ifdef __CHECKER__
-#define __bitwise __attribute__((bitwise))
-#define __force __attribute__((force))
-#else
-#define __bitwise
-#define __force
-#endif
-
-typedef __u16 __bitwise __le16;
-typedef __u32 __bitwise __le32;
-typedef __u64 __bitwise __le64;
-
-typedef __u16 __bitwise __be16;
-typedef __u32 __bitwise __be32;
-typedef __u64 __bitwise __be64;
-
typedef struct filldir filldir_t;
#if defined(__linux__)
@@ -130,13 +114,6 @@ typedef unsigned short umode_t;
| (minor&IRIX_DEV_MAXMIN)))
#define IRIX_DEV_TO_KDEVT(dev) makedev(IRIX_DEV_MAJOR(dev),IRIX_DEV_MINOR(dev))
-/* ARM old ABI has some weird alignment/padding */
-#if defined(__arm__) && !defined(__ARM_EABI__)
-#define __arch_pack __attribute__((packed))
-#else
-#define __arch_pack
-#endif
-
#ifndef min
#define min(a,b) (((a)<(b))?(a):(b))
#define max(a,b) (((a)>(b))?(a):(b))
diff --git a/include/xfs_arch.h b/include/xfs_arch.h
index 310a17e..87650f1 100644
--- a/include/xfs_arch.h
+++ b/include/xfs_arch.h
@@ -24,6 +24,22 @@
#undef XFS_NATIVE_HOST
#endif
+#ifdef __CHECKER__
+#define __bitwise __attribute__((bitwise))
+#define __force __attribute__((force))
+#else
+#define __bitwise
+#define __force
+#endif
+
+typedef __u16 __bitwise __le16;
+typedef __u32 __bitwise __le32;
+typedef __u64 __bitwise __le64;
+
+typedef __u16 __bitwise __be16;
+typedef __u32 __bitwise __be32;
+typedef __u64 __bitwise __be64;
+
/*
* Casts are necessary for constants, because we never know how for sure
* how U/UL/ULL map to __u16, __u32, __u64. At least not in a portable way.
@@ -262,4 +278,11 @@ static inline void put_unaligned_be64(__uint64_t val, void *p)
put_unaligned_be32(val, p + 4);
}
+/* ARM old ABI has some weird alignment/padding */
+#if defined(__arm__) && !defined(__ARM_EABI__)
+#define __arch_pack __attribute__((packed))
+#else
+#define __arch_pack
+#endif
+
#endif /* __XFS_ARCH_H__ */
--
1.9.1
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2015-07-03 10:15 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-03 10:12 xfsprogs: clean up installed headers Christoph Hellwig
2015-07-03 10:12 ` [PATCH 01/13] xfsprogs: don't install internal header files Christoph Hellwig
2015-07-03 10:12 ` [PATCH 02/13] xfsprogs: remove unused macros from xfs_arch.h Christoph Hellwig
2015-07-03 10:12 ` [PATCH 03/13] xfsprogs: remove swab.h Christoph Hellwig
2015-07-03 10:12 ` [PATCH 04/13] xfsprogs: only install *format.h headers in install-qa Christoph Hellwig
2015-07-03 10:12 ` [PATCH 05/13] xfsprogs: remove install-qa target Christoph Hellwig
2015-07-03 10:12 ` [PATCH 06/13] xfsprogs: use <>-style includes in installed headers Christoph Hellwig
2015-07-03 10:12 ` [PATCH 07/13] xfsprogs: simplify internal includes Christoph Hellwig
2015-07-03 10:12 ` Christoph Hellwig [this message]
2015-07-03 10:12 ` [PATCH 09/13] xfsprogs: move __u*/__s* typedefs to per-port headers Christoph Hellwig
2015-07-03 10:12 ` [PATCH 10/13] xfsprogs: include libxfs.h in libxfs_priv.h Christoph Hellwig
2015-07-03 23:42 ` Dave Chinner
2015-07-03 10:12 ` [PATCH 11/13] xfsprogs: don't install platform_defs.h Christoph Hellwig
2015-07-03 10:12 ` [PATCH 12/13] xfsprogs: remove filldir_t typedef Christoph Hellwig
2015-07-03 10:12 ` [PATCH 13/13] xfsprogs: remove the constpp define Christoph Hellwig
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=1435918341-10128-9-git-send-email-hch@lst.de \
--to=hch@lst.de \
--cc=xfs@oss.sgi.com \
/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