Re: [PATCH] abuse of macros in swab.h

From: Andrzej Krzysztofowicz (kufel!ankry@green.mif.pg.gda.pl)
Date: Wed Sep 20 2000 - 12:47:28 EST


> +static inline __u64 ___swab16(__u64 x)
> +{
> + return (__u64)((x & (__u64)0x00000000000000ffULL) << 56) |
> + (__u64)((x & (__u64)0x000000000000ff00ULL) << 40) |
> + (__u64)((x & (__u64)0x0000000000ff0000ULL) << 24) |
> + (__u64)((x & (__u64)0x00000000ff000000ULL) << 8) |
> + (__u64)((x & (__u64)0x000000ff00000000ULL) >> 8) |
> + (__u64)((x & (__u64)0x0000ff0000000000ULL) >> 24) |
> + (__u64)((x & (__u64)0x00ff000000000000ULL) >> 40) |
> + (__u64)((x & (__u64)0xff00000000000000ULL) >> 56);
> +}

I'm afraid the above one will not compile correctly with gcc-2.7.2.3,
which is still "official" compiler (especially) for 2.2.
Old gcc versions seem not to supprt 64-bit inline functions...

Just check 2.4 compilation with CONFIG_HIGHMEM64G=y ...

Andrzej

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 21:00:23 EST