[U-Boot] [PATCH 1/5] input: Use finer grain udelays while waitng for the i8042 keyboard buffer to empty

Graeme Russ graeme.russ at gmail.com
Fri Oct 12 05:55:47 CEST 2012


Hi Simon,

On Fri, Oct 12, 2012 at 12:15 PM, Simon Glass <sjg at chromium.org> wrote:

> diff --git a/drivers/input/i8042.c b/drivers/input/i8042.c
> index c3bc536..99254e4 100644
> --- a/drivers/input/i8042.c
> +++ b/drivers/input/i8042.c
> @@ -607,11 +607,10 @@ static void kbd_led_set(void)
>
>  static int kbd_input_empty(void)
>  {
> -       int kbdTimeout = KBD_TIMEOUT;
> +       int kbdTimeout = KBD_TIMEOUT * 1000;
>
> -       /* wait for input buf empty */
>         while ((in8(I8042_STATUS_REG) & 0x02) && kbdTimeout--)

I know this magic number was already here, but later patches introduce
even more. Any chance these can be cleaned up as well?

Regards,

Graeme


More information about the U-Boot mailing list