All of lore.kernel.org
 help / color / mirror / Atom feed
* ELAN0732 I2C Touchscreen Driver
@ 2017-03-20  6:26 M K
  2017-03-21  4:45 ` Dmitry Torokhov
  0 siblings, 1 reply; 13+ messages in thread
From: M K @ 2017-03-20  6:26 UTC (permalink / raw)
  To: linux-input

Is there a compatible driver for this device?  I've tried loading
various modules with no success (elants_i2c, hid_multitouch, etc.).

The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00

However, xinput does not list it at all.

This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display,
and AMD FX-9800P processor.

Scott Liu suggested I try posting here.


Thanks!

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-03-20  6:26 ELAN0732 I2C Touchscreen Driver M K
@ 2017-03-21  4:45 ` Dmitry Torokhov
  2017-03-21  5:48   ` 劉嘉駿
  2017-03-21  5:55   ` 廖崇榮
  0 siblings, 2 replies; 13+ messages in thread
From: Dmitry Torokhov @ 2017-03-21  4:45 UTC (permalink / raw)
  To: M K, 廖崇榮; +Cc: linux-input, ELAN 劉嘉駿

On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
> Is there a compatible driver for this device?  I've tried loading
> various modules with no success (elants_i2c, hid_multitouch, etc.).
>
> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00

You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c
to load and bind to the device.

>
> However, xinput does not list it at all.
>
> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display,
> and AMD FX-9800P processor.
>
> Scott Liu suggested I try posting here.

Hmm, I'd expect Scott to know if elants_i2c could theoretically drive
this device. KT, do you know by chance?

Thanks.

-- 
Dmitry

^ permalink raw reply	[flat|nested] 13+ messages in thread

* RE: ELAN0732 I2C Touchscreen Driver
  2017-03-21  4:45 ` Dmitry Torokhov
@ 2017-03-21  5:48   ` 劉嘉駿
  2017-03-21 17:01     ` 'Dmitry Torokhov'
  2017-03-21  5:55   ` 廖崇榮
  1 sibling, 1 reply; 13+ messages in thread
From: 劉嘉駿 @ 2017-03-21  5:48 UTC (permalink / raw)
  To: 'Dmitry Torokhov', 'M K',
	'廖崇榮'
  Cc: linux-input, james.chen

As far as I known, It is hidi2c device and not be supported by elants_i2c module.
elants_i2c module is for chrome i2c device.

I supposed hidi2c driver can support this device but don't know why it doesn't work?

Thanks,
Scott

-----Original Message-----
From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com] 
Sent: Tuesday, March 21, 2017 12:45 PM
To: M K; 廖崇榮
Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
Subject: Re: ELAN0732 I2C Touchscreen Driver

On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
> Is there a compatible driver for this device?  I've tried loading 
> various modules with no success (elants_i2c, hid_multitouch, etc.).
>
> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00

You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.

>
> However, xinput does not list it at all.
>
> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display, 
> and AMD FX-9800P processor.
>
> Scott Liu suggested I try posting here.

Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?

Thanks.

--
Dmitry


^ permalink raw reply	[flat|nested] 13+ messages in thread

* RE: ELAN0732 I2C Touchscreen Driver
  2017-03-21  4:45 ` Dmitry Torokhov
  2017-03-21  5:48   ` 劉嘉駿
@ 2017-03-21  5:55   ` 廖崇榮
  2017-03-28  3:06     ` Johnny.Chuang
  1 sibling, 1 reply; 13+ messages in thread
From: 廖崇榮 @ 2017-03-21  5:55 UTC (permalink / raw)
  To: 'Dmitry Torokhov', 'M K'
  Cc: linux-input, 'ELAN 劉嘉駿',
	'Johnny.Chuang'

Add Johnny who handle ELAN touchscreen in loop.

-----Original Message-----
From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com] 
Sent: Tuesday, March 21, 2017 12:45 PM
To: M K; 廖崇榮
Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
Subject: Re: ELAN0732 I2C Touchscreen Driver

On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
> Is there a compatible driver for this device?  I've tried loading 
> various modules with no success (elants_i2c, hid_multitouch, etc.).
>
> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00

You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.

>
> However, xinput does not list it at all.
>
> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display, 
> and AMD FX-9800P processor.
>
> Scott Liu suggested I try posting here.

Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
Hi Johnny,
	Could you help to check this TS issue
Thanks.

--
Dmitry


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-03-21  5:48   ` 劉嘉駿
@ 2017-03-21 17:01     ` 'Dmitry Torokhov'
  2017-03-22  3:30       ` M K
  0 siblings, 1 reply; 13+ messages in thread
From: 'Dmitry Torokhov' @ 2017-03-21 17:01 UTC (permalink / raw)
  To: 劉嘉駿
  Cc: 'M K', '廖崇榮',
	linux-input, james.chen

On Tue, Mar 21, 2017 at 01:48:57PM +0800, 劉嘉駿 wrote:
> As far as I known, It is hidi2c device and not be supported by elants_i2c module.
> elants_i2c module is for chrome i2c device.
> 
> I supposed hidi2c driver can support this device but don't know why it doesn't work?

i2c-hid driver binds to ACPI0C50 or PNP0C50 devices. MK, could you
please post snippet of your DTSD with ELAN0732 device?

> 
> Thanks,
> Scott
> 
> -----Original Message-----
> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com] 
> Sent: Tuesday, March 21, 2017 12:45 PM
> To: M K; 廖崇榮
> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
> Subject: Re: ELAN0732 I2C Touchscreen Driver
> 
> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
> > Is there a compatible driver for this device?  I've tried loading 
> > various modules with no success (elants_i2c, hid_multitouch, etc.).
> >
> > The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
> 
> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
> 
> >
> > However, xinput does not list it at all.
> >
> > This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display, 
> > and AMD FX-9800P processor.
> >
> > Scott Liu suggested I try posting here.
> 
> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
> 
> Thanks.
> 
> --
> Dmitry
> 

-- 
Dmitry

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-03-21 17:01     ` 'Dmitry Torokhov'
@ 2017-03-22  3:30       ` M K
  0 siblings, 0 replies; 13+ messages in thread
From: M K @ 2017-03-22  3:30 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: 劉嘉駿, 廖崇榮,
	linux-input, james.chen

Hi Dmitry,

What do you mean by DTSD?

Also, in my quest for answers I came across a bug report from a
different user who happens to have this exact same laptop model.  They
attached all kinds of debugging logs.

However, I'm not having any of these issues (I checked journalctl and dmesg):
https://patchwork.kernel.org/patch/9318703/




On Tue, Mar 21, 2017 at 12:01 PM, Dmitry Torokhov
<dmitry.torokhov@gmail.com> wrote:
> On Tue, Mar 21, 2017 at 01:48:57PM +0800, 劉嘉駿 wrote:
>> As far as I known, It is hidi2c device and not be supported by elants_i2c module.
>> elants_i2c module is for chrome i2c device.
>>
>> I supposed hidi2c driver can support this device but don't know why it doesn't work?
>
> i2c-hid driver binds to ACPI0C50 or PNP0C50 devices. MK, could you
> please post snippet of your DTSD with ELAN0732 device?
>
>>
>> Thanks,
>> Scott
>>
>> -----Original Message-----
>> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
>> Sent: Tuesday, March 21, 2017 12:45 PM
>> To: M K; 廖崇榮
>> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>
>> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>> > Is there a compatible driver for this device?  I've tried loading
>> > various modules with no success (elants_i2c, hid_multitouch, etc.).
>> >
>> > The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>>
>> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>>
>> >
>> > However, xinput does not list it at all.
>> >
>> > This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display,
>> > and AMD FX-9800P processor.
>> >
>> > Scott Liu suggested I try posting here.
>>
>> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
>>
>> Thanks.
>>
>> --
>> Dmitry
>>
>
> --
> Dmitry

^ permalink raw reply	[flat|nested] 13+ messages in thread

* RE: ELAN0732 I2C Touchscreen Driver
  2017-03-21  5:55   ` 廖崇榮
