Re: [PATCH] Add be*/le* types without underscores

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Sun, 30 Oct 2005, Herbert Xu wrote:
> 
> Of course userspace won't see them since they're protected by
> #ifdef __KERNEL__.
> 
> Signed-off-by: Herbert Xu <[email protected]>

This won't work, I think.

sparse basically always creates a _new_type_ for a bitwise typedef, so 
when you do

	typedef u16 __bitwise le16;
	typedef u16 __bitwise be16;
	...

your new "le16" will be _different_ from the old __le16, and you can't use 
it with "cpu_to_le16()" and other things.

I think that

	typedef __le16 le16;

should do what you want, but you should check.

		Linus
-
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]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux