2011-03-31 17:22:21

by Manoj Iyer

[permalink] [raw]
Subject: [PATCH] add support for Lenovo tablet ID (0xE6)

Please consider this patch to wacom for Lenovo x220.

Patch enables wacom touch screen on Lenovo x220. Values are as per
reported in Xorg.0.log and attached here.

[ 12.877] (II) config/udev: Adding input device Wacom ISDv4 E6 Pen (/dev/input/event6)
[ 12.877] (**) Wacom ISDv4 E6 Pen: Applying InputClass "evdev tablet catchall"
[ 12.877] (**) Wacom ISDv4 E6 Pen: Applying InputClass "Wacom class"
[ 12.877] (II) LoadModule: "wacom"
[ 12.878] (II) Loading /usr/lib/xorg/modules/input/wacom_drv.so
[ 12.878] (II) Module wacom: vendor="X.Org Foundation"
[ 12.878] compiled for 1.9.0, module version = 0.10.8
[ 12.878] Module class: X.Org XInput Driver
[ 12.878] ABI class: X.Org XInput driver, version 11.0
[ 12.878] (**) Option "Device" "/dev/input/event6"
[ 12.892] (II) Wacom ISDv4 E6 Pen: type not specified, assuming 'stylus'.
[ 12.892] (II) Wacom ISDv4 E6 Pen: other types will be automatically added.
[ 12.892] (**) Wacom ISDv4 E6 Pen stylus: always reports core events
[ 12.892] (--) Wacom ISDv4 E6 Pen stylus: using pressure threshold of 27 for button 1
[ 12.892] (--) Wacom ISDv4 E6 Pen stylus: Wacom USB TabletPC tablet maxX=27760 maxY=15694 maxZ=255 resX=1016 resY=1016 tilt=disabled
[ 12.892] (II) Wacom ISDv4 E6 Pen stylus: hotplugging dependent devices.
[ 12.892] (**) Wacom ISDv4 E6 Pen eraser: Applying InputClass "evdev tablet catchall"
[ 12.892] (**) Wacom ISDv4 E6 Pen eraser: Applying InputClass "Wacom class"
[ 12.892] (**) Option "Device" "/dev/input/event6"
[ 12.920] (**) Wacom ISDv4 E6 Pen eraser: always reports core events
[ 12.920] (--) Wacom ISDv4 E6 Pen eraser: Wacom USB TabletPC tablet maxX=27760 maxY=15694 maxZ=255 resX=1016 resY=1016 tilt=disabled
[ 12.936] (II) XINPUT: Adding extended input device "Wacom ISDv4 E6 Pen eraser" (type: ERASER)
[ 12.936] (--) Wacom ISDv4 E6 Pen eraser: top X=0 top Y=0 bottom X=27760 bottom Y=15694 resol X=1016 resol Y=1016
[ 12.988] (II) Wacom ISDv4 E6 Pen stylus: hotplugging completed.
[ 13.036] (II) XINPUT: Adding extended input device "Wacom ISDv4 E6 Pen stylus" (type: STYLUS)
[ 13.036] (--) Wacom ISDv4 E6 Pen stylus: top X=0 top Y=0 bottom X=27760 bottom Y=15694 resol X=1016 resol Y=1016
[ 13.036] (II) config/udev: Adding input device Wacom ISDv4 E6 Pen (/dev/input/mouse0)
[ 13.036] (II) No input driver/identifier specified (ignoring)
[ 13.036] (II) config/udev: Adding input device Wacom ISDv4 E6 Finger (/dev/input/event7)
[ 13.036] (**) Wacom ISDv4 E6 Finger: Applying InputClass "evdev touchscreen catchall"
[ 13.036] (**) Wacom ISDv4 E6 Finger: Applying InputClass "Wacom class"
[ 13.036] (**) Option "Device" "/dev/input/event7"
[ 13.068] (II) Wacom ISDv4 E6 Finger: type not specified, assuming 'touch'.
[ 13.068] (II) Wacom ISDv4 E6 Finger: other types will be automatically added.
[ 13.068] (**) Wacom ISDv4 E6 Finger touch: always reports core events
[ 13.068] (--) Wacom ISDv4 E6 Finger touch: using pressure threshold of 27 for button 1
[ 13.068] (--) Wacom ISDv4 E6 Finger touch: Wacom USB TabletPC tablet maxX=0 maxY=0 maxZ=255 resX=1016 resY=1016 tilt=disabled
[ 13.068] (II) Wacom ISDv4 E6 Finger touch: hotplugging dependent devices.
[ 13.068] (II) Wacom ISDv4 E6 Finger touch: hotplugging completed.
[ 13.132] (II) XINPUT: Adding extended input device "Wacom ISDv4 E6 Finger touch" (type: TOUCH)
[ 13.132] (--) Wacom ISDv4 E6 Finger touch: top X=0 top Y=0 bottom X=2776 bottom Y=1549 resol X=1016 resol Y=1016
[ 13.228] (II) config/udev: Adding input device Wacom ISDv4 E6 Finger (/dev/input/mouse1)



