Re: [PATCH v3] Input: evdev - add event-mask API

2014-11-13 Thread David Herrmann
Hi On Wed, Nov 12, 2014 at 1:41 PM, David Herrmann dh.herrm...@gmail.com wrote: Hi On Wed, Nov 12, 2014 at 8:40 AM, Dmitry Torokhov dmitry.torok...@gmail.com wrote: Hi David, On Tue, Nov 04, 2014 at 06:12:23PM +0100, David Herrmann wrote: +static int bits_from_user(unsigned long *bits,

Re: [PATCH v3] Input: evdev - add event-mask API

2014-11-12 Thread David Herrmann
Hi On Wed, Nov 12, 2014 at 8:40 AM, Dmitry Torokhov dmitry.torok...@gmail.com wrote: Hi David, On Tue, Nov 04, 2014 at 06:12:23PM +0100, David Herrmann wrote: +static int bits_from_user(unsigned long *bits, unsigned int maxbit, + unsigned int maxlen, const void __user

Re: [PATCH v3] Input: evdev - add event-mask API

2014-11-11 Thread Dmitry Torokhov
Hi David, On Tue, Nov 04, 2014 at 06:12:23PM +0100, David Herrmann wrote: +static int bits_from_user(unsigned long *bits, unsigned int maxbit, + unsigned int maxlen, const void __user *p, int compat) +{ + int len; + +#if IS_ENABLED(CONFIG_COMPAT) + if (compat)

[PATCH v3] Input: evdev - add event-mask API

2014-11-04 Thread David Herrmann
Hardware manufacturers group keys in the weirdest way possible. This may cause a power-key to be grouped together with normal keyboard keys and thus be reported on the same kernel interface. However, user-space is often only interested in specific sets of events. For instance, daemons dealing

Re: [PATCH v3] Input: evdev - add event-mask API

2014-07-03 Thread David Herrmann
Hi Dmitry On Wed, Jun 18, 2014 at 7:42 AM, David Herrmann dh.herrm...@gmail.com wrote: Hardware manufacturers group keys in the weirdest way possible. This may cause a power-key to be grouped together with normal keyboard keys and thus be reported on the same kernel interface. However,