caiaq/NativeInstruments: input handling fixes
Subsystems (2)
PATCH 1/2 caiaq/NativeInstruments: input handling fixes
Hi,
I'm re-posting a patch from Dmitry Torokhov which cleans up some input layer related things. It hasn't made its way to any repository yet but my subsequent patch needs it as dependency. I Cc'ed Dmitry to avoid confusion.
Subject: SOUND: caiaq - misc input handling fixes
From: Dmitry Torokhov <[email protected]>
SOUND: caiaq - misc input handling fixes
- link input device with its parent so that it placed in proper spot in sysfs hierarchy
- drivers that allow changing their keymaps should use private copy of the keymap so that one instance of a device does not affect another instance
- it is preferred for drivers to properly set up input_dev->phys to help userspace locate devices
- drivers should use usb_to_input_id(), or perform endianess conversion, themselves, otherwise ID is not correct on big-endian boxes
- whitespace and formatting cleanup
sound/usb/caiaq/caiaq-device.h +6 -4
@@ -7,7 +7,7 @@#define USB_PID_RIGKONTROL2 0x1969#define USB_PID_RIGKONTROL3 0x1940 -#define USB_PID_KORECONTROLLER 0x4711 +#define USB_PID_KORECONTROLLER 0x4711#define USB_PID_AK1 0x0815#define USB_PID_AUDIO8DJ 0x1978
@@ -62,7 +62,7 @@ struct snd_usb_caiaqdev {struct urb **data_urbs_in;struct urb **data_urbs_out;struct snd_usb_caiaq_cb_info *data_cb_info; - +unsigned char ep1_in_buf[EP1_BUFSIZE ];unsigned char ep1_out_buf[EP1_BUFSIZE ];unsigned char midi_out_buf[EP1_BUFSIZE ];
@@ -72,7 +72,7 @@ struct snd_usb_caiaqdev {wait_queue_head_t ep1_wait_queue;wait_queue_head_t prepare_wait_queue;int spec_received, audio_parm_answer; - +char vendor_name[CAIAQ_USB_STR_LEN ];char product_name[CAIAQ_USB_STR_LEN ];char serial[CAIAQ_USB_STR_LEN ];
@@ -93,8 +93,10 @@ struct snd_usb_caiaqdev {/* Linux input */ #ifdef CONFIG_SND_USB_CAIAQ_INPUT struct input_dev *input_dev; +char phys[64 ];/* physical device path */ +unsigned short keycode[10 ];#endif - +/* ALSA */ struct snd_pcm *pcm;struct snd_pcm_hardware pcm_info;
sound/usb/caiaq/caiaq-input.c +66 -62
236 lines not on this page · raw message
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
At Tue, 20 Nov 2007 14:35:28 +0100,
Quoted 7 lines · Daniel Mack
Hi,
I'm re-posting a patch from Dmitry Torokhov which cleans up some input layer related things. It hasn't made its way to any repository yet but my subsequent patch needs it as dependency. I Cc'ed Dmitry to avoid confusion.
Dmitry, will this patch go to 2.6.24 from your tree?
If it's a 2.6.25 material, then I'd like to put it rather to ALSA tree together with Daniel's another patch.
thanks,
Takashi
Quoted 7 lines · Takashi Iwai
At Tue, 20 Nov 2007 14:35:28 +0100,
Quoted 5 lines · Daniel Mack
Hi,
I'm re-posting a patch from Dmitry Torokhov which cleans up some input layer related things. It hasn't made its way to any repository yet but
Yes, I am being slow lately, sorry.
Quoted 6 lines
Quoted 2 lines
my subsequent patch needs it as dependency. I Cc'ed Dmitry to avoid confusion.
Dmitry, will this patch go to 2.6.24 from your tree?
If it's a 2.6.25 material,
Yes, it is .25 material.
Quoted 2 lines
then I'd like to put it rather to ALSA
tree together with Daniel's another patch.
Thet would be great. The only reason I offered to send through my tree is that I did not see any response from you guys... I actually prefer not to touch code outside of drivers/input.
BTW, attached is a small Kconfig patchs for caiaq. Probably good for .24.
Signature · 1 line
Dmitry
SOUND: caiaq - input device support must depend on CONFIG_INPUT
--- sound/usb/Kconfig | 1 + 1 file changed, 1 insertion(+)
sound/usb/Kconfig +1 -0
@@ -51,6 +51,7 @@ config SND_USB_CAIAQ config SND_USB_CAIAQ_INPUT bool "enable input device for controllers" depends on SND_USB_CAIAQ + depends on INPUT=y || INPUT=SND_USB_CAIAQ help Say Y here to support input controllers like buttons, knobs, alpha dials and analog pedals on the following products:
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
At Wed, 21 Nov 2007 08:34:33 -0500,
Quoted 19 lines · Dmitry Torokhov
Quoted 7 lines · Takashi Iwai
At Tue, 20 Nov 2007 14:35:28 +0100,
Quoted 5 lines · Daniel Mack
Hi,
I'm re-posting a patch from Dmitry Torokhov which cleans up some input layer related things. It hasn't made its way to any repository yet but
Yes, I am being slow lately, sorry.
Quoted 6 lines
Quoted 2 lines
my subsequent patch needs it as dependency. I Cc'ed Dmitry to avoid confusion.
Dmitry, will this patch go to 2.6.24 from your tree?
If it's a 2.6.25 material,
Quoted 8 lines
Yes, it is .25 material.
Quoted 2 lines
then I'd like to put it rather to ALSA
tree together with Daniel's another patch.Thet would be great. The only reason I offered to send through my tree is that I did not see any response from you guys... I actually prefer not to touch code outside of
drivers/input.
Well, I didn't apply it just because I thought you prefer pushing it to 2.6.24 :) If it's for 25, no problem to put to ALSA tree.
Quoted 1 line
BTW, attached is a small
Kconfigpatchs for caiaq. Probably good for .24.
OK, will add this, too.
Thanks,
Takashi
At Wed, 21 Nov 2007 14:05:56 +0100,
Quoted 27 lines · I wrote:
At Wed, 21 Nov 2007 08:34:33 -0500,
Quoted 24 lines · Dmitry Torokhov
Quoted 7 lines · Takashi Iwai
At Tue, 20 Nov 2007 14:35:28 +0100,
Quoted 5 lines · Daniel Mack
Hi,
I'm re-posting a patch from Dmitry Torokhov which cleans up some input layer related things. It hasn't made its way to any repository yet but
Yes, I am being slow lately, sorry.
Quoted 6 lines
Quoted 2 lines
my subsequent patch needs it as dependency. I Cc'ed Dmitry to avoid confusion.
Dmitry, will this patch go to 2.6.24 from your tree?
If it's a 2.6.25 material,
Yes, it is .25 material.
Quoted 2 lines
then I'd like to put it rather to ALSA
tree together with Daniel's another patch.
Quoted 6 lines
Quoted 3 lines
Thet would be great. The only reason I offered to send through my tree is that I did not see any response from you guys... I actually prefer not to touch code outside of
drivers/input.Well, I didn't apply it just because I thought you prefer pushing it to 2.6.24 :) If it's for 25, no problem to put to ALSA tree.
Now it's on ALSA HG tree. I fixed two tiny coding issues checkpatch.pl reported.
Quoted 3 lines
Quoted 1 line
BTW, attached is a small
Kconfigpatchs for caiaq. Probably good for .24.OK, will add this, too.
Applied this, too.
Thanks.
Takashi
Quoted 33 lines · Takashi Iwai
At Wed, 21 Nov 2007 14:05:56 +0100,
Quoted 31 lines · I wrote:
At Wed, 21 Nov 2007 08:34:33 -0500,
Quoted 27 lines · Dmitry Torokhov
Quoted 7 lines · Takashi Iwai
At Tue, 20 Nov 2007 14:35:28 +0100,
Quoted 5 lines · Daniel Mack
Hi,
I'm re-posting a patch from Dmitry Torokhov which cleans up some input layer related things. It hasn't made its way to any repository yet but
Yes, I am being slow lately, sorry.
Quoted 6 lines
Quoted 2 lines
my subsequent patch needs it as dependency. I Cc'ed Dmitry to avoid confusion.
Dmitry, will this patch go to 2.6.24 from your tree?
If it's a 2.6.25 material,
Yes, it is .25 material.
Quoted 2 lines
then I'd like to put it rather to ALSA
tree together with Daniel's another patch.Thet would be great. The only reason I offered to send through my tree is that I did not see any response from you guys... I actually prefer not to touch code outside of
drivers/input.
Quoted 6 lines
Quoted 2 lines
Well, I didn't apply it just because I thought you prefer pushing it to 2.6.24 :) If it's for 25, no problem to put to ALSA tree.
Now it's on ALSA HG tree. I fixed two tiny coding issues checkpatch.pl reported.
Thank you.
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
BTW, attached is a small
Kconfigpatchs for caiaq. Probably good for .24.OK, will add this, too.
Applied this, too.
Great, thank you Takashi.
Signature · 1 line
Dmitry