2011-03-31 17:22:20

by Manoj Iyer

[permalink] [raw]
Subject: [PATCH] add support for Lenovo tablet ID (0xE6)

Signed-off-by: Manoj Iyer <[email protected]>
---
drivers/input/tablet/wacom_wac.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
index 5597637..f751224 100644
--- a/drivers/input/tablet/wacom_wac.c
+++ b/drivers/input/tablet/wacom_wac.c
@@ -1364,6 +1364,8 @@ static const struct wacom_features wacom_features_0xE2 =
{ "Wacom ISDv4 E2", WACOM_PKGLEN_TPC2FG, 26202, 16325, 255, 0, TABLETPC2FG };
static const struct wacom_features wacom_features_0xE3 =
{ "Wacom ISDv4 E3", WACOM_PKGLEN_TPC2FG, 26202, 16325, 255, 0, TABLETPC2FG };
+static const struct wacom_features wacom_features_0xE6 =
+ { "ISD-V4", WACOM_PKGLEN_TPC2FG, 27760, 15694, 255, 0, TABLETPC2FG };
static const struct wacom_features wacom_features_0x47 =
{ "Wacom Intuos2 6x8", WACOM_PKGLEN_INTUOS, 20320, 16240, 1023, 31, INTUOS };
static struct wacom_features wacom_features_0xD0 =
@@ -1474,6 +1476,7 @@ const struct usb_device_id wacom_ids[] = {
{ USB_DEVICE_WACOM(0x9F) },
{ USB_DEVICE_WACOM(0xE2) },
{ USB_DEVICE_WACOM(0xE3) },
+ { USB_DEVICE_WACOM(0xE6) },
{ USB_DEVICE_WACOM(0x47) },
{ USB_DEVICE_LENOVO(0x6004) },
{ }
--
1.7.1

2011-03-31 17:44:05

by Dmitry Torokhov

[permalink] [raw]
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)

On Thu, Mar 31, 2011 at 12:20:52PM -0500, Manoj Iyer wrote:
> Signed-off-by: Manoj Iyer <[email protected]>
> ---
> drivers/input/tablet/wacom_wac.c | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
> index 5597637..f751224 100644
> --- a/drivers/input/tablet/wacom_wac.c
> +++ b/drivers/input/tablet/wacom_wac.c
> @@ -1364,6 +1364,8 @@ static const struct wacom_features wacom_features_0xE2 =
> { "Wacom ISDv4 E2", WACOM_PKGLEN_TPC2FG, 26202, 16325, 255, 0, TABLETPC2FG };
> static const struct wacom_features wacom_features_0xE3 =
> { "Wacom ISDv4 E3", WACOM_PKGLEN_TPC2FG, 26202, 16325, 255, 0, TABLETPC2FG };
> +static const struct wacom_features wacom_features_0xE6 =
> + { "ISD-V4", WACOM_PKGLEN_TPC2FG, 27760, 15694, 255, 0, TABLETPC2FG };

Manoj, shouldn't we call it "Wacom ISDv4 E6" to be consistent?

Ping, is resolution the same as with other "ISDv4"s?

Thanks,

--
Dmitry

2011-03-31 17:46:58

by Manoj Iyer

[permalink] [raw]
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)


>
> Manoj, shouldn't we call it "Wacom ISDv4 E6" to be consistent?
It shows up as such in the logs so I called it so, sure I can rename it.

>
> Ping, is resolution the same as with other "ISDv4"s?

Waiting on Ping before I resend patch.

