lkml.org 
[lkml]   [2010]   [Dec]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [RFC][PATCH] input: Introduce device information ioctl
Date
On Tuesday 07 December 2010, Kay Sievers wrote:
> >> Oh, how does that work? With the ioctl call, userspace has to supply
> >> the size it expects to be returned from the kernel. How does the
> >> kernel otherwise know how much it is allowed to copy to the user?
> >
> > The ioctl command number itself is calculated from the size of the
> > data that gets passed:
> >
> > #define EVIOCGDEVINFO _IOR('E', 0x09, struct input_devinfo)
> >
> > If struct input_devinfo ever changes (which it can, but should not),
> > the command changes as well.
>
> So unlike statet, it's not extensible, and this struct and this ioctl
> can never change?

Exactly. We have plenty of unused ioctl numbers free though.

Arnd


\
 
 \ /
  Last update: 2010-12-07 13:57    [W:0.044 / U:0.184 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site