* [PATCH] xfstests: fix compile error of src/fssum.c on bigendian host
@ 2013-10-30 3:55 Eryu Guan
2013-10-30 4:21 ` Dave Chinner
2013-10-31 12:12 ` Carlos Maiolino
0 siblings, 2 replies; 3+ messages in thread
From: Eryu Guan @ 2013-10-30 3:55 UTC (permalink / raw)
To: xfs; +Cc: Eryu Guan
Definition of htonll() is needed on bigendian host too, otherwise
src/fssum.c won't compile on ppc64/s390x hosts.
Signed-off-by: Eryu Guan <eguan@redhat.com>
---
src/fssum.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/fssum.c b/src/fssum.c
index c75ff8b..c26d32b 100644
--- a/src/fssum.c
+++ b/src/fssum.c
@@ -50,6 +50,8 @@
#if __BYTE_ORDER == __LITTLE_ENDIAN
#define htonll(x) __bswap_64 (x)
+#else
+#define htonll(x) (x)
#endif
#endif
--
1.8.3.1
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] xfstests: fix compile error of src/fssum.c on bigendian host
2013-10-30 3:55 [PATCH] xfstests: fix compile error of src/fssum.c on bigendian host Eryu Guan
@ 2013-10-30 4:21 ` Dave Chinner
2013-10-31 12:12 ` Carlos Maiolino
1 sibling, 0 replies; 3+ messages in thread
From: Dave Chinner @ 2013-10-30 4:21 UTC (permalink / raw)
To: Eryu Guan; +Cc: xfs
On Wed, Oct 30, 2013 at 11:55:43AM +0800, Eryu Guan wrote:
> Definition of htonll() is needed on bigendian host too, otherwise
> src/fssum.c won't compile on ppc64/s390x hosts.
>
> Signed-off-by: Eryu Guan <eguan@redhat.com>
> ---
> src/fssum.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/src/fssum.c b/src/fssum.c
> index c75ff8b..c26d32b 100644
> --- a/src/fssum.c
> +++ b/src/fssum.c
> @@ -50,6 +50,8 @@
>
> #if __BYTE_ORDER == __LITTLE_ENDIAN
> #define htonll(x) __bswap_64 (x)
> +#else
> +#define htonll(x) (x)
> #endif
> #endif
Looks fine.
Acked-by: Dave Chinner <dchinner@redhat.com>
--
Dave Chinner
david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] xfstests: fix compile error of src/fssum.c on bigendian host
2013-10-30 3:55 [PATCH] xfstests: fix compile error of src/fssum.c on bigendian host Eryu Guan
2013-10-30 4:21 ` Dave Chinner
@ 2013-10-31 12:12 ` Carlos Maiolino
1 sibling, 0 replies; 3+ messages in thread
From: Carlos Maiolino @ 2013-10-31 12:12 UTC (permalink / raw)
To: xfs
Looks good,
Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
On Wed, Oct 30, 2013 at 11:55:43AM +0800, Eryu Guan wrote:
> Definition of htonll() is needed on bigendian host too, otherwise
> src/fssum.c won't compile on ppc64/s390x hosts.
>
> Signed-off-by: Eryu Guan <eguan@redhat.com>
> ---
> src/fssum.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/src/fssum.c b/src/fssum.c
> index c75ff8b..c26d32b 100644
> --- a/src/fssum.c
> +++ b/src/fssum.c
> @@ -50,6 +50,8 @@
>
> #if __BYTE_ORDER == __LITTLE_ENDIAN
> #define htonll(x) __bswap_64 (x)
> +#else
> +#define htonll(x) (x)
> #endif
> #endif
>
> --
> 1.8.3.1
>
> _______________________________________________
> xfs mailing list
> xfs@oss.sgi.com
> http://oss.sgi.com/mailman/listinfo/xfs
--
Carlos
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-10-31 12:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-30 3:55 [PATCH] xfstests: fix compile error of src/fssum.c on bigendian host Eryu Guan
2013-10-30 4:21 ` Dave Chinner
2013-10-31 12:12 ` Carlos Maiolino
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox