From: Heiko Carstens <heiko.carstens@de.ibm.com>
To: Kyle McMartin <kyle@mcmartin.ca>
Cc: linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [COMPAT] Add compat_merge64 helper
Date: Sat, 29 Sep 2007 11:48:52 +0200 [thread overview]
Message-ID: <20070929094852.GA7715@osiris.boeblingen.de.ibm.com> (raw)
In-Reply-To: <1191018832-18069-1-git-send-email-kyle@mcmartin.ca>
On Fri, Sep 28, 2007 at 06:33:51PM -0400, Kyle McMartin wrote:
> To be used when endianness matters for argument ordering when reassembling
> a 64-bit value out of two register halves.
>
> Signed-off-by: Kyle McMartin <kyle@mcmartin.ca>
>
> +static inline u64 compat_merge64(u32 left, u32 right)
> +{
> +#if defined(__BIG_ENDIAN)
> + return ((u64)left << 32) | right;
> +#else /* defined (__LITTLE_ENDIAN) */
Could you change that to an #elif please and #error out if none is defined?
Should safe us from subtle bugs caused by missing includes.
next prev parent reply other threads:[~2007-09-29 9:48 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-28 22:33 [COMPAT] Add compat_merge64 helper Kyle McMartin
2007-09-28 22:33 ` [PATCH] Generic compat_sys_fallocate Kyle McMartin
2007-09-29 9:11 ` Geert Uytterhoeven
2007-09-28 23:38 ` [COMPAT] Add compat_merge64 helper Arnd Bergmann
2007-09-29 0:01 ` Kyle McMartin
2007-09-28 23:52 ` Arnd Bergmann
2007-09-29 0:02 ` Kyle McMartin
2007-09-29 7:23 ` Paul Mundt
2007-09-29 9:48 ` Heiko Carstens [this message]
2007-10-03 12:12 ` Ralf Baechle
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=20070929094852.GA7715@osiris.boeblingen.de.ibm.com \
--to=heiko.carstens@de.ibm.com \
--cc=kyle@mcmartin.ca \
--cc=linux-arch@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).