>
> Thanks,
>

2011-03-31 17:58:59

by Chris Bagwell

[permalink] [raw]
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)

On Thu, Mar 31, 2011 at 12:43 PM, Dmitry Torokhov
<[email protected]> wrote:
> On Thu, Mar 31, 2011 at 12:20:52PM -0500, Manoj Iyer wrote:
>> Signed-off-by: Manoj Iyer <[email protected]>
>> ---
>> ?drivers/input/tablet/wacom_wac.c | ? ?3 +++
>> ?1 files changed, 3 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
>> index 5597637..f751224 100644
>> --- a/drivers/input/tablet/wacom_wac.c
>> +++ b/drivers/input/tablet/wacom_wac.c
>> @@ -1364,6 +1364,8 @@ static const struct wacom_features wacom_features_0xE2 =
>> ? ? ? { "Wacom ISDv4 E2", ? ? ? WACOM_PKGLEN_TPC2FG, ? ?26202, 16325, ?255, ?0, TABLETPC2FG };
>> ?static const struct wacom_features wacom_features_0xE3 =
>> ? ? ? { "Wacom ISDv4 E3", ? ? ? WACOM_PKGLEN_TPC2FG, ? ?26202, 16325, ?255, ?0, TABLETPC2FG };
>> +static const struct wacom_features wacom_features_0xE6 =
>> + ? ? { "ISD-V4", ? ? ? ? ? ? ? WACOM_PKGLEN_TPC2FG, ? ?27760, 15694, ?255, ?0, TABLETPC2FG };
>
> Manoj, shouldn't we call it "Wacom ISDv4 E6" to be consistent?

I think its best to rename to be consistent with others in series.

>
> Ping, is resolution the same as with other "ISDv4"s?

My guess is yes.

Note: There is a patch from Ping that you recently accepted but I do
not see on a branch yet (maybe I'm looking in wrong place). In it,
Ping replaces all resolution values with #defines and they are metric
based (aligns with synaptics) instead of these based on inches.

This patch is on version before that patch.

When convering over, it looks like value of 100/WACOM_INTUOS_RES is
the value to use here.

>
> Thanks,
>
> --
> Dmitry
>

2011-03-31 18:07:57

by Dmitry Torokhov

[permalink] [raw]
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)

On Thu, Mar 31, 2011 at 12:58:57PM -0500, Chris Bagwell wrote:
> On Thu, Mar 31, 2011 at 12:43 PM, Dmitry Torokhov
> <[email protected]> wrote:
> > On Thu, Mar 31, 2011 at 12:20:52PM -0500, Manoj Iyer wrote:
> >> Signed-off-by: Manoj Iyer <[email protected]>
> >> ---
> >> ?drivers/input/tablet/wacom_wac.c | ? ?3 +++
> >> ?1 files changed, 3 insertions(+), 0 deletions(-)
> >>
> >> diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
> >> index 5597637..f751224 100644
> >> --- a/drivers/input/tablet/wacom_wac.c
> >> +++ b/drivers/input/tablet/wacom_wac.c
> >> @@ -1364,6 +1364,8 @@ static const struct wacom_features wacom_features_0xE2 =
> >> ? ? ? { "Wacom ISDv4 E2", ? ? ? WACOM_PKGLEN_TPC2FG, ? ?26202, 16325, ?255, ?0, TABLETPC2FG };
> >> ?static const struct wacom_features wacom_features_0xE3 =
> >> ? ? ? { "Wacom ISDv4 E3", ? ? ? WACOM_PKGLEN_TPC2FG, ? ?26202, 16325, ?255, ?0, TABLETPC2FG };
> >> +static const struct wacom_features wacom_features_0xE6 =
> >> + ? ? { "ISD-V4", ? ? ? ? ? ? ? WACOM_PKGLEN_TPC2FG, ? ?27760, 15694, ?255, ?0, TABLETPC2FG };
> >
> > Manoj, shouldn't we call it "Wacom ISDv4 E6" to be consistent?
>
> I think its best to rename to be consistent with others in series.
>
> >
> > Ping, is resolution the same as with other "ISDv4"s?
>
> My guess is yes.
>
> Note: There is a patch from Ping that you recently accepted but I do
> not see on a branch yet (maybe I'm looking in wrong place).

If we are talking about the same thing it shoudl be in my 'for-linus'
branch.

Thanks.

--
Dmitry

2011-03-31 18:21:13

by Chris Bagwell

[permalink] [raw]
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)

