* [PATCH] HID: add keyboard input assist hid usages
@ 2014-10-17 23:53 Olivier Gay
2014-10-17 23:59 ` Dmitry Torokhov
0 siblings, 1 reply; 7+ messages in thread
From: Olivier Gay @ 2014-10-17 23:53 UTC (permalink / raw)
To: linux-input; +Cc: Jiri Kosina, Dmitry Torokhov, Mathieu Meisser, Olivier Gay
Add keyboard input assist controls usages from approved
hid usage table request HUTTR42:
http://www.usb.org/developers/hidpage/HUTRR42c.pdf
Signed-off-by: Olivier Gay <ogay@logitech.com>
---
Hi all,
this patch adds some currently missing hid usages to the
hid system.
Best regards,
Olivier
drivers/hid/hid-debug.c | 6 ++++++
drivers/hid/hid-input.c | 7 +++++++
include/uapi/linux/input.h | 7 +++++++
3 files changed, 20 insertions(+)
diff --git a/drivers/hid/hid-debug.c b/drivers/hid/hid-debug.c
index 84c3cb1..8bf61d2 100644
--- a/drivers/hid/hid-debug.c
+++ b/drivers/hid/hid-debug.c
@@ -946,6 +946,12 @@ static const char *keys[KEY_MAX + 1] = {
[KEY_BRIGHTNESS_MIN] = "BrightnessMin",
[KEY_BRIGHTNESS_MAX] = "BrightnessMax",
[KEY_BRIGHTNESS_AUTO] = "BrightnessAuto",
+ [KEY_KBDINPUTASSIST_PREV] = "KbdInputAssistPrev",
+ [KEY_KBDINPUTASSIST_NEXT] = "KbdInputAssistNext",
+ [KEY_KBDINPUTASSIST_PREVGROUP] = "KbdInputAssistPrevGroup",
+ [KEY_KBDINPUTASSIST_NEXTGROUP] = "KbdInputAssistNextGroup",
+ [KEY_KBDINPUTASSIST_ACCEPT] = "KbdInputAssistAccept",
+ [KEY_KBDINPUTASSIST_CANCEL] = "KbdInputAssistCancel",
};
static const char *relatives[REL_MAX + 1] = {
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index 2df7fdd..56c6c30 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -862,6 +862,13 @@ static void hidinput_configure_usage(struct hid_input *hidinput, struct hid_fiel
case 0x28b: map_key_clear(KEY_FORWARDMAIL); break;
case 0x28c: map_key_clear(KEY_SEND); break;
+ case 0x2c7: map_key_clear(KEY_KBDINPUTASSIST_PREV); break;
+ case 0x2c8: map_key_clear(KEY_KBDINPUTASSIST_NEXT); break;
+ case 0x2c9: map_key_clear(KEY_KBDINPUTASSIST_PREVGROUP); break;
+ case 0x2ca: map_key_clear(KEY_KBDINPUTASSIST_NEXTGROUP); break;
+ case 0x2cb: map_key_clear(KEY_KBDINPUTASSIST_ACCEPT); break;
+ case 0x2cc: map_key_clear(KEY_KBDINPUTASSIST_CANCEL); break;
+
default: goto ignore;
}
break;
diff --git a/include/uapi/linux/input.h b/include/uapi/linux/input.h
index 19df18c..9be8c13 100644
--- a/include/uapi/linux/input.h
+++ b/include/uapi/linux/input.h
@@ -738,6 +738,13 @@ struct input_keymap_entry {
#define KEY_BRIGHTNESS_MIN 0x250 /* Set Brightness to Minimum */
#define KEY_BRIGHTNESS_MAX 0x251 /* Set Brightness to Maximum */
+#define KEY_KBDINPUTASSIST_PREV 0x260
+#define KEY_KBDINPUTASSIST_NEXT 0x261
+#define KEY_KBDINPUTASSIST_PREVGROUP 0x262
+#define KEY_KBDINPUTASSIST_NEXTGROUP 0x263
+#define KEY_KBDINPUTASSIST_ACCEPT 0x264
+#define KEY_KBDINPUTASSIST_CANCEL 0x265
+
#define BTN_TRIGGER_HAPPY 0x2c0
#define BTN_TRIGGER_HAPPY1 0x2c0
#define BTN_TRIGGER_HAPPY2 0x2c1
--
1.9.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] HID: add keyboard input assist hid usages
2014-10-17 23:53 [PATCH] HID: add keyboard input assist hid usages Olivier Gay
@ 2014-10-17 23:59 ` Dmitry Torokhov
2014-10-18 15:55 ` Olivier Gay
2014-10-20 9:28 ` Jiri Kosina
0 siblings, 2 replies; 7+ messages in thread
From: Dmitry Torokhov @ 2014-10-17 23:59 UTC (permalink / raw)
To: Olivier Gay; +Cc: linux-input, Jiri Kosina, Mathieu Meisser
On Sat, Oct 18, 2014 at 01:53:39AM +0200, Olivier Gay wrote:
> Add keyboard input assist controls usages from approved
> hid usage table request HUTTR42:
> http://www.usb.org/developers/hidpage/HUTRR42c.pdf
>
> Signed-off-by: Olivier Gay <ogay@logitech.com>
> ---
>
> Hi all,
>
> this patch adds some currently missing hid usages to the
> hid system.
Who is going to be using these codes? Do we have userspace consumers?
Thanks.
--
Dmitry
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] HID: add keyboard input assist hid usages
2014-10-17 23:59 ` Dmitry Torokhov
@ 2014-10-18 15:55 ` Olivier Gay
2014-10-20 9:28 ` Jiri Kosina
1 sibling, 0 replies; 7+ messages in thread
From: Olivier Gay @ 2014-10-18 15:55 UTC (permalink / raw)
To: Dmitry Torokhov; +Cc: linux-input, Jiri Kosina, Mathieu Meisser
Hi Dmitry,
a potential consumer could be Android and Android IMEs, this would add
the ability for a HID device to select and control the suggested words
in the word prediction system when typing.
Olivier
On Fri, Oct 17, 2014 at 4:59 PM, Dmitry Torokhov
<dmitry.torokhov@gmail.com> wrote:
> On Sat, Oct 18, 2014 at 01:53:39AM +0200, Olivier Gay wrote:
>> Add keyboard input assist controls usages from approved
>> hid usage table request HUTTR42:
>> http://www.usb.org/developers/hidpage/HUTRR42c.pdf
>>
>> Signed-off-by: Olivier Gay <ogay@logitech.com>
>> ---
>>
>> Hi all,
>>
>> this patch adds some currently missing hid usages to the
>> hid system.
>
> Who is going to be using these codes? Do we have userspace consumers?
>
> Thanks.
>
> --
> Dmitry
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] HID: add keyboard input assist hid usages
2014-10-17 23:59 ` Dmitry Torokhov
2014-10-18 15:55 ` Olivier Gay
@ 2014-10-20 9:28 ` Jiri Kosina
2014-10-20 18:07 ` Dmitry Torokhov
1 sibling, 1 reply; 7+ messages in thread
From: Jiri Kosina @ 2014-10-20 9:28 UTC (permalink / raw)
To: Dmitry Torokhov; +Cc: Olivier Gay, linux-input, Mathieu Meisser
On Fri, 17 Oct 2014, Dmitry Torokhov wrote:
> > Add keyboard input assist controls usages from approved
> > hid usage table request HUTTR42:
> > http://www.usb.org/developers/hidpage/HUTRR42c.pdf
> >
> > Signed-off-by: Olivier Gay <ogay@logitech.com>
> > ---
> >
> > Hi all,
> >
> > this patch adds some currently missing hid usages to the
> > hid system.
>
> Who is going to be using these codes? Do we have userspace consumers?
As review request #42 has been approved, I don't really have strong
objections to adding this, as it means certain level of standardization by
he USB Device Working Group HID Committee.
Dmitry, given your question, I am not applying the patch yet and waiting
for your consideration/Ack.
Thanks,
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] HID: add keyboard input assist hid usages
2014-10-20 9:28 ` Jiri Kosina
@ 2014-10-20 18:07 ` Dmitry Torokhov
2014-10-20 19:04 ` Jiri Kosina
0 siblings, 1 reply; 7+ messages in thread
From: Dmitry Torokhov @ 2014-10-20 18:07 UTC (permalink / raw)
To: Jiri Kosina; +Cc: Olivier Gay, linux-input, Mathieu Meisser
Hi Jiri,
On Monday, October 20, 2014 11:28:19 AM Jiri Kosina wrote:
> On Fri, 17 Oct 2014, Dmitry Torokhov wrote:
> > > Add keyboard input assist controls usages from approved
> > > hid usage table request HUTTR42:
> > > http://www.usb.org/developers/hidpage/HUTRR42c.pdf
> > >
> > > Signed-off-by: Olivier Gay <ogay@logitech.com>
> > > ---
> > >
> > > Hi all,
> > >
> > > this patch adds some currently missing hid usages to the
> > > hid system.
> >
> > Who is going to be using these codes? Do we have userspace consumers?
>
> As review request #42 has been approved, I don't really have strong
> objections to adding this, as it means certain level of standardization by
> he USB Device Working Group HID Committee.
>
> Dmitry, given your question, I am not applying the patch yet and waiting
> for your consideration/Ack.
Please merge with my Ack for the new codes - I was not against adding them,
just wanted to make sure they are going to be used instead of just adding them
as placehoders.
Thanks.
--
Dmitry
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] HID: add keyboard input assist hid usages
2014-10-20 18:07 ` Dmitry Torokhov
@ 2014-10-20 19:04 ` Jiri Kosina
2014-10-20 21:30 ` Olivier Gay
0 siblings, 1 reply; 7+ messages in thread
From: Jiri Kosina @ 2014-10-20 19:04 UTC (permalink / raw)
To: Dmitry Torokhov; +Cc: Olivier Gay, linux-input, Mathieu Meisser
On Mon, 20 Oct 2014, Dmitry Torokhov wrote:
> > As review request #42 has been approved, I don't really have strong
> > objections to adding this, as it means certain level of standardization by
> > he USB Device Working Group HID Committee.
> >
> > Dmitry, given your question, I am not applying the patch yet and waiting
> > for your consideration/Ack.
>
> Please merge with my Ack for the new codes - I was not against adding them,
> just wanted to make sure they are going to be used instead of just adding them
> as placehoders.
That was my understanding, but I wanted to be sure.
Thanks everybody, now queued in hid.git#for-3.18/upstream-fixes
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] HID: add keyboard input assist hid usages
2014-10-20 19:04 ` Jiri Kosina
@ 2014-10-20 21:30 ` Olivier Gay
0 siblings, 0 replies; 7+ messages in thread
From: Olivier Gay @ 2014-10-20 21:30 UTC (permalink / raw)
To: Jiri Kosina; +Cc: Dmitry Torokhov, linux-input, Mathieu Meisser
On Mon, Oct 20, 2014 at 12:04 PM, Jiri Kosina <jkosina@suse.cz> wrote:
> On Mon, 20 Oct 2014, Dmitry Torokhov wrote:
>> Please merge with my Ack for the new codes - I was not against adding them,
>> just wanted to make sure they are going to be used instead of just adding them
>> as placehoders.
>
> That was my understanding, but I wanted to be sure.
>
> Thanks everybody, now queued in hid.git#for-3.18/upstream-fixes
OK, thank you Jiri and Dmitry!
Olivier
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2014-10-20 21:31 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-17 23:53 [PATCH] HID: add keyboard input assist hid usages Olivier Gay
2014-10-17 23:59 ` Dmitry Torokhov
2014-10-18 15:55 ` Olivier Gay
2014-10-20 9:28 ` Jiri Kosina
2014-10-20 18:07 ` Dmitry Torokhov
2014-10-20 19:04 ` Jiri Kosina
2014-10-20 21:30 ` Olivier Gay
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).