Bug in keyboard driver

Carsten Haitzler (The Rasterman) raster at openmoko.org
Thu May 8 09:26:22 CEST 2008


On Thu, 08 May 2008 00:08:21 -0700 Sean McNeil <sean at mcneil.com> babbled:

god.. THAT explains it! definite mist-have patch for the kernel this is! this
highly breaks x userspace without it.

> the KEY_PHONE is backwards. It returns up when pushed and down when 
> released. The following change fixes it:
> 
>  static irqreturn_t neo1973kbd_aux_irq(int irq, void *dev_id)
>  {
>         struct neo1973kbd *neo1973kbd_data = dev_id;
>  
> -       int key_pressed = !gpio_get_value(irq_to_gpio(irq));
> +       int key_pressed = !!gpio_get_value(irq_to_gpio(irq));
>         input_report_key(neo1973kbd_data->input, KEY_PHONE, key_pressed);
>         input_sync(neo1973kbd_data->input);
> 
> 


-- 
Carsten Haitzler (The Rasterman) <raster at openmoko.org>




More information about the openmoko-kernel mailing list