On Thu, Mar 31, 2011 at 1:07 PM, Dmitry Torokhov
<[email protected]> wrote:
> On Thu, Mar 31, 2011 at 12:58:57PM -0500, Chris Bagwell wrote:
>> On Thu, Mar 31, 2011 at 12:43 PM, Dmitry Torokhov
>> <[email protected]> wrote:
>> > On Thu, Mar 31, 2011 at 12:20:52PM -0500, Manoj Iyer wrote:
>> >> Signed-off-by: Manoj Iyer <[email protected]>
>> >> ---
>> >> ?drivers/input/tablet/wacom_wac.c | ? ?3 +++
>> >> ?1 files changed, 3 insertions(+), 0 deletions(-)
>> >>
>> >> diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
>> >> index 5597637..f751224 100644
>> >> --- a/drivers/input/tablet/wacom_wac.c
>> >> +++ b/drivers/input/tablet/wacom_wac.c
>> >> @@ -1364,6 +1364,8 @@ static const struct wacom_features wacom_features_0xE2 =
>> >> ? ? ? { "Wacom ISDv4 E2", ? ? ? WACOM_PKGLEN_TPC2FG, ? ?26202, 16325, ?255, ?0, TABLETPC2FG };
>> >> ?static const struct wacom_features wacom_features_0xE3 =
>> >> ? ? ? { "Wacom ISDv4 E3", ? ? ? WACOM_PKGLEN_TPC2FG, ? ?26202, 16325, ?255, ?0, TABLETPC2FG };
>> >> +static const struct wacom_features wacom_features_0xE6 =
>> >> + ? ? { "ISD-V4", ? ? ? ? ? ? ? WACOM_PKGLEN_TPC2FG, ? ?27760, 15694, ?255, ?0, TABLETPC2FG };
>> >
>> > Manoj, shouldn't we call it "Wacom ISDv4 E6" to be consistent?
>>
>> I think its best to rename to be consistent with others in series.
>>
>> >
>> > Ping, is resolution the same as with other "ISDv4"s?
>>
>> My guess is yes.
>>
>> Note: There is a patch from Ping that you recently accepted but I do
>> not see on a branch yet (maybe I'm looking in wrong place).
>
> If we are talking about the same thing it shoudl be in my 'for-linus'
> branch.
>

Ah, yes. There it is.

The for-linus and next branches are quite different in this area of
file. The patch of this email would not apply cleanly to for-linus.

My suggestion is to use value of 0xE3 for which ever branch this is
merged to... but best for Ping to ack.

Chris

2011-03-31 18:28:09

by Manoj Iyer

[permalink] [raw]
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)


> Ah, yes. There it is.
>
> The for-linus and next branches are quite different in this area of
> file. The patch of this email would not apply cleanly to for-linus.
>
> My suggestion is to use value of 0xE3 for which ever branch this is
> merged to... but best for Ping to ack.

Chris,

Just to confirm, so base the patch on the for-linus tree and use the
values as in 0xE3? is that correct? I will put Ping to ack as well.

>
> Chris
>

2011-03-31 19:23:39

by Ping Cheng

[permalink] [raw]
Subject: RE: [PATCH] add support for Lenovo tablet ID (0xE6)

Acked-by: Ping Cheng <[email protected]>.

Yes, please use E3 resolutions. The X and Y values should be from your tablet though.

Thank you.

Ping

-----Original Message-----
From: Manoj [mailto:[email protected]]
Sent: Thursday, March 31, 2011 11:28 AM
To: Chris Bagwell
Cc: Dmitry Torokhov; [email protected]; Ping Cheng
Subject: Re: [PATCH] add support for Lenovo tablet ID (0xE6)


> Ah, yes. There it is.
>
> The for-linus and next branches are quite different in this area of
> file. The patch of this email would not apply cleanly to for-linus.
>
> My suggestion is to use value of 0xE3 for which ever branch this is
> merged to... but best for Ping to ack.

Chris,

Just to confirm, so base the patch on the for-linus tree and use the values as in 0xE3? is that correct? I will put Ping to ack as well.

>
> Chris
>