Re: [Intel-gfx] [RFC PATCH 3/3] libdrm: user mode helper for ipvr drm driver

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

 



On Tue, Oct 28, 2014 at 04:56:03PM +0000, Daniel Stone wrote:
> Hi,
> 
> On 17 October 2014 01:36, Jiang, Fei <fei.jiang@xxxxxxxxx> wrote:
> 
> > Thanks for Emil's suggestion. You are right, we need make sure structure
> > size aligned on 8 bytes, which is important for 32bit-64bit compatible case.
> 
> 
> While you're at it, please don't use enum as a type inside ioctls, since
> the size can vary by compiler. Please use a uint32_t or whatever instead,
> assigning enum values to that.

Quick correction: You must use __u32 and friends, since using the standard
C typesdef might collide with some program which defines them a different
way. The double underscore ones are explicit ok per the C standard as
private types for the system library. So they're the only ones we can use
in userspace headers.

I've thought checkpatch would bitch about this if you get it wrong, now
that we have the uapi split ...
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel





[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux