From: James Hogan <james.hogan@imgtec.com>
To: "David Härdeman" <david@hardeman.nu>
Cc: "Antti Seppälä" <a.seppala@gmail.com>,
"Mauro Carvalho Chehab" <m.chehab@samsung.com>,
linux-media@vger.kernel.org
Subject: Re: [PATCH 1/5] rc-main: add generic scancode filtering
Date: Wed, 26 Mar 2014 15:54:01 +0000 [thread overview]
Message-ID: <5332F819.2040207@imgtec.com> (raw)
In-Reply-To: <e38b3c86fdbfa448549762a6a700c296@hardeman.nu>
[-- Attachment #1: Type: text/plain, Size: 2675 bytes --]
On 26/03/14 13:44, David Härdeman wrote:
> On 2014-03-26 08:08, Antti Seppälä wrote:
>> On 26 March 2014 01:21, David Härdeman <david@hardeman.nu> wrote:
>>> On Tue, Mar 25, 2014 at 09:12:11AM +0000, James Hogan wrote:
>>>> On Tuesday 25 March 2014 00:51:46 David Härdeman wrote:
>>>>> What's the purpose of providing the sw scancode filtering in the
>>>>> case where
>>>>> there's no hardware filtering support at all?
>>>>
>>>> Consistency is probably the main reason, but I'll admit it's not
>>>> perfectly
>>>> consistent between generic/hardware filtering (mostly thanks to NEC
>>>> scancode
>>>> complexities), and I have no particular objection to dropping it if
>>>> that isn't
>>>> considered a good enough reason.
>>>
>>> I'm kind of sceptical...and given how difficult it is to remove
>>> functionality that is in a released kernel...I think that particular
>>> part (i.e. the software filtering) should be removed until it has had
>>> further discussion...
> ...
>>> I don't understand. What's the purpose of a "software fallback" for
>>> scancode filtering? Antti?
>>>
>>
>> Well since the ImgTec patches will create a new sysfs interface for
>> the HW scancode filtering I figured that it would be nice for it to
>> also function on devices which lack the hardware filtering
>> capabilities. Especially since it's only three lines of code. :)
>>
>> Therefore I suggested the software fallback. At the time I had no clue
>> that there might be added complexities with nec scancodes.
>
> It's not only NEC scancodes, the sw scancode filter is state that is
> changeable from user-space and which will require reader/writer
> synchronization during the RX path (which is the "hottest" path in
> rc-core). I've posted patches before which make the RX path lockless,
> this change makes complicates such changes.
>
> Additionally, the provision of the sw fallback means that userspace has
> no idea if there is an actual hardware filter present or not, meaning
> that a userspace program that is aware of the scancode filter will
> always enable it.
>
> So, I still think the SW part should be reverted, at least for now (i.e.
> the sysfs file should only be present if there is hardware support).
I've prepared a revert patch (which also reverts a part of a later patch
which takes SW filtering into account when updating the filter on a
protocol change). I'll double check it works right later and submit.
Note that this still leaves the sysfs nodes there though, but if
!s_filter then they read as 0 and only accept the value 0 to be written
(mask == 0 represents no filtering).
Cheers
James
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2014-03-26 15:54 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-28 23:17 [PATCH 0/5] rc: scancode filtering improvements James Hogan
2014-02-28 23:17 ` [PATCH 1/5] rc-main: add generic scancode filtering James Hogan
2014-03-24 23:51 ` David Härdeman
2014-03-25 9:12 ` James Hogan
2014-03-25 23:21 ` David Härdeman
2014-03-26 7:08 ` Antti Seppälä
2014-03-26 13:44 ` David Härdeman
2014-03-26 15:54 ` James Hogan [this message]
2014-02-28 23:17 ` [PATCH 2/5] rc: abstract access to allowed/enabled protocols James Hogan
2014-02-28 23:17 ` [PATCH 3/5] rc: add allowed/enabled wakeup protocol masks James Hogan
2014-02-28 23:17 ` [PATCH 4/5] rc: add wakeup_protocols sysfs file James Hogan
2014-02-28 23:17 ` [PATCH 5/5] rc-main: automatically refresh filter on protocol change James Hogan
2014-03-05 18:12 ` [PATCH 0/5] rc: scancode filtering improvements Antti Seppälä
2014-03-05 23:17 ` James Hogan
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=5332F819.2040207@imgtec.com \
--to=james.hogan@imgtec.com \
--cc=a.seppala@gmail.com \
--cc=david@hardeman.nu \
--cc=linux-media@vger.kernel.org \
--cc=m.chehab@samsung.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.