linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Sean Young <sean@mess.org>
Cc: Hans Verkuil <hverkuil@xs4all.nl>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	linux-input@vger.kernel.org, linux-media@vger.kernel.org
Subject: Re: [PATCH 0/3] Improve CEC autorepeat handling
Date: Sat, 25 Nov 2017 15:47:52 -0800	[thread overview]
Message-ID: <20171125234752.2z46d3ya7qiaovby@dtor-ws> (raw)
In-Reply-To: <cover.1511523174.git.sean@mess.org>

Hi Sean,

On Fri, Nov 24, 2017 at 11:43:58AM +0000, Sean Young wrote:
> Due to the slowness of the CEC bus, autorepeat handling rather special
> on CEC. If the repeated user control pressed message is received, a 
> keydown repeat should be sent immediately.

This sounds like you want to have hardware autorepeat combined with
software one. This seems fairly specific to CEC and I do not think that
this should be in input core; but stay in the driver.

Another option just to decide what common delay for CEC autorepeat is
and rely on the standard autorepeat handling. The benefit is that users
can control the delay before autorepeat kicks in.

> 
> By handling this in the input layer, we can remove some ugly code from
> cec, which also sends a keyup event after the first keydown, to prevent
> autorepeat.

If driver does not want input core to handle autorepeat (but handle
autorepeat by themselves) they should indicate it by setting appropriate
dev->rep[REP_DELAY] and dev->rep[REP_PERIOD] before calling
input_register_device(). This will let input core know that it should
not setup its autorepeat timer.

Thanks.

-- 
Dmitry

  parent reply	other threads:[~2017-11-25 23:47 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-24 11:43 [PATCH 0/3] Improve CEC autorepeat handling Sean Young
2017-11-24 11:43 ` [PATCH 1/3] input: remove redundant check for EV_REP Sean Young
2017-11-24 11:44 ` [PATCH 2/3] input: handle case whether first repeated key triggers repeat Sean Young
2017-11-24 11:44 ` [PATCH 3/3] media: cec: move cec autorepeat handling to rc-core Sean Young
2017-11-25 23:47 ` Dmitry Torokhov [this message]
2017-11-27  9:13   ` [PATCH 0/3] Improve CEC autorepeat handling Hans Verkuil
2017-11-27  9:47     ` Sean Young
2017-11-27 10:01       ` Hans Verkuil
2017-11-27 10:11       ` Dmitry Torokhov
2017-11-27 15:43       ` Hans Verkuil

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=20171125234752.2z46d3ya7qiaovby@dtor-ws \
    --to=dmitry.torokhov@gmail.com \
    --cc=hverkuil@xs4all.nl \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=sean@mess.org \
    /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;
as well as URLs for NNTP newsgroup(s).