linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Cc: Sean Young <sean@mess.org>,
	linux-input@vger.kernel.org, linux-media@vger.kernel.org
Subject: Re: [PATCH] [media/input] rc: report rc protocol type to userspace through input
Date: Fri, 23 Sep 2016 15:08:31 -0700	[thread overview]
Message-ID: <20160923220831.GE25499@dtor-ws> (raw)
In-Reply-To: <20160922115713.7f341c46@vento.lan>

On Thu, Sep 22, 2016 at 11:57:13AM -0300, Mauro Carvalho Chehab wrote:
> Em Wed, 21 Sep 2016 10:54:21 +0100
> Sean Young <sean@mess.org> escreveu:
> 
> > We might want to know what protocol a remote uses when we do not know. With
> > this patch and another patch for v4l-utils (follows), you can do that with:
> > 
> > ./ir-keytable  -p rc-5,nec,rc-6,jvc,sony,sanyo,sharp,xmp -t
> > Testing events. Please, press CTRL-C to abort.
> > 1474415431.689685: event type EV_MSC(0x04): protocol = RC_TYPE_RC6_MCE
> > 1474415431.689685: event type EV_MSC(0x04): scancode = 0x800f040e
> > 1474415431.689685: event type EV_SYN(0x00).
> > 
> > This makes RC_TYPE_* part of the ABI. We also remove the enum rc_type,
> > since in input-event-codes.h we cannot not use enums.
> > 
> > In addition, now that the input layer knows the rc protocol and scancode,
> > at a later point we could add a feature where keymaps could be created
> > based on both protocol and scancode, not just scancode.
> 
> We need Dmitry's ack in order to apply this one.

I'd rather not: I am trying to keep input API hardware-independent and
the kind of device emitting keycodes (a remote control in the sense of
drivers/media/rc or USB device or BT device) should not really matter to
consumers. Similarly how we do not export whether device is USB1.1 or
USB2 or USB3 (although we do have input->id.bustype, but it is more for
identification purposes rather than for adjusting properties).

For configuration (like loading keymaps) we can examine
parent hardware device and decide.

Thanks.

-- 
Dmitry

  reply	other threads:[~2016-09-23 22:08 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-21  9:54 [PATCH] [media/input] rc: report rc protocol type to userspace through input Sean Young
2016-09-22 14:57 ` Mauro Carvalho Chehab
2016-09-23 22:08   ` Dmitry Torokhov [this message]
2016-09-25 13:00     ` Sean Young

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=20160923220831.GE25499@dtor-ws \
    --to=dmitry.torokhov@gmail.com \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@s-opensource.com \
    --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).