Re: u32 vs. __u32 (and what is __attribute__((bitwise) ?)

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

 



On Sat, Jan 20, 2007 at 06:10:40PM +0200, Ramagudi Naziir wrote:
> >Otherwise, use u32 or __u32, the latter alone if exported to user space.
> 
> can you please explain this too ? what is the difference ? what is a value
> that is exported to user space ?

If you have a struct that is only internal to the kernel, you can use
either u32 or __u32.  It will normally be inside a #ifdef __KERNEL__ in
the header files.  If regular applications use the struct, and it is
outside #ifdef __KERNEL__, then it should be __u32, otherwise it could
conflict with the application's own typedefs.

-- 
Bob Copeland %% www.bobcopeland.com 


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux