public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Marek Vasut <marex@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2] usb: kbd: Fix key repeat not always using
Date: Tue, 19 May 2015 19:56:22 +0200	[thread overview]
Message-ID: <201505191956.22919.marex@denx.de> (raw)
In-Reply-To: <1431521271-4493-1-git-send-email-hdegoede@redhat.com>

On Wednesday, May 13, 2015 at 02:47:51 PM, Hans de Goede wrote:
> The usb-kbd key repeat code assumes that reports get repeated every 40 ms,
> this is never true when using CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP, and
> does not always works for CONFIG_SYS_USB_EVENT_POLL and
> CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE since not all usb keyboards honor
> the usb_set_idle() command.
> 
> For CONFIG_SYS_USB_EVENT_POLL we must use usb_set_idle() since we do a
> blocking wait for the hid report, so if we do not tell the keyboard to send
> a hid report every 40ms even if nothing changes then we will block u-boot
> for 1s (the default u-boot usb interrupt packet timeout). Note that in this
> case on keyboards which do not support usb_set_idle() we loose and we
> actually get 1s latencies on other u-boot activities.
> 
> For the other poll-methods this commit stops using usb_set_idle() and
> instead repeats the last received hid-report every 40 ms as long as no new
> hid-report is received. This fixes key-repeat not working at all with
> CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP and fixes it not working with
> keyboards which do not implement usb_set_idle() when using
> CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Hi, this broke a couple of machines, quoting Tom. I'm dropping it for now.

NAK.  This introduces various breakage:
12: Merge branch 'master' of git://git.denx.de/u-boot-usb
       arm:  +   VCMA9 beagle_x15 at91rm9200ek_ram peach-pi snow smdk5250 
am43xx_evm dr
a7xx_evm_uart3 k2l_evm am43xx_evm_qspiboot smdk5420 dra7xx_evm smdk2410 
at91rm9200ek dr
a7xx_evm_qspiboot k2hk_evm k2e_evm peach-pit
   powerpc:  +   PIP405 MIP405
The powerpc board breakage is the same as some of the ARM ones so fix it
once and they'll come along.

Best regards,
Marek Vasut

      parent reply	other threads:[~2015-05-19 17:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-13 12:47 [U-Boot] [PATCH v2] usb: kbd: Fix key repeat not always using Hans de Goede
2015-05-13 20:02 ` Marek Vasut
2015-05-19 17:56 ` Marek Vasut [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201505191956.22919.marex@denx.de \
    --to=marex@denx.de \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox