[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20080411202238.GB9108@cvg>
Date: Sat, 12 Apr 2008 00:22:38 +0400
From: Cyrill Gorcunov <gorcunov@...il.com>
To: Harvey Harrison <harvey.harrison@...il.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>,
linux-arch <linux-arch@...r.kernel.org>,
David Howells <dhowells@...hat.com>,
Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [PATCH 1/2] kernel: add common infrastructure for unaligned
access
[Harvey Harrison - Thu, Apr 10, 2008 at 08:38:57PM -0700]
[...]
| +
| +static inline void __put_unaligned_be16(u16 val, u8 *p)
| +{
| + *p++ = val >> 8;
| + *p++ = val;
| +}
| +
[...]
| +static inline void __put_unaligned_le16(u16 val, u8 *p)
| +{
| + *p++ = val;
| + *p++ = val >> 8;
| +}
[...]
Hi Harvey, do we really need second increments? I mean, wouldn't
be better to use *p = val >> 8 and *p << 8?
- Cyrill -
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists