On Sun, Aug 28, 2005 at 04:05:07PM -0500, Eric Van Hensbergen wrote:
> [PATCH] v9fs: use standard kernel byteswapping routines
>
> Originally suggested by hch, we have removed our byteswap code
> and replaced it with calls to the standard kernel byteswapping code.
> - buf->p[0] = val;
> - buf->p[1] = val >> 8;
> + *(u16 *) buf->p = cpu_to_le16(val);
*(__le16 *)
> - ret = buf->p[0] | (buf->p[1] << 8);
> + ret = le16_to_cpu(*(u16 *)buf->p);
*(__le16 *) etc.
Otherwise sparse will warn.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
|
|