@ 2017-03-28  3:06     ` Johnny.Chuang
  2017-03-28  8:13       ` M K
  0 siblings, 1 reply; 13+ messages in thread
From: Johnny.Chuang @ 2017-03-28  3:06 UTC (permalink / raw)
  To: '廖崇榮', 'Dmitry Torokhov',
	'M K'
  Cc: linux-input, 'ELAN 劉嘉駿'

Hi Dmitry,

Sorry for late response.

ELAN0732 is hid over i2c touch screen device.
There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
Please make i2c-hid.c as build-in driver or module.

And please also add VID/PID at hid-ids.h and hid-multitouch.c
drivers/hid/hid-ids.h
	#define USB_VENDOR_ID_ELAN	0x04f3
	#define USB_DEVICE_ID_ELAN_A	0x0732
	#define USB_DEVICE_ID_ELAN_B	0x000b
drivers/hid/hid-multitouch.c
        /* Elan i2c-hid TouchSystems panel */
        { .driver_data = MT_CLS_DEFAULT,
                HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
                        USB_DEVICE_ID_ELAN_A) },

Many thanks,
Johnny
-----Original Message-----
From: 廖崇榮 [mailto:kt.liao@emc.com.tw] 
Sent: Tuesday, March 21, 2017 1:55 PM
To: 'Dmitry Torokhov'; 'M K'
Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
Subject: RE: ELAN0732 I2C Touchscreen Driver

Add Johnny who handle ELAN touchscreen in loop.

-----Original Message-----
From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
Sent: Tuesday, March 21, 2017 12:45 PM
To: M K; 廖崇榮
Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
Subject: Re: ELAN0732 I2C Touchscreen Driver

On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
> Is there a compatible driver for this device?  I've tried loading 
> various modules with no success (elants_i2c, hid_multitouch, etc.).
>
> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00

You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.

>
> However, xinput does not list it at all.
>
> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display, 
> and AMD FX-9800P processor.
>
> Scott Liu suggested I try posting here.

Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
Hi Johnny,
	Could you help to check this TS issue
Thanks.

--
Dmitry


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-03-28  3:06     ` Johnny.Chuang
@ 2017-03-28  8:13       ` M K
  2017-03-28  8:15         ` M K
  0 siblings, 1 reply; 13+ messages in thread
From: M K @ 2017-03-28  8:13 UTC (permalink / raw)
  To: Johnny.Chuang
  Cc: 廖崇榮,
	Dmitry Torokhov, linux-input, ELAN 劉嘉駿

Hi Johnny,

Did you mean to add the {.driver_data...} to a static in i2c-hid.c, or
in hid-multitouch.c?  If so, where?  After downloading the kernel
source and building these modules, it looks to me like
hid-multitouch.c is its own module (part of the Makefile for
"M=drivers/hid") separate from i2c-hid ("M=drivers/hid/i2c-hid")

Also, the comments in hid-multitouch.c state that definitions for
items using MT_CLS_DEFAULT don't do anything.  Finally, what device
type should I use?  The code you provided won't compile, because the
HID_DEVICE() macro expects another argument.  I presume this would be
"HID_GROUP_MULTITOUCH" ?

After trying the above, I recompiled the two modules and re-installed
them in my kernel using modprobe.  However, I could find no evidence
that the ELAN0732 device was actually detected as an input device (cat
/proc/bus/input/devices, and xinput both don't show anything new).  I
also tried rebooting (however, neither of these modules is in the
standard initramfs for Arch Linux, so I don't think rebooting is
necessary).

Any other ideas?

Also, here's a snippet of the DxDiag report from Windows..for this
vendor ID, it lists 4 devices (0x2B28)...not sure if this is the same
piece of hardware or not:
"-------------------
DirectInput Devices
-------------------
      Device Name: Mouse
         Attached: 1
    Controller ID: n/a
Vendor/Product ID: n/a
        FF Driver: n/a

      Device Name: Keyboard
         Attached: 1
    Controller ID: n/a
Vendor/Product ID: n/a
        FF Driver: n/a

      Device Name: HIDI2C Device
         Attached: 1
    Controller ID: 0x0
Vendor/Product ID: 0x04F3, 0x2B28
        FF Driver: n/a

      Device Name: HIDI2C Device
         Attached: 1
    Controller ID: 0x0
Vendor/Product ID: 0x04F3, 0x2B28
        FF Driver: n/a

      Device Name: HIDI2C Device
         Attached: 1
    Controller ID: 0x0
Vendor/Product ID: 0x04F3, 0x2B28
        FF Driver: n/a

      Device Name: HIDI2C Device
         Attached: 1
    Controller ID: 0x0
Vendor/Product ID: 0x04F3, 0x2B28
        FF Driver: n/a

      Device Name: HP Wireless Button Driver
         Attached: 1
    Controller ID: 0x0
Vendor/Product ID: 0x0001, 0x0001
        FF Driver: n/a

      Device Name: ST_SENSOR_HUB
         Attached: 1
    Controller ID: 0x0
Vendor/Product ID: 0x0483, 0x91D1
        FF Driver: n/a

Poll w/ Interrupt: No

-----------"




Thanks,

MK


On Mon, Mar 27, 2017 at 10:06 PM, Johnny.Chuang
<johnny.chuang@emc.com.tw> wrote:
> Hi Dmitry,
>
> Sorry for late response.
>
> ELAN0732 is hid over i2c touch screen device.
> There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
> Please make i2c-hid.c as build-in driver or module.
>
> And please also add VID/PID at hid-ids.h and hid-multitouch.c
> drivers/hid/hid-ids.h
>         #define USB_VENDOR_ID_ELAN      0x04f3
>         #define USB_DEVICE_ID_ELAN_A    0x0732
>         #define USB_DEVICE_ID_ELAN_B    0x000b
> drivers/hid/hid-multitouch.c
>         /* Elan i2c-hid TouchSystems panel */
>         { .driver_data = MT_CLS_DEFAULT,
>                 HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
>                         USB_DEVICE_ID_ELAN_A) },
>
> Many thanks,
> Johnny
> -----Original Message-----
> From: 廖崇榮 [mailto:kt.liao@emc.com.tw]
> Sent: Tuesday, March 21, 2017 1:55 PM
> To: 'Dmitry Torokhov'; 'M K'
> Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
> Subject: RE: ELAN0732 I2C Touchscreen Driver
>
> Add Johnny who handle ELAN touchscreen in loop.
>
> -----Original Message-----
> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
> Sent: Tuesday, March 21, 2017 12:45 PM
> To: M K; 廖崇榮
> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
> Subject: Re: ELAN0732 I2C Touchscreen Driver
>
> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>> Is there a compatible driver for this device?  I've tried loading
>> various modules with no success (elants_i2c, hid_multitouch, etc.).
>>
>> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>
> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>
>>
>> However, xinput does not list it at all.
>>
>> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display,
>> and AMD FX-9800P processor.
>>
>> Scott Liu suggested I try posting here.
>
> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
> Hi Johnny,
>         Could you help to check this TS issue
> Thanks.
>
> --
> Dmitry
>

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-03-28  8:13       ` M K
@ 2017-03-28  8:15         ` M K
  2017-03-29  8:02           ` Johnny.Chuang
  0 siblings, 1 reply; 13+ messages in thread
From: M K @ 2017-03-28  8:15 UTC (permalink / raw)
  To: Johnny.Chuang
  Cc: 廖崇榮,
	Dmitry Torokhov, linux-input, ELAN 劉嘉駿

[-- Attachment #1: Type: text/plain, Size: 5075 bytes --]

And here's a screenshot of the device info in Windows:

On Tue, Mar 28, 2017 at 3:13 AM, M K <m.kolesinski@gmail.com> wrote:
> Hi Johnny,
>
> Did you mean to add the {.driver_data...} to a static in i2c-hid.c, or
> in hid-multitouch.c?  If so, where?  After downloading the kernel
> source and building these modules, it looks to me like
> hid-multitouch.c is its own module (part of the Makefile for
> "M=drivers/hid") separate from i2c-hid ("M=drivers/hid/i2c-hid")
>
> Also, the comments in hid-multitouch.c state that definitions for
> items using MT_CLS_DEFAULT don't do anything.  Finally, what device
> type should I use?  The code you provided won't compile, because the
> HID_DEVICE() macro expects another argument.  I presume this would be
> "HID_GROUP_MULTITOUCH" ?
>
> After trying the above, I recompiled the two modules and re-installed
> them in my kernel using modprobe.  However, I could find no evidence
> that the ELAN0732 device was actually detected as an input device (cat
> /proc/bus/input/devices, and xinput both don't show anything new).  I
> also tried rebooting (however, neither of these modules is in the
> standard initramfs for Arch Linux, so I don't think rebooting is
> necessary).
>
> Any other ideas?
>
> Also, here's a snippet of the DxDiag report from Windows..for this
> vendor ID, it lists 4 devices (0x2B28)...not sure if this is the same
> piece of hardware or not:
> "-------------------
> DirectInput Devices
> -------------------
>       Device Name: Mouse
>          Attached: 1
>     Controller ID: n/a
> Vendor/Product ID: n/a
>         FF Driver: n/a
>
>       Device Name: Keyboard
>          Attached: 1
>     Controller ID: n/a
> Vendor/Product ID: n/a
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HP Wireless Button Driver
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x0001, 0x0001
>         FF Driver: n/a
>
>       Device Name: ST_SENSOR_HUB
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x0483, 0x91D1
>         FF Driver: n/a
>
> Poll w/ Interrupt: No
>
> -----------"
>
>
>
>
> Thanks,
>
> MK
>
>
> On Mon, Mar 27, 2017 at 10:06 PM, Johnny.Chuang
> <johnny.chuang@emc.com.tw> wrote:
>> Hi Dmitry,
>>
>> Sorry for late response.
>>
>> ELAN0732 is hid over i2c touch screen device.
>> There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
>> Please make i2c-hid.c as build-in driver or module.
>>
>> And please also add VID/PID at hid-ids.h and hid-multitouch.c
>> drivers/hid/hid-ids.h
>>         #define USB_VENDOR_ID_ELAN      0x04f3
>>         #define USB_DEVICE_ID_ELAN_A    0x0732
>>         #define USB_DEVICE_ID_ELAN_B    0x000b
>> drivers/hid/hid-multitouch.c
>>         /* Elan i2c-hid TouchSystems panel */
>>         { .driver_data = MT_CLS_DEFAULT,
>>                 HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
>>                         USB_DEVICE_ID_ELAN_A) },
>>
>> Many thanks,
>> Johnny
>> -----Original Message-----
>> From: 廖崇榮 [mailto:kt.liao@emc.com.tw]
>> Sent: Tuesday, March 21, 2017 1:55 PM
>> To: 'Dmitry Torokhov'; 'M K'
>> Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
>> Subject: RE: ELAN0732 I2C Touchscreen Driver
>>
>> Add Johnny who handle ELAN touchscreen in loop.
>>
>> -----Original Message-----
>> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
>> Sent: Tuesday, March 21, 2017 12:45 PM
>> To: M K; 廖崇榮
>> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>
>> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>>> Is there a compatible driver for this device?  I've tried loading
>>> various modules with no success (elants_i2c, hid_multitouch, etc.).
>>>
>>> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>>
>> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>>
>>>
>>> However, xinput does not list it at all.
>>>
>>> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen display,
>>> and AMD FX-9800P processor.
>>>
>>> Scott Liu suggested I try posting here.
>>
>> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
>> Hi Johnny,
>>         Could you help to check this TS issue
>> Thanks.
>>
>> --
>> Dmitry
>>

[-- Attachment #2: elan_0732_info.png --]
[-- Type: image/png, Size: 11330 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* RE: ELAN0732 I2C Touchscreen Driver
  2017-03-28  8:15         ` M K
@ 2017-03-29  8:02           ` Johnny.Chuang
  2017-04-01  8:30             ` M K
  0 siblings, 1 reply; 13+ messages in thread
From: Johnny.Chuang @ 2017-03-29  8:02 UTC (permalink / raw)
  To: 'M K'
  Cc: '廖崇榮', 'Dmitry Torokhov',
	linux-input, 'ELAN 劉嘉駿'

Hi MK,

1. Please add the {.driver_data...} to a static in hid-multitouch.c
	static const struct hid_device_id mt_devices[] = {
		/* Elan i2c-hid TouchSystems panel */
		{ .driver_data = MT_CLS_DEFAULT,
			HID_DEVICE(BUS_I2C, HID_GROUP_MULTITOUCH, USB_VENDOR_ID_ELAN,
				USB_DEVICE_ID_ELAN_A) },
Please add in drivers/hid/hid-ids.h
	#define USB_VENDOR_ID_ELAN             0x04f3
	#define USB_DEVICE_ID_ELAN_A           0x0732

2. There are two separate modules (hid-multitouch.c and i2c-hid.c) you need to use. 

3. using MT_CLS_DEFAULT : Yes

4. HID_DEVICE() : My fault, miss an argument " HID_GROUP_MULTITOUCH " as above.

5. PID: 0x2B28 : As I know our I2CHID touch screen PID is 0x0732. I'm not sure what 0x2B28 is.

Please try it again, thanks.

Many thanks,
Johnny
-----Original Message-----
From: M K [mailto:m.kolesinski@gmail.com] 
Sent: Tuesday, March 28, 2017 4:16 PM
To: Johnny.Chuang
Cc: 廖崇榮; Dmitry Torokhov; linux-input@vger.kernel.org; ELAN 劉嘉駿
Subject: Re: ELAN0732 I2C Touchscreen Driver

And here's a screenshot of the device info in Windows:

On Tue, Mar 28, 2017 at 3:13 AM, M K <m.kolesinski@gmail.com> wrote:
> Hi Johnny,
>
> Did you mean to add the {.driver_data...} to a static in i2c-hid.c, or 
> in hid-multitouch.c?  If so, where?  After downloading the kernel 
> source and building these modules, it looks to me like 
> hid-multitouch.c is its own module (part of the Makefile for
> "M=drivers/hid") separate from i2c-hid ("M=drivers/hid/i2c-hid")
>
> Also, the comments in hid-multitouch.c state that definitions for 
> items using MT_CLS_DEFAULT don't do anything.  Finally, what device 
> type should I use?  The code you provided won't compile, because the
> HID_DEVICE() macro expects another argument.  I presume this would be 
> "HID_GROUP_MULTITOUCH" ?
>
> After trying the above, I recompiled the two modules and re-installed 
> them in my kernel using modprobe.  However, I could find no evidence 
> that the ELAN0732 device was actually detected as an input device (cat 
> /proc/bus/input/devices, and xinput both don't show anything new).  I 
> also tried rebooting (however, neither of these modules is in the 
> standard initramfs for Arch Linux, so I don't think rebooting is 
> necessary).
>
> Any other ideas?
>
> Also, here's a snippet of the DxDiag report from Windows..for this 
> vendor ID, it lists 4 devices (0x2B28)...not sure if this is the same 
> piece of hardware or not:
> "-------------------
> DirectInput Devices
> -------------------
>       Device Name: Mouse
>          Attached: 1
>     Controller ID: n/a
> Vendor/Product ID: n/a
>         FF Driver: n/a
>
>       Device Name: Keyboard
>          Attached: 1
>     Controller ID: n/a
> Vendor/Product ID: n/a
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HIDI2C Device
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x04F3, 0x2B28
>         FF Driver: n/a
>
>       Device Name: HP Wireless Button Driver
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x0001, 0x0001
>         FF Driver: n/a
>
>       Device Name: ST_SENSOR_HUB
>          Attached: 1
>     Controller ID: 0x0
> Vendor/Product ID: 0x0483, 0x91D1
>         FF Driver: n/a
>
> Poll w/ Interrupt: No
>
> -----------"
>
>
>
>
> Thanks,
>
> MK
>
>
> On Mon, Mar 27, 2017 at 10:06 PM, Johnny.Chuang 
> <johnny.chuang@emc.com.tw> wrote:
>> Hi Dmitry,
>>
>> Sorry for late response.
>>
>> ELAN0732 is hid over i2c touch screen device.
>> There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
>> Please make i2c-hid.c as build-in driver or module.
>>
>> And please also add VID/PID at hid-ids.h and hid-multitouch.c 
>> drivers/hid/hid-ids.h
>>         #define USB_VENDOR_ID_ELAN      0x04f3
>>         #define USB_DEVICE_ID_ELAN_A    0x0732
>>         #define USB_DEVICE_ID_ELAN_B    0x000b
>> drivers/hid/hid-multitouch.c
>>         /* Elan i2c-hid TouchSystems panel */
>>         { .driver_data = MT_CLS_DEFAULT,
>>                 HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
>>                         USB_DEVICE_ID_ELAN_A) },
>>
>> Many thanks,
>> Johnny
>> -----Original Message-----
>> From: 廖崇榮 [mailto:kt.liao@emc.com.tw]
>> Sent: Tuesday, March 21, 2017 1:55 PM
>> To: 'Dmitry Torokhov'; 'M K'
>> Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
>> Subject: RE: ELAN0732 I2C Touchscreen Driver
>>
>> Add Johnny who handle ELAN touchscreen in loop.
>>
>> -----Original Message-----
>> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
>> Sent: Tuesday, March 21, 2017 12:45 PM
>> To: M K; 廖崇榮
>> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>
>> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>>> Is there a compatible driver for this device?  I've tried loading 
>>> various modules with no success (elants_i2c, hid_multitouch, etc.).
>>>
>>> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>>
>> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>>
>>>
>>> However, xinput does not list it at all.
>>>
>>> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen 
>>> display, and AMD FX-9800P processor.
>>>
>>> Scott Liu suggested I try posting here.
>>
>> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
>> Hi Johnny,
>>         Could you help to check this TS issue Thanks.
>>
>> --
>> Dmitry
>>


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-03-29  8:02           ` Johnny.Chuang
@ 2017-04-01  8:30             ` M K
  2017-04-02 10:46               ` M K
  0 siblings, 1 reply; 13+ messages in thread
From: M K @ 2017-04-01  8:30 UTC (permalink / raw)
  To: Johnny.Chuang
  Cc: 廖崇榮,
	Dmitry Torokhov, linux-input, ELAN 劉嘉駿

Hi Johnny,

That is already what I tried.  I am able to get the kernel module
"drivers/hid" to build (make M=drivers/hid modules), and I then
gzipped the hid-multitouch.ko file, and copied it to
/usr/lib/modules/'uname -r'/kernel/drivers/hid/.

The thing is, I tried putting printk() calls in, and nothing shows up
in dmesg or in journalctl.  I tried removing the existing modules
(modprobe -r hid-multitouch) and re-probing with the updated module
(modprobe -v hid-multitouch), and the file on the path it points to
matches my compiled version.

But, the touchscreen still doesn't work, nothing shows up in "xinput",
and I don't see printk() messages.  Am I rebuilding/installing these
modules incorrectly?


Thanks,

On Wed, Mar 29, 2017 at 3:02 AM, Johnny.Chuang <johnny.chuang@emc.com.tw> wrote:
> Hi MK,
>
> 1. Please add the {.driver_data...} to a static in hid-multitouch.c
>         static const struct hid_device_id mt_devices[] = {
>                 /* Elan i2c-hid TouchSystems panel */
>                 { .driver_data = MT_CLS_DEFAULT,
>                         HID_DEVICE(BUS_I2C, HID_GROUP_MULTITOUCH, USB_VENDOR_ID_ELAN,
>                                 USB_DEVICE_ID_ELAN_A) },
> Please add in drivers/hid/hid-ids.h
>         #define USB_VENDOR_ID_ELAN             0x04f3
>         #define USB_DEVICE_ID_ELAN_A           0x0732
>
> 2. There are two separate modules (hid-multitouch.c and i2c-hid.c) you need to use.
>
> 3. using MT_CLS_DEFAULT : Yes
>
> 4. HID_DEVICE() : My fault, miss an argument " HID_GROUP_MULTITOUCH " as above.
>
> 5. PID: 0x2B28 : As I know our I2CHID touch screen PID is 0x0732. I'm not sure what 0x2B28 is.
>
> Please try it again, thanks.
>
> Many thanks,
> Johnny
> -----Original Message-----
> From: M K [mailto:m.kolesinski@gmail.com]
> Sent: Tuesday, March 28, 2017 4:16 PM
> To: Johnny.Chuang
> Cc: 廖崇榮; Dmitry Torokhov; linux-input@vger.kernel.org; ELAN 劉嘉駿
> Subject: Re: ELAN0732 I2C Touchscreen Driver
>
> And here's a screenshot of the device info in Windows:
>
> On Tue, Mar 28, 2017 at 3:13 AM, M K <m.kolesinski@gmail.com> wrote:
>> Hi Johnny,
>>
>> Did you mean to add the {.driver_data...} to a static in i2c-hid.c, or
>> in hid-multitouch.c?  If so, where?  After downloading the kernel
>> source and building these modules, it looks to me like
>> hid-multitouch.c is its own module (part of the Makefile for
>> "M=drivers/hid") separate from i2c-hid ("M=drivers/hid/i2c-hid")
>>
>> Also, the comments in hid-multitouch.c state that definitions for
>> items using MT_CLS_DEFAULT don't do anything.  Finally, what device
>> type should I use?  The code you provided won't compile, because the
>> HID_DEVICE() macro expects another argument.  I presume this would be
>> "HID_GROUP_MULTITOUCH" ?
>>
>> After trying the above, I recompiled the two modules and re-installed
>> them in my kernel using modprobe.  However, I could find no evidence
>> that the ELAN0732 device was actually detected as an input device (cat
>> /proc/bus/input/devices, and xinput both don't show anything new).  I
>> also tried rebooting (however, neither of these modules is in the
>> standard initramfs for Arch Linux, so I don't think rebooting is
>> necessary).
>>
>> Any other ideas?
>>
>> Also, here's a snippet of the DxDiag report from Windows..for this
>> vendor ID, it lists 4 devices (0x2B28)...not sure if this is the same
>> piece of hardware or not:
>> "-------------------
>> DirectInput Devices
>> -------------------
>>       Device Name: Mouse
>>          Attached: 1
>>     Controller ID: n/a
>> Vendor/Product ID: n/a
>>         FF Driver: n/a
>>
>>       Device Name: Keyboard
>>          Attached: 1
>>     Controller ID: n/a
>> Vendor/Product ID: n/a
>>         FF Driver: n/a
>>
>>       Device Name: HIDI2C Device
>>          Attached: 1
>>     Controller ID: 0x0
>> Vendor/Product ID: 0x04F3, 0x2B28
>>         FF Driver: n/a
>>
>>       Device Name: HIDI2C Device
>>          Attached: 1
>>     Controller ID: 0x0
>> Vendor/Product ID: 0x04F3, 0x2B28
>>         FF Driver: n/a
>>
>>       Device Name: HIDI2C Device
>>          Attached: 1
>>     Controller ID: 0x0
>> Vendor/Product ID: 0x04F3, 0x2B28
>>         FF Driver: n/a
>>
>>       Device Name: HIDI2C Device
>>          Attached: 1
>>     Controller ID: 0x0
>> Vendor/Product ID: 0x04F3, 0x2B28
>>         FF Driver: n/a
>>
>>       Device Name: HP Wireless Button Driver
>>          Attached: 1
>>     Controller ID: 0x0
>> Vendor/Product ID: 0x0001, 0x0001
>>         FF Driver: n/a
>>
>>       Device Name: ST_SENSOR_HUB
>>          Attached: 1
>>     Controller ID: 0x0
>> Vendor/Product ID: 0x0483, 0x91D1
>>         FF Driver: n/a
>>
>> Poll w/ Interrupt: No
>>
>> -----------"
>>
>>
>>
>>
>> Thanks,
>>
>> MK
>>
>>
>> On Mon, Mar 27, 2017 at 10:06 PM, Johnny.Chuang
>> <johnny.chuang@emc.com.tw> wrote:
>>> Hi Dmitry,
>>>
>>> Sorry for late response.
>>>
>>> ELAN0732 is hid over i2c touch screen device.
>>> There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
>>> Please make i2c-hid.c as build-in driver or module.
>>>
>>> And please also add VID/PID at hid-ids.h and hid-multitouch.c
>>> drivers/hid/hid-ids.h
>>>         #define USB_VENDOR_ID_ELAN      0x04f3
>>>         #define USB_DEVICE_ID_ELAN_A    0x0732
>>>         #define USB_DEVICE_ID_ELAN_B    0x000b
>>> drivers/hid/hid-multitouch.c
>>>         /* Elan i2c-hid TouchSystems panel */
>>>         { .driver_data = MT_CLS_DEFAULT,
>>>                 HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
>>>                         USB_DEVICE_ID_ELAN_A) },
>>>
>>> Many thanks,
>>> Johnny
>>> -----Original Message-----
>>> From: 廖崇榮 [mailto:kt.liao@emc.com.tw]
>>> Sent: Tuesday, March 21, 2017 1:55 PM
>>> To: 'Dmitry Torokhov'; 'M K'
>>> Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
>>> Subject: RE: ELAN0732 I2C Touchscreen Driver
>>>
>>> Add Johnny who handle ELAN touchscreen in loop.
>>>
>>> -----Original Message-----
>>> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
>>> Sent: Tuesday, March 21, 2017 12:45 PM
>>> To: M K; 廖崇榮
>>> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
>>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>>
>>> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>>>> Is there a compatible driver for this device?  I've tried loading
>>>> various modules with no success (elants_i2c, hid_multitouch, etc.).
>>>>
>>>> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>>>
>>> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>>>
>>>>
>>>> However, xinput does not list it at all.
>>>>
>>>> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen
>>>> display, and AMD FX-9800P processor.
>>>>
>>>> Scott Liu suggested I try posting here.
>>>
>>> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
>>> Hi Johnny,
>>>         Could you help to check this TS issue Thanks.
>>>
>>> --
>>> Dmitry
>>>
>

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-04-01  8:30             ` M K
@ 2017-04-02 10:46               ` M K
  2017-04-05  5:43                 ` M K
  0 siblings, 1 reply; 13+ messages in thread
From: M K @ 2017-04-02 10:46 UTC (permalink / raw)
  To: Johnny.Chuang
  Cc: 廖崇榮,
	Dmitry Torokhov, linux-input, ELAN 劉嘉駿

I think the issue is the module hid-multitouch isn't generating an
alias for the dev/vendor ID.  After recompiling, when I run depmod it
doesn't create a unique entry for the Elan device.  I see a generic
entry in modules.alias:
"alias acpi*:PNP0C50:* i2c_hid

Shouldn't I see an entry for hid_multitouch, with the ELAN
vendor/device ID in it?


Thanks,

MK

On Sat, Apr 1, 2017 at 3:30 AM, M K <m.kolesinski@gmail.com> wrote:
> Hi Johnny,
>
> That is already what I tried.  I am able to get the kernel module
> "drivers/hid" to build (make M=drivers/hid modules), and I then
> gzipped the hid-multitouch.ko file, and copied it to
> /usr/lib/modules/'uname -r'/kernel/drivers/hid/.
>
> The thing is, I tried putting printk() calls in, and nothing shows up
> in dmesg or in journalctl.  I tried removing the existing modules
> (modprobe -r hid-multitouch) and re-probing with the updated module
> (modprobe -v hid-multitouch), and the file on the path it points to
> matches my compiled version.
>
> But, the touchscreen still doesn't work, nothing shows up in "xinput",
> and I don't see printk() messages.  Am I rebuilding/installing these
> modules incorrectly?
>
>
> Thanks,
>
> On Wed, Mar 29, 2017 at 3:02 AM, Johnny.Chuang <johnny.chuang@emc.com.tw> wrote:
>> Hi MK,
>>
>> 1. Please add the {.driver_data...} to a static in hid-multitouch.c
>>         static const struct hid_device_id mt_devices[] = {
>>                 /* Elan i2c-hid TouchSystems panel */
>>                 { .driver_data = MT_CLS_DEFAULT,
>>                         HID_DEVICE(BUS_I2C, HID_GROUP_MULTITOUCH, USB_VENDOR_ID_ELAN,
>>                                 USB_DEVICE_ID_ELAN_A) },
>> Please add in drivers/hid/hid-ids.h
>>         #define USB_VENDOR_ID_ELAN             0x04f3
>>         #define USB_DEVICE_ID_ELAN_A           0x0732
>>
>> 2. There are two separate modules (hid-multitouch.c and i2c-hid.c) you need to use.
>>
>> 3. using MT_CLS_DEFAULT : Yes
>>
>> 4. HID_DEVICE() : My fault, miss an argument " HID_GROUP_MULTITOUCH " as above.
>>
>> 5. PID: 0x2B28 : As I know our I2CHID touch screen PID is 0x0732. I'm not sure what 0x2B28 is.
>>
>> Please try it again, thanks.
>>
>> Many thanks,
>> Johnny
>> -----Original Message-----
>> From: M K [mailto:m.kolesinski@gmail.com]
>> Sent: Tuesday, March 28, 2017 4:16 PM
>> To: Johnny.Chuang
>> Cc: 廖崇榮; Dmitry Torokhov; linux-input@vger.kernel.org; ELAN 劉嘉駿
>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>
>> And here's a screenshot of the device info in Windows:
>>
>> On Tue, Mar 28, 2017 at 3:13 AM, M K <m.kolesinski@gmail.com> wrote:
>>> Hi Johnny,
>>>
>>> Did you mean to add the {.driver_data...} to a static in i2c-hid.c, or
>>> in hid-multitouch.c?  If so, where?  After downloading the kernel
>>> source and building these modules, it looks to me like
>>> hid-multitouch.c is its own module (part of the Makefile for
>>> "M=drivers/hid") separate from i2c-hid ("M=drivers/hid/i2c-hid")
>>>
>>> Also, the comments in hid-multitouch.c state that definitions for
>>> items using MT_CLS_DEFAULT don't do anything.  Finally, what device
>>> type should I use?  The code you provided won't compile, because the
>>> HID_DEVICE() macro expects another argument.  I presume this would be
>>> "HID_GROUP_MULTITOUCH" ?
>>>
>>> After trying the above, I recompiled the two modules and re-installed
>>> them in my kernel using modprobe.  However, I could find no evidence
>>> that the ELAN0732 device was actually detected as an input device (cat
>>> /proc/bus/input/devices, and xinput both don't show anything new).  I
>>> also tried rebooting (however, neither of these modules is in the
>>> standard initramfs for Arch Linux, so I don't think rebooting is
>>> necessary).
>>>
>>> Any other ideas?
>>>
>>> Also, here's a snippet of the DxDiag report from Windows..for this
>>> vendor ID, it lists 4 devices (0x2B28)...not sure if this is the same
>>> piece of hardware or not:
>>> "-------------------
>>> DirectInput Devices
>>> -------------------
>>>       Device Name: Mouse
>>>          Attached: 1
>>>     Controller ID: n/a
>>> Vendor/Product ID: n/a
>>>         FF Driver: n/a
>>>
>>>       Device Name: Keyboard
>>>          Attached: 1
>>>     Controller ID: n/a
>>> Vendor/Product ID: n/a
>>>         FF Driver: n/a
>>>
>>>       Device Name: HIDI2C Device
>>>          Attached: 1
>>>     Controller ID: 0x0
>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>         FF Driver: n/a
>>>
>>>       Device Name: HIDI2C Device
>>>          Attached: 1
>>>     Controller ID: 0x0
>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>         FF Driver: n/a
>>>
>>>       Device Name: HIDI2C Device
>>>          Attached: 1
>>>     Controller ID: 0x0
>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>         FF Driver: n/a
>>>
>>>       Device Name: HIDI2C Device
>>>          Attached: 1
>>>     Controller ID: 0x0
>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>         FF Driver: n/a
>>>
>>>       Device Name: HP Wireless Button Driver
>>>          Attached: 1
>>>     Controller ID: 0x0
>>> Vendor/Product ID: 0x0001, 0x0001
>>>         FF Driver: n/a
>>>
>>>       Device Name: ST_SENSOR_HUB
>>>          Attached: 1
>>>     Controller ID: 0x0
>>> Vendor/Product ID: 0x0483, 0x91D1
>>>         FF Driver: n/a
>>>
>>> Poll w/ Interrupt: No
>>>
>>> -----------"
>>>
>>>
>>>
>>>
>>> Thanks,
>>>
>>> MK
>>>
>>>
>>> On Mon, Mar 27, 2017 at 10:06 PM, Johnny.Chuang
>>> <johnny.chuang@emc.com.tw> wrote:
>>>> Hi Dmitry,
>>>>
>>>> Sorry for late response.
>>>>
>>>> ELAN0732 is hid over i2c touch screen device.
>>>> There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
>>>> Please make i2c-hid.c as build-in driver or module.
>>>>
>>>> And please also add VID/PID at hid-ids.h and hid-multitouch.c
>>>> drivers/hid/hid-ids.h
>>>>         #define USB_VENDOR_ID_ELAN      0x04f3
>>>>         #define USB_DEVICE_ID_ELAN_A    0x0732
>>>>         #define USB_DEVICE_ID_ELAN_B    0x000b
>>>> drivers/hid/hid-multitouch.c
>>>>         /* Elan i2c-hid TouchSystems panel */
>>>>         { .driver_data = MT_CLS_DEFAULT,
>>>>                 HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
>>>>                         USB_DEVICE_ID_ELAN_A) },
>>>>
>>>> Many thanks,
>>>> Johnny
>>>> -----Original Message-----
>>>> From: 廖崇榮 [mailto:kt.liao@emc.com.tw]
>>>> Sent: Tuesday, March 21, 2017 1:55 PM
>>>> To: 'Dmitry Torokhov'; 'M K'
>>>> Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
>>>> Subject: RE: ELAN0732 I2C Touchscreen Driver
>>>>
>>>> Add Johnny who handle ELAN touchscreen in loop.
>>>>
>>>> -----Original Message-----
>>>> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
>>>> Sent: Tuesday, March 21, 2017 12:45 PM
>>>> To: M K; 廖崇榮
>>>> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
>>>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>>>
>>>> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>>>>> Is there a compatible driver for this device?  I've tried loading
>>>>> various modules with no success (elants_i2c, hid_multitouch, etc.).
>>>>>
>>>>> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>>>>
>>>> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>>>>
>>>>>
>>>>> However, xinput does not list it at all.
>>>>>
>>>>> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen
>>>>> display, and AMD FX-9800P processor.
>>>>>
>>>>> Scott Liu suggested I try posting here.
>>>>
>>>> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
>>>> Hi Johnny,
>>>>         Could you help to check this TS issue Thanks.
>>>>
>>>> --
>>>> Dmitry
>>>>
>>

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: ELAN0732 I2C Touchscreen Driver
  2017-04-02 10:46               ` M K
@ 2017-04-05  5:43                 ` M K
  0 siblings, 0 replies; 13+ messages in thread
From: M K @ 2017-04-05  5:43 UTC (permalink / raw)
  To: Johnny.Chuang
  Cc: 廖崇榮,
	Dmitry Torokhov, linux-input, ELAN 劉嘉駿

[-- Attachment #1: Type: text/plain, Size: 8443 bytes --]

I tried aliasing the device, still no luck.

I figured out what you meant by DSDT.  I extracted mine (attached),
but it would not decompile, iasl core dumps with an error.  Maybe
you'll have better luck with it.



On Sun, Apr 2, 2017 at 5:46 AM, M K <m.kolesinski@gmail.com> wrote:
> I think the issue is the module hid-multitouch isn't generating an
> alias for the dev/vendor ID.  After recompiling, when I run depmod it
> doesn't create a unique entry for the Elan device.  I see a generic
> entry in modules.alias:
> "alias acpi*:PNP0C50:* i2c_hid
>
> Shouldn't I see an entry for hid_multitouch, with the ELAN
> vendor/device ID in it?
>
>
> Thanks,
>
> MK
>
> On Sat, Apr 1, 2017 at 3:30 AM, M K <m.kolesinski@gmail.com> wrote:
>> Hi Johnny,
>>
>> That is already what I tried.  I am able to get the kernel module
>> "drivers/hid" to build (make M=drivers/hid modules), and I then
>> gzipped the hid-multitouch.ko file, and copied it to
>> /usr/lib/modules/'uname -r'/kernel/drivers/hid/.
>>
>> The thing is, I tried putting printk() calls in, and nothing shows up
>> in dmesg or in journalctl.  I tried removing the existing modules
>> (modprobe -r hid-multitouch) and re-probing with the updated module
>> (modprobe -v hid-multitouch), and the file on the path it points to
>> matches my compiled version.
>>
>> But, the touchscreen still doesn't work, nothing shows up in "xinput",
>> and I don't see printk() messages.  Am I rebuilding/installing these
>> modules incorrectly?
>>
>>
>> Thanks,
>>
>> On Wed, Mar 29, 2017 at 3:02 AM, Johnny.Chuang <johnny.chuang@emc.com.tw> wrote:
>>> Hi MK,
>>>
>>> 1. Please add the {.driver_data...} to a static in hid-multitouch.c
>>>         static const struct hid_device_id mt_devices[] = {
>>>                 /* Elan i2c-hid TouchSystems panel */
>>>                 { .driver_data = MT_CLS_DEFAULT,
>>>                         HID_DEVICE(BUS_I2C, HID_GROUP_MULTITOUCH, USB_VENDOR_ID_ELAN,
>>>                                 USB_DEVICE_ID_ELAN_A) },
>>> Please add in drivers/hid/hid-ids.h
>>>         #define USB_VENDOR_ID_ELAN             0x04f3
>>>         #define USB_DEVICE_ID_ELAN_A           0x0732
>>>
>>> 2. There are two separate modules (hid-multitouch.c and i2c-hid.c) you need to use.
>>>
>>> 3. using MT_CLS_DEFAULT : Yes
>>>
>>> 4. HID_DEVICE() : My fault, miss an argument " HID_GROUP_MULTITOUCH " as above.
>>>
>>> 5. PID: 0x2B28 : As I know our I2CHID touch screen PID is 0x0732. I'm not sure what 0x2B28 is.
>>>
>>> Please try it again, thanks.
>>>
>>> Many thanks,
>>> Johnny
>>> -----Original Message-----
>>> From: M K [mailto:m.kolesinski@gmail.com]
>>> Sent: Tuesday, March 28, 2017 4:16 PM
>>> To: Johnny.Chuang
>>> Cc: 廖崇榮; Dmitry Torokhov; linux-input@vger.kernel.org; ELAN 劉嘉駿
>>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>>
>>> And here's a screenshot of the device info in Windows:
>>>
>>> On Tue, Mar 28, 2017 at 3:13 AM, M K <m.kolesinski@gmail.com> wrote:
>>>> Hi Johnny,
>>>>
>>>> Did you mean to add the {.driver_data...} to a static in i2c-hid.c, or
>>>> in hid-multitouch.c?  If so, where?  After downloading the kernel
>>>> source and building these modules, it looks to me like
>>>> hid-multitouch.c is its own module (part of the Makefile for
>>>> "M=drivers/hid") separate from i2c-hid ("M=drivers/hid/i2c-hid")
>>>>
>>>> Also, the comments in hid-multitouch.c state that definitions for
>>>> items using MT_CLS_DEFAULT don't do anything.  Finally, what device
>>>> type should I use?  The code you provided won't compile, because the
>>>> HID_DEVICE() macro expects another argument.  I presume this would be
>>>> "HID_GROUP_MULTITOUCH" ?
>>>>
>>>> After trying the above, I recompiled the two modules and re-installed
>>>> them in my kernel using modprobe.  However, I could find no evidence
>>>> that the ELAN0732 device was actually detected as an input device (cat
>>>> /proc/bus/input/devices, and xinput both don't show anything new).  I
>>>> also tried rebooting (however, neither of these modules is in the
>>>> standard initramfs for Arch Linux, so I don't think rebooting is
>>>> necessary).
>>>>
>>>> Any other ideas?
>>>>
>>>> Also, here's a snippet of the DxDiag report from Windows..for this
>>>> vendor ID, it lists 4 devices (0x2B28)...not sure if this is the same
>>>> piece of hardware or not:
>>>> "-------------------
>>>> DirectInput Devices
>>>> -------------------
>>>>       Device Name: Mouse
>>>>          Attached: 1
>>>>     Controller ID: n/a
>>>> Vendor/Product ID: n/a
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: Keyboard
>>>>          Attached: 1
>>>>     Controller ID: n/a
>>>> Vendor/Product ID: n/a
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: HIDI2C Device
>>>>          Attached: 1
>>>>     Controller ID: 0x0
>>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: HIDI2C Device
>>>>          Attached: 1
>>>>     Controller ID: 0x0
>>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: HIDI2C Device
>>>>          Attached: 1
>>>>     Controller ID: 0x0
>>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: HIDI2C Device
>>>>          Attached: 1
>>>>     Controller ID: 0x0
>>>> Vendor/Product ID: 0x04F3, 0x2B28
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: HP Wireless Button Driver
>>>>          Attached: 1
>>>>     Controller ID: 0x0
>>>> Vendor/Product ID: 0x0001, 0x0001
>>>>         FF Driver: n/a
>>>>
>>>>       Device Name: ST_SENSOR_HUB
>>>>          Attached: 1
>>>>     Controller ID: 0x0
>>>> Vendor/Product ID: 0x0483, 0x91D1
>>>>         FF Driver: n/a
>>>>
>>>> Poll w/ Interrupt: No
>>>>
>>>> -----------"
>>>>
>>>>
>>>>
>>>>
>>>> Thanks,
>>>>
>>>> MK
>>>>
>>>>
>>>> On Mon, Mar 27, 2017 at 10:06 PM, Johnny.Chuang
>>>> <johnny.chuang@emc.com.tw> wrote:
>>>>> Hi Dmitry,
>>>>>
>>>>> Sorry for late response.
>>>>>
>>>>> ELAN0732 is hid over i2c touch screen device.
>>>>> There is a compatible linux inbox driver which is drivers/hid/i2c-hid/i2c-hid.c.
>>>>> Please make i2c-hid.c as build-in driver or module.
>>>>>
>>>>> And please also add VID/PID at hid-ids.h and hid-multitouch.c
>>>>> drivers/hid/hid-ids.h
>>>>>         #define USB_VENDOR_ID_ELAN      0x04f3
>>>>>         #define USB_DEVICE_ID_ELAN_A    0x0732
>>>>>         #define USB_DEVICE_ID_ELAN_B    0x000b
>>>>> drivers/hid/hid-multitouch.c
>>>>>         /* Elan i2c-hid TouchSystems panel */
>>>>>         { .driver_data = MT_CLS_DEFAULT,
>>>>>                 HID_DEVICE(BUS_I2C, USB_VENDOR_ID_ELAN,
>>>>>                         USB_DEVICE_ID_ELAN_A) },
>>>>>
>>>>> Many thanks,
>>>>> Johnny
>>>>> -----Original Message-----
>>>>> From: 廖崇榮 [mailto:kt.liao@emc.com.tw]
>>>>> Sent: Tuesday, March 21, 2017 1:55 PM
>>>>> To: 'Dmitry Torokhov'; 'M K'
>>>>> Cc: linux-input@vger.kernel.org; 'ELAN 劉嘉駿'; 'Johnny.Chuang'
>>>>> Subject: RE: ELAN0732 I2C Touchscreen Driver
>>>>>
>>>>> Add Johnny who handle ELAN touchscreen in loop.
>>>>>
>>>>> -----Original Message-----
>>>>> From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
>>>>> Sent: Tuesday, March 21, 2017 12:45 PM
>>>>> To: M K; 廖崇榮
>>>>> Cc: linux-input@vger.kernel.org; ELAN 劉嘉駿
>>>>> Subject: Re: ELAN0732 I2C Touchscreen Driver
>>>>>
>>>>> On Sun, Mar 19, 2017 at 11:26 PM, M K <m.kolesinski@gmail.com> wrote:
>>>>>> Is there a compatible driver for this device?  I've tried loading
>>>>>> various modules with no success (elants_i2c, hid_multitouch, etc.).
>>>>>>
>>>>>> The device shows up under /sys/bus/i2c/devices/i2c-ELAN0732:00
>>>>>
>>>>> You would need to add "ELAN0732" to elants_i2c_id table for elants_i2c to load and bind to the device.
>>>>>
>>>>>>
>>>>>> However, xinput does not list it at all.
>>>>>>
>>>>>> This is an HP m6-ar004dx laptop (Envy x360) with touchscreen
>>>>>> display, and AMD FX-9800P processor.
>>>>>>
>>>>>> Scott Liu suggested I try posting here.
>>>>>
>>>>> Hmm, I'd expect Scott to know if elants_i2c could theoretically drive this device. KT, do you know by chance?
>>>>> Hi Johnny,
>>>>>         Could you help to check this TS issue Thanks.
>>>>>
>>>>> --
>>>>> Dmitry
>>>>>
>>>

[-- Attachment #2: dsdt.dat --]
[-- Type: application/x-ns-proxy-autoconfig, Size: 55305 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2017-04-05  5:43 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-20  6:26 ELAN0732 I2C Touchscreen Driver M K
2017-03-21  4:45 ` Dmitry Torokhov
2017-03-21  5:48   ` 劉嘉駿
2017-03-21 17:01     ` 'Dmitry Torokhov'
2017-03-22  3:30       ` M K
2017-03-21  5:55   ` 廖崇榮
2017-03-28  3:06     ` Johnny.Chuang
2017-03-28  8:13       ` M K
2017-03-28  8:15         ` M K
2017-03-29  8:02           ` Johnny.Chuang
2017-04-01  8:30             ` M K
2017-04-02 10:46               ` M K
2017-04-05  5:43                 ` M K

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.