Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1615142 > unrolled thread
| Started by | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| First post | 2017-04-03 14:20 +0200 |
| Last post | 2017-04-03 14:20 +0200 |
| Articles | 20 — 5 participants |
Back to article view | Back to linux.kernel
[PATCH v2 0/6] hpet: fix build warnings and style Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
[PATCH v2 1/6] hpet: remove unused variable hpet in hpet_ioctl_common Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
[PATCH v2 5/6] hpet: removing unused variable m in hpet_interrupt Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
Re: [PATCH v2 5/6] hpet: removing unused variable m in hpet_interrupt Clemens Ladisch <clemens@ladisch.de> - 2017-04-03 15:10 +0200
Re: [PATCH 1/2] Alps HID I2C T4 device support Nikolaus Rath <Nikolaus@rath.org> - 2017-04-04 05:10 +0200
RE: [PATCH 1/2] Alps HID I2C T4 device support Masaki Ota <masaki.ota@jp.alps.com> - 2017-04-04 09:00 +0200
RE: [PATCH 1/2] Alps HID I2C T4 device support Masaki Ota <masaki.ota@jp.alps.com> - 2017-04-05 01:50 +0200
Re: [PATCH 1/2] Alps HID I2C T4 device support Nikolaus Rath <Nikolaus@rath.org> - 2017-04-05 01:50 +0200
RE: [PATCH 1/2] Alps HID I2C T4 device support Masaki Ota <masaki.ota@jp.alps.com> - 2017-04-05 01:50 +0200
Re: [PATCH 1/2] Alps HID I2C T4 device support Nikolaus Rath <Nikolaus@rath.org> - 2017-04-05 02:10 +0200
RE: [PATCH 1/2] Alps HID I2C T4 device support Masaki Ota <masaki.ota@jp.alps.com> - 2017-04-05 10:50 +0200
Re: [PATCH 1/2] Alps HID I2C T4 device support Nikolaus Rath <Nikolaus@rath.org> - 2017-04-05 20:40 +0200
RE: [PATCH 1/2] Alps HID I2C T4 device support Masaki Ota <masaki.ota@jp.alps.com> - 2017-04-06 03:10 +0200
Re: [PATCH 1/2] Alps HID I2C T4 device support Nikolaus Rath <Nikolaus@rath.org> - 2017-04-07 01:10 +0200
[PATCH v2 2/6] hpet: remove unused writeq/readq function definitions Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
[PATCH v2 6/6] hpet: fix style issue about braces and alignment Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
Re: [PATCH v2 6/6] hpet: fix style issue about braces and alignment Joe Perches <joe@perches.com> - 2017-04-04 05:50 +0200
[PATCH v2 4/6] hpet: replace printk by their pr_xxx counterparts Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
Re: [PATCH v2 4/6] hpet: replace printk by their pr_xxx counterparts Joe Perches <joe@perches.com> - 2017-04-03 21:50 +0200
[PATCH v2 3/6] hpet: fix checkpatch complains about spaces Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-04-03 14:20 +0200
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 0/6] hpet: fix build warnings and style |
| Message-ID | <ts97I-6L2-1@gated-at.bofh.it> |
The original intent was to remove two build warnings, but finaly took the opportunity to fix some style issues. compile-tested for both x86/x86_64/ia64. Changes since v1: - add linux/io-64-nonatomic-lo-hi.h for writeq/readq as suggested by Clemens Ladisch Corentin Labbe (6): hpet: remove unused variable hpet in hpet_ioctl_common hpet: remove unused writeq/readq function definitions hpet: fix checkpatch complains about spaces hpet: replace printk by their pr_xxx counterparts hpet: removing unused variable m in hpet_interrupt hpet: fix style issue about braces and alignment drivers/char/hpet.c | 57 ++++++++++++++++++----------------------------------- 1 file changed, 19 insertions(+), 38 deletions(-) -- 2.10.2
[toc] | [next] | [standalone]
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 1/6] hpet: remove unused variable hpet in hpet_ioctl_common |
| Message-ID | <ts97I-6L2-3@gated-at.bofh.it> |
| In reply to | #1615142 |
This patch fix the following warning:
drivers/char/hpet.c:582:23: attention : variable ‘hpet’ set but not used [-Wunused-but-set-variable]
by removing the unused variable hpet in hpet_ioctl_common
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
drivers/char/hpet.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index b941e6d..f0e6427 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -579,7 +579,6 @@ hpet_ioctl_common(struct hpet_dev *devp, unsigned int cmd, unsigned long arg,
struct hpet_info *info)
{
struct hpet_timer __iomem *timer;
- struct hpet __iomem *hpet;
struct hpets *hpetp;
int err;
unsigned long v;
@@ -591,7 +590,6 @@ hpet_ioctl_common(struct hpet_dev *devp, unsigned int cmd, unsigned long arg,
case HPET_DPI:
case HPET_IRQFREQ:
timer = devp->hd_timer;
- hpet = devp->hd_hpet;
hpetp = devp->hd_hpets;
break;
case HPET_IE_ON:
--
2.10.2
[toc] | [prev] | [next] | [standalone]
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 5/6] hpet: removing unused variable m in hpet_interrupt |
| Message-ID | <ts97I-6L2-9@gated-at.bofh.it> |
| In reply to | #1615142 |
This patch fix the following warning:
drivers/char/hpet.c:146:17: attention : variable ‘m’ set but not used [-Wunused-but-set-variable]
by removing the unused variable m in hpet_interrupt
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
drivers/char/hpet.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index 59e89e5..f6096e1 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -144,12 +144,11 @@ static irqreturn_t hpet_interrupt(int irq, void *data)
* This has the effect of treating non-periodic like periodic.
*/
if ((devp->hd_flags & (HPET_IE | HPET_PERIODIC)) == HPET_IE) {
- unsigned long m, t, mc, base, k;
+ unsigned long t, mc, base, k;
struct hpet __iomem *hpet = devp->hd_hpet;
struct hpets *hpetp = devp->hd_hpets;
t = devp->hd_ireqfreq;
- m = read_counter(&devp->hd_timer->hpet_compare);
mc = read_counter(&hpet->hpet_mc);
/* The time for the next interrupt would logically be t + m,
* however, if we are very unlucky and the interrupt is delayed
--
2.10.2
[toc] | [prev] | [next] | [standalone]
| From | Clemens Ladisch <clemens@ladisch.de> |
|---|---|
| Date | 2017-04-03 15:10 +0200 |
| Subject | Re: [PATCH v2 5/6] hpet: removing unused variable m in hpet_interrupt |
| Message-ID | <ts9U5-7iF-3@gated-at.bofh.it> |
| In reply to | #1615145 |
Corentin Labbe wrote: > This patch fix the following warning: > drivers/char/hpet.c:146:17: attention : variable ‘m’ set but not used [-Wunused-but-set-variable] > by removing the unused variable m in hpet_interrupt This patch might silence the warning, but it leaves the bug that actually caused the warning. As far as I can see, the computation of "base" should use "m". But the entire algorithm is completely bogus because it does not actually remove the race condition; the counter is likely to have advanced beyond the "mc" value when the new comparator value is written. Also see arch/x86/kernel/hpet.c for how hpet_next_event() handles this. And why a non-periodic timer should generate periodic interrupts is another question. And nobody uses this crap. So I'm really not sure what to do about this ... Regards, Clemens
[toc] | [prev] | [next] | [standalone]
| From | Nikolaus Rath <Nikolaus@rath.org> |
|---|---|
| Date | 2017-04-04 05:10 +0200 |
| Subject | Re: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsn10-7wd-11@gated-at.bofh.it> |
| In reply to | #1615182 |
Hi Ota,
> -Support Alps HID I2C T4 Touchpad device.
> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>
> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
> ---
> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
> drivers/hid/hid-core.c | 3 +-
> drivers/hid/hid-ids.h | 1 +
> 3 files changed, 403 insertions(+), 101 deletions(-)
I tried your patch on an HP Elitebook, but with rather limited
success. Before, I was able to use the touchpad in limited fashion
(https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your patch
(applied on top of 4.10), the touchpad no longer reacts at all.
That said, I didn't find a patch 2/2 anywhere.. is there something
missing?
Thanks,
-Nikolaus
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Masaki Ota <masaki.ota@jp.alps.com> |
|---|---|
| Date | 2017-04-04 09:00 +0200 |
| Subject | RE: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsqBA-1io-5@gated-at.bofh.it> |
| In reply to | #1615676 |
Hi, Nikolaus,
Your Touchpad is 044E:120C, right?
PATCH 1/2 supports 044E:120C Touchpad device.
I think you can use all features of this Touchpad.
PATCH 2/2 supports 044E:1215 Touchpad device.
You don't need to care about this.
If Touchpad does not work completely, there is something an error.
What does dmesg show?
Best Regards,
Masaki Ota
-----Original Message-----
From: Nikolaus Rath [mailto:Nikolaus@rath.org]
Sent: Tuesday, April 04, 2017 12:09 PM
To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
Hi Ota,
> -Support Alps HID I2C T4 Touchpad device.
> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook Folio
> G1, Elitebook 1030 G1, Elitebook 1040 G3
>
> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
> ---
> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
> drivers/hid/hid-core.c | 3 +-
> drivers/hid/hid-ids.h | 1 +
> 3 files changed, 403 insertions(+), 101 deletions(-)
I tried your patch on an HP Elitebook, but with rather limited success. Before, I was able to use the touchpad in limited fashion (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your patch (applied on top of 4.10), the touchpad no longer reacts at all.
That said, I didn't find a patch 2/2 anywhere.. is there something missing?
Thanks,
-Nikolaus
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Masaki Ota <masaki.ota@jp.alps.com> |
|---|---|
| Date | 2017-04-05 01:50 +0200 |
| Subject | RE: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsGmZ-3eo-1@gated-at.bofh.it> |
| In reply to | #1615731 |
Hi, Nikolaus,
There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
However, both of interface should work properly on Linux.
I tested it on Ubuntu +4.10 kernel.
If you don't apply my patch, does device work as I2C? (044E:120C appears?)
Best Regards,
Masaki Ota
-----Original Message-----
From: Nikolaus Rath [mailto:Nikolaus@rath.org]
Sent: Wednesday, April 05, 2017 2:09 AM
To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
Hi Masaki,
Yes, I think I have a 044E:120C. Is there a way to find out for sure?
It's not listed by e.g. lspci.
The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
I have attached the dmesg output.
Best,
-Nikolaus
On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> Your Touchpad is 044E:120C, right?
>
> PATCH 1/2 supports 044E:120C Touchpad device.
> I think you can use all features of this Touchpad.
>
> PATCH 2/2 supports 044E:1215 Touchpad device.
> You don't need to care about this.
>
> If Touchpad does not work completely, there is something an error.
> What does dmesg show?
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Tuesday, April 04, 2017 12:09 PM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Ota,
>
>> -Support Alps HID I2C T4 Touchpad device.
>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook Folio
>> G1, Elitebook 1030 G1, Elitebook 1040 G3
>>
>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>> ---
>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>> drivers/hid/hid-core.c | 3 +-
>> drivers/hid/hid-ids.h | 1 +
>> 3 files changed, 403 insertions(+), 101 deletions(-)
>
> I tried your patch on an HP Elitebook, but with rather limited success. Before, I was able to use the touchpad in limited fashion (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your patch (applied on top of 4.10), the touchpad no longer reacts at all.
>
> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>
> Thanks,
> -Nikolaus
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Nikolaus Rath <Nikolaus@rath.org> |
|---|---|
| Date | 2017-04-05 01:50 +0200 |
| Subject | Re: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsGmZ-3eo-7@gated-at.bofh.it> |
| In reply to | #1616448 |
Hi Masaki,
Yes, without your patch the touchpad is mostly working - I just can't
configure it.
Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
Best,
-Nikolaus
On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>
> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>
> However, both of interface should work properly on Linux.
> I tested it on Ubuntu +4.10 kernel.
>
> If you don't apply my patch, does device work as I2C? (044E:120C appears?)
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Wednesday, April 05, 2017 2:09 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
> It's not listed by e.g. lspci.
>
> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>
> I have attached the dmesg output.
>
> Best,
> -Nikolaus
>
>
> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> Your Touchpad is 044E:120C, right?
>>
>> PATCH 1/2 supports 044E:120C Touchpad device.
>> I think you can use all features of this Touchpad.
>>
>> PATCH 2/2 supports 044E:1215 Touchpad device.
>> You don't need to care about this.
>>
>> If Touchpad does not work completely, there is something an error.
>> What does dmesg show?
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Tuesday, April 04, 2017 12:09 PM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Ota,
>>
>>> -Support Alps HID I2C T4 Touchpad device.
>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook Folio
>>> G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>
>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>> ---
>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>> drivers/hid/hid-core.c | 3 +-
>>> drivers/hid/hid-ids.h | 1 +
>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>
>> I tried your patch on an HP Elitebook, but with rather limited
>> success. Before, I was able to use the touchpad in limited fashion
>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>> patch (applied on top of 4.10), the touchpad no longer reacts at
>> all.
>>
>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>
>> Thanks,
>> -Nikolaus
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Masaki Ota <masaki.ota@jp.alps.com> |
|---|---|
| Date | 2017-04-05 01:50 +0200 |
| Subject | RE: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsGmZ-3eo-9@gated-at.bofh.it> |
| In reply to | #1616449 |
Hi, Nikolaus,
Um, but demesg log does not have any error of this Touchpad.
It's a strange.
Best Regards,
Masaki Ota
-----Original Message-----
From: Nikolaus Rath [mailto:Nikolaus@rath.org]
Sent: Wednesday, April 05, 2017 8:43 AM
To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
Hi Masaki,
Yes, without your patch the touchpad is mostly working - I just can't configure it.
Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
Best,
-Nikolaus
On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>
> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>
> However, both of interface should work properly on Linux.
> I tested it on Ubuntu +4.10 kernel.
>
> If you don't apply my patch, does device work as I2C? (044E:120C
> appears?)
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Wednesday, April 05, 2017 2:09 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
> linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
> It's not listed by e.g. lspci.
>
> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>
> I have attached the dmesg output.
>
> Best,
> -Nikolaus
>
>
> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> Your Touchpad is 044E:120C, right?
>>
>> PATCH 1/2 supports 044E:120C Touchpad device.
>> I think you can use all features of this Touchpad.
>>
>> PATCH 2/2 supports 044E:1215 Touchpad device.
>> You don't need to care about this.
>>
>> If Touchpad does not work completely, there is something an error.
>> What does dmesg show?
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Tuesday, April 04, 2017 12:09 PM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Ota,
>>
>>> -Support Alps HID I2C T4 Touchpad device.
>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook
>>> Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>
>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>> ---
>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>> drivers/hid/hid-core.c | 3 +-
>>> drivers/hid/hid-ids.h | 1 +
>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>
>> I tried your patch on an HP Elitebook, but with rather limited
>> success. Before, I was able to use the touchpad in limited fashion
>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>> patch (applied on top of 4.10), the touchpad no longer reacts at all.
>>
>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>
>> Thanks,
>> -Nikolaus
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Nikolaus Rath <Nikolaus@rath.org> |
|---|---|
| Date | 2017-04-05 02:10 +0200 |
| Subject | Re: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsGGl-3zJ-1@gated-at.bofh.it> |
| In reply to | #1616451 |
Hi Masaki,
Well, I'd be pleasently surprised if every bug always came together with
an associated error message :-). No matter if there's a dmesg entry or
not, at the moment this patch will make life much worse for at least
some EliteBook owners.
Is there anything I can do to help you debug this?
Best,
-Nikolaus
On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> Um, but demesg log does not have any error of this Touchpad.
> It's a strange.
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Wednesday, April 05, 2017 8:43 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Yes, without your patch the touchpad is mostly working - I just can't configure it.
>
> Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
>
> Best,
> -Nikolaus
>
> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>>
>> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
>> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>>
>> However, both of interface should work properly on Linux.
>> I tested it on Ubuntu +4.10 kernel.
>>
>> If you don't apply my patch, does device work as I2C? (044E:120C
>> appears?)
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Wednesday, April 05, 2017 2:09 AM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>> linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Masaki,
>>
>> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
>> It's not listed by e.g. lspci.
>>
>> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>>
>> I have attached the dmesg output.
>>
>> Best,
>> -Nikolaus
>>
>>
>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>> Hi, Nikolaus,
>>>
>>> Your Touchpad is 044E:120C, right?
>>>
>>> PATCH 1/2 supports 044E:120C Touchpad device.
>>> I think you can use all features of this Touchpad.
>>>
>>> PATCH 2/2 supports 044E:1215 Touchpad device.
>>> You don't need to care about this.
>>>
>>> If Touchpad does not work completely, there is something an error.
>>> What does dmesg show?
>>>
>>> Best Regards,
>>> Masaki Ota
>>> -----Original Message-----
>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>> Sent: Tuesday, April 04, 2017 12:09 PM
>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>
>>> Hi Ota,
>>>
>>>> -Support Alps HID I2C T4 Touchpad device.
>>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook
>>>> Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>>
>>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>>> ---
>>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>>> drivers/hid/hid-core.c | 3 +-
>>>> drivers/hid/hid-ids.h | 1 +
>>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>>
>>> I tried your patch on an HP Elitebook, but with rather limited
>>> success. Before, I was able to use the touchpad in limited fashion
>>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>>> patch (applied on top of 4.10), the touchpad no longer reacts at all.
>>>
>>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>>
>>> Thanks,
>>> -Nikolaus
>>>
>>> --
>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>
>>> »Time flies like an arrow, fruit flies like a Banana.«
>>
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Masaki Ota <masaki.ota@jp.alps.com> |
|---|---|
| Date | 2017-04-05 10:50 +0200 |
| Subject | RE: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsONA-kg-15@gated-at.bofh.it> |
| In reply to | #1616453 |
Hi, Nikolaus,
If you have a time, please try below debug method.
Download below file, copy it to your system and unpack.
https://www.filesanywhere.com/fs/v.aspx?v=8b716a8e5b6773baa799
Procedure ex:
#cd Desktop/LinuxModDebug
#sudo chmod 755 linux_kr_rebuild_tool_hid.sh
#sudo ./linux_kr_rebuild_tool_hid.sh /init linux-4.10.tar.gz
#sudo ./linux_kr_rebuild_tool_hid.sh /build DebugSrc
After that Touchpad all features should work.
If Touchpad does not work, something error appears on dmesg.
Best Regards,
Masaki Ota
-----Original Message-----
From: Nikolaus Rath [mailto:Nikolaus@rath.org]
Sent: Wednesday, April 05, 2017 9:01 AM
To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
Hi Masaki,
Well, I'd be pleasently surprised if every bug always came together with an associated error message :-). No matter if there's a dmesg entry or not, at the moment this patch will make life much worse for at least some EliteBook owners.
Is there anything I can do to help you debug this?
Best,
-Nikolaus
On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> Um, but demesg log does not have any error of this Touchpad.
> It's a strange.
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Wednesday, April 05, 2017 8:43 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
> linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Yes, without your patch the touchpad is mostly working - I just can't configure it.
>
> Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
>
> Best,
> -Nikolaus
>
> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>>
>> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
>> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>>
>> However, both of interface should work properly on Linux.
>> I tested it on Ubuntu +4.10 kernel.
>>
>> If you don't apply my patch, does device work as I2C? (044E:120C
>> appears?)
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Wednesday, April 05, 2017 2:09 AM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>> linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Masaki,
>>
>> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
>> It's not listed by e.g. lspci.
>>
>> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>>
>> I have attached the dmesg output.
>>
>> Best,
>> -Nikolaus
>>
>>
>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>> Hi, Nikolaus,
>>>
>>> Your Touchpad is 044E:120C, right?
>>>
>>> PATCH 1/2 supports 044E:120C Touchpad device.
>>> I think you can use all features of this Touchpad.
>>>
>>> PATCH 2/2 supports 044E:1215 Touchpad device.
>>> You don't need to care about this.
>>>
>>> If Touchpad does not work completely, there is something an error.
>>> What does dmesg show?
>>>
>>> Best Regards,
>>> Masaki Ota
>>> -----Original Message-----
>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>> Sent: Tuesday, April 04, 2017 12:09 PM
>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>
>>> Hi Ota,
>>>
>>>> -Support Alps HID I2C T4 Touchpad device.
>>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook
>>>> Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>>
>>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>>> ---
>>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>>> drivers/hid/hid-core.c | 3 +-
>>>> drivers/hid/hid-ids.h | 1 +
>>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>>
>>> I tried your patch on an HP Elitebook, but with rather limited
>>> success. Before, I was able to use the touchpad in limited fashion
>>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>>> patch (applied on top of 4.10), the touchpad no longer reacts at all.
>>>
>>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>>
>>> Thanks,
>>> -Nikolaus
>>>
>>> --
>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>
>>> »Time flies like an arrow, fruit flies like a Banana.«
>>
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Nikolaus Rath <Nikolaus@rath.org> |
|---|---|
| Date | 2017-04-05 20:40 +0200 |
| Subject | Re: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tsY0x-6cV-5@gated-at.bofh.it> |
| In reply to | #1616708 |
Hi Masaki,
Could you be a little more specific about what you need? I don't like
executing scripts containing several instances of 'sudo rm -rf
[something]'.
It seems that the script is meant to install debugging versions of some
modules. Could you simply send me a patch against the official kernel
that includes your debugging code? I'm perfectly able to compile it and
load the modules on my own :-).
Thanks,
-Nikolaus
On Apr 05 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> If you have a time, please try below debug method.
>
> Download below file, copy it to your system and unpack.
> https://www.filesanywhere.com/fs/v.aspx?v=8b716a8e5b6773baa799
>
> Procedure ex:
> #cd Desktop/LinuxModDebug
> #sudo chmod 755 linux_kr_rebuild_tool_hid.sh
> #sudo ./linux_kr_rebuild_tool_hid.sh /init linux-4.10.tar.gz
> #sudo ./linux_kr_rebuild_tool_hid.sh /build DebugSrc
>
> After that Touchpad all features should work.
> If Touchpad does not work, something error appears on dmesg.
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Wednesday, April 05, 2017 9:01 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Well, I'd be pleasently surprised if every bug always came together
> with an associated error message :-). No matter if there's a dmesg
> entry or not, at the moment this patch will make life much worse for
> at least some EliteBook owners.
>
> Is there anything I can do to help you debug this?
>
> Best,
> -Nikolaus
>
>
> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> Um, but demesg log does not have any error of this Touchpad.
>> It's a strange.
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Wednesday, April 05, 2017 8:43 AM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>> linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Masaki,
>>
>> Yes, without your patch the touchpad is mostly working - I just can't configure it.
>>
>> Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
>>
>> Best,
>> -Nikolaus
>>
>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>> Hi, Nikolaus,
>>>
>>> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>>>
>>> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
>>> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>>>
>>> However, both of interface should work properly on Linux.
>>> I tested it on Ubuntu +4.10 kernel.
>>>
>>> If you don't apply my patch, does device work as I2C? (044E:120C
>>> appears?)
>>>
>>> Best Regards,
>>> Masaki Ota
>>> -----Original Message-----
>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>> Sent: Wednesday, April 05, 2017 2:09 AM
>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>>> linux-input@vger.kernel.org
>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>
>>> Hi Masaki,
>>>
>>> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
>>> It's not listed by e.g. lspci.
>>>
>>> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>>>
>>> I have attached the dmesg output.
>>>
>>> Best,
>>> -Nikolaus
>>>
>>>
>>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>>> Hi, Nikolaus,
>>>>
>>>> Your Touchpad is 044E:120C, right?
>>>>
>>>> PATCH 1/2 supports 044E:120C Touchpad device.
>>>> I think you can use all features of this Touchpad.
>>>>
>>>> PATCH 2/2 supports 044E:1215 Touchpad device.
>>>> You don't need to care about this.
>>>>
>>>> If Touchpad does not work completely, there is something an error.
>>>> What does dmesg show?
>>>>
>>>> Best Regards,
>>>> Masaki Ota
>>>> -----Original Message-----
>>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>>> Sent: Tuesday, April 04, 2017 12:09 PM
>>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>>>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>>
>>>> Hi Ota,
>>>>
>>>>> -Support Alps HID I2C T4 Touchpad device.
>>>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook
>>>>> Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>>>
>>>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>>>> ---
>>>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>>>> drivers/hid/hid-core.c | 3 +-
>>>>> drivers/hid/hid-ids.h | 1 +
>>>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>>>
>>>> I tried your patch on an HP Elitebook, but with rather limited
>>>> success. Before, I was able to use the touchpad in limited fashion
>>>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>>>> patch (applied on top of 4.10), the touchpad no longer reacts at all.
>>>>
>>>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>>>
>>>> Thanks,
>>>> -Nikolaus
>>>>
>>>> --
>>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>>
>>>> »Time flies like an arrow, fruit flies like a Banana.«
>>>
>>>
>>> --
>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>
>>> »Time flies like an arrow, fruit flies like a Banana.«
>>
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Masaki Ota <masaki.ota@jp.alps.com> |
|---|---|
| Date | 2017-04-06 03:10 +0200 |
| Subject | RE: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <tt45X-1FN-13@gated-at.bofh.it> |
| In reply to | #1617275 |
Hi, Nikolaus,
Could you add below debug message to hid-alps.c, and check it?
This device is "HID_DEVICE_ID_ALPS_T4_BTNLESS"(0x120C).
If the device is UNKNOWN, this device does not work completely.
And if the system does not call here, it has nothing to do with my patch.
static int alps_probe()
{ ...
...
...
printk("====> ALPS Debug Log: (%x) \n", hdev->product);
switch (hdev->product) {
case HID_DEVICE_ID_ALPS_T4_BTNLESS:
data->dev_type = T4;
break;
case HID_DEVICE_ID_ALPS_U1_DUAL:
data->dev_type = U1;
break;
default:
data->dev_type = UNKNOWN;
}
Best Regards,
Masaki Ota
-----Original Message-----
From: Nikolaus Rath [mailto:Nikolaus@rath.org]
Sent: Thursday, April 06, 2017 3:36 AM
To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
Hi Masaki,
Could you be a little more specific about what you need? I don't like executing scripts containing several instances of 'sudo rm -rf [something]'.
It seems that the script is meant to install debugging versions of some modules. Could you simply send me a patch against the official kernel that includes your debugging code? I'm perfectly able to compile it and load the modules on my own :-).
Thanks,
-Nikolaus
On Apr 05 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> If you have a time, please try below debug method.
>
> Download below file, copy it to your system and unpack.
> https://www.filesanywhere.com/fs/v.aspx?v=8b716a8e5b6773baa799
>
> Procedure ex:
> #cd Desktop/LinuxModDebug
> #sudo chmod 755 linux_kr_rebuild_tool_hid.sh #sudo
> ./linux_kr_rebuild_tool_hid.sh /init linux-4.10.tar.gz #sudo
> ./linux_kr_rebuild_tool_hid.sh /build DebugSrc
>
> After that Touchpad all features should work.
> If Touchpad does not work, something error appears on dmesg.
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Wednesday, April 05, 2017 9:01 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
> linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Well, I'd be pleasently surprised if every bug always came together
> with an associated error message :-). No matter if there's a dmesg
> entry or not, at the moment this patch will make life much worse for
> at least some EliteBook owners.
>
> Is there anything I can do to help you debug this?
>
> Best,
> -Nikolaus
>
>
> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> Um, but demesg log does not have any error of this Touchpad.
>> It's a strange.
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Wednesday, April 05, 2017 8:43 AM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>> linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Masaki,
>>
>> Yes, without your patch the touchpad is mostly working - I just can't configure it.
>>
>> Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
>>
>> Best,
>> -Nikolaus
>>
>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>> Hi, Nikolaus,
>>>
>>> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>>>
>>> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
>>> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>>>
>>> However, both of interface should work properly on Linux.
>>> I tested it on Ubuntu +4.10 kernel.
>>>
>>> If you don't apply my patch, does device work as I2C? (044E:120C
>>> appears?)
>>>
>>> Best Regards,
>>> Masaki Ota
>>> -----Original Message-----
>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>> Sent: Wednesday, April 05, 2017 2:09 AM
>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>>> linux-input@vger.kernel.org
>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>
>>> Hi Masaki,
>>>
>>> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
>>> It's not listed by e.g. lspci.
>>>
>>> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>>>
>>> I have attached the dmesg output.
>>>
>>> Best,
>>> -Nikolaus
>>>
>>>
>>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>>> Hi, Nikolaus,
>>>>
>>>> Your Touchpad is 044E:120C, right?
>>>>
>>>> PATCH 1/2 supports 044E:120C Touchpad device.
>>>> I think you can use all features of this Touchpad.
>>>>
>>>> PATCH 2/2 supports 044E:1215 Touchpad device.
>>>> You don't need to care about this.
>>>>
>>>> If Touchpad does not work completely, there is something an error.
>>>> What does dmesg show?
>>>>
>>>> Best Regards,
>>>> Masaki Ota
>>>> -----Original Message-----
>>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>>> Sent: Tuesday, April 04, 2017 12:09 PM
>>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>>>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>>
>>>> Hi Ota,
>>>>
>>>>> -Support Alps HID I2C T4 Touchpad device.
>>>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook
>>>>> Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>>>
>>>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>>>> ---
>>>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>>>> drivers/hid/hid-core.c | 3 +-
>>>>> drivers/hid/hid-ids.h | 1 +
>>>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>>>
>>>> I tried your patch on an HP Elitebook, but with rather limited
>>>> success. Before, I was able to use the touchpad in limited fashion
>>>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>>>> patch (applied on top of 4.10), the touchpad no longer reacts at all.
>>>>
>>>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>>>
>>>> Thanks,
>>>> -Nikolaus
>>>>
>>>> --
>>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>>
>>>> »Time flies like an arrow, fruit flies like a Banana.«
>>>
>>>
>>> --
>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>
>>> »Time flies like an arrow, fruit flies like a Banana.«
>>
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Nikolaus Rath <Nikolaus@rath.org> |
|---|---|
| Date | 2017-04-07 01:10 +0200 |
| Subject | Re: [PATCH 1/2] Alps HID I2C T4 device support |
| Message-ID | <ttoHn-7pr-5@gated-at.bofh.it> |
| In reply to | #1617452 |
Dear Masaki,
Thanks! I think I figured out the problem - it was on my side.
After I installed your patch, I ran "make localmodconfig". However, I
think prior to your patch my touchpad was handled by hid_generic - so
hid_alps was not loaded and the patched module thus never
build. However, your patch still prevented hid_generic from taking
control of the touchpad. After I explicitly enabled the hid_alps module,
my touchpad is now working again and, thanks to your patch, can now also
be configured.
Thanks again! Feel free to add a:
Tested-By: Nikolaus Rath <Nikolaus@rath.org
Best,
-Nikolaus
On Apr 06 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
> Hi, Nikolaus,
>
> Could you add below debug message to hid-alps.c, and check it?
> This device is "HID_DEVICE_ID_ALPS_T4_BTNLESS"(0x120C).
> If the device is UNKNOWN, this device does not work completely.
> And if the system does not call here, it has nothing to do with my patch.
>
> static int alps_probe()
> { ...
> ...
> ...
> printk("====> ALPS Debug Log: (%x) \n", hdev->product);
> switch (hdev->product) {
> case HID_DEVICE_ID_ALPS_T4_BTNLESS:
> data->dev_type = T4;
> break;
> case HID_DEVICE_ID_ALPS_U1_DUAL:
> data->dev_type = U1;
> break;
> default:
> data->dev_type = UNKNOWN;
> }
>
> Best Regards,
> Masaki Ota
> -----Original Message-----
> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
> Sent: Thursday, April 06, 2017 3:36 AM
> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
> Cc: linux-kernel <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>
> Hi Masaki,
>
> Could you be a little more specific about what you need? I don't like
> executing scripts containing several instances of 'sudo rm -rf
> [something]'.
>
> It seems that the script is meant to install debugging versions of
> some modules. Could you simply send me a patch against the official
> kernel that includes your debugging code? I'm perfectly able to
> compile it and load the modules on my own :-).
>
> Thanks,
> -Nikolaus
>
> On Apr 05 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>> Hi, Nikolaus,
>>
>> If you have a time, please try below debug method.
>>
>> Download below file, copy it to your system and unpack.
>> https://www.filesanywhere.com/fs/v.aspx?v=8b716a8e5b6773baa799
>>
>> Procedure ex:
>> #cd Desktop/LinuxModDebug
>> #sudo chmod 755 linux_kr_rebuild_tool_hid.sh #sudo
>> ./linux_kr_rebuild_tool_hid.sh /init linux-4.10.tar.gz #sudo
>> ./linux_kr_rebuild_tool_hid.sh /build DebugSrc
>>
>> After that Touchpad all features should work.
>> If Touchpad does not work, something error appears on dmesg.
>>
>> Best Regards,
>> Masaki Ota
>> -----Original Message-----
>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>> Sent: Wednesday, April 05, 2017 9:01 AM
>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>> linux-input@vger.kernel.org
>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>
>> Hi Masaki,
>>
>> Well, I'd be pleasently surprised if every bug always came together
>> with an associated error message :-). No matter if there's a dmesg
>> entry or not, at the moment this patch will make life much worse for
>> at least some EliteBook owners.
>>
>> Is there anything I can do to help you debug this?
>>
>> Best,
>> -Nikolaus
>>
>>
>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>> Hi, Nikolaus,
>>>
>>> Um, but demesg log does not have any error of this Touchpad.
>>> It's a strange.
>>>
>>> Best Regards,
>>> Masaki Ota
>>> -----Original Message-----
>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>> Sent: Wednesday, April 05, 2017 8:43 AM
>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>>> linux-input@vger.kernel.org
>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>
>>> Hi Masaki,
>>>
>>> Yes, without your patch the touchpad is mostly working - I just can't configure it.
>>>
>>> Please take a look at https://bugs.freedesktop.org/show_bug.cgi?id=100345.
>>>
>>> Best,
>>> -Nikolaus
>>>
>>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>>> Hi, Nikolaus,
>>>>
>>>> There is no 044E:120C device, but it looks like Alps Touchpad is detected as PS/2 Touchpad.
>>>>
>>>> Actually, this Touchpad has two interfaces. One is I2C, the other is PS/2.
>>>> Default setting is I2C, and if the system does not support I2C, Touchpad works as PS/2.
>>>>
>>>> However, both of interface should work properly on Linux.
>>>> I tested it on Ubuntu +4.10 kernel.
>>>>
>>>> If you don't apply my patch, does device work as I2C? (044E:120C
>>>> appears?)
>>>>
>>>> Best Regards,
>>>> Masaki Ota
>>>> -----Original Message-----
>>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>>> Sent: Wednesday, April 05, 2017 2:09 AM
>>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>
>>>> Cc: linux-kernel <linux-kernel@vger.kernel.org>;
>>>> linux-input@vger.kernel.org
>>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>>
>>>> Hi Masaki,
>>>>
>>>> Yes, I think I have a 044E:120C. Is there a way to find out for sure?
>>>> It's not listed by e.g. lspci.
>>>>
>>>> The touchpad is definitely not reacting to anything. evemu-record does not show any events either.
>>>>
>>>> I have attached the dmesg output.
>>>>
>>>> Best,
>>>> -Nikolaus
>>>>
>>>>
>>>> On Apr 04 2017, Masaki Ota <masaki.ota@jp.alps.com> wrote:
>>>>> Hi, Nikolaus,
>>>>>
>>>>> Your Touchpad is 044E:120C, right?
>>>>>
>>>>> PATCH 1/2 supports 044E:120C Touchpad device.
>>>>> I think you can use all features of this Touchpad.
>>>>>
>>>>> PATCH 2/2 supports 044E:1215 Touchpad device.
>>>>> You don't need to care about this.
>>>>>
>>>>> If Touchpad does not work completely, there is something an error.
>>>>> What does dmesg show?
>>>>>
>>>>> Best Regards,
>>>>> Masaki Ota
>>>>> -----Original Message-----
>>>>> From: Nikolaus Rath [mailto:Nikolaus@rath.org]
>>>>> Sent: Tuesday, April 04, 2017 12:09 PM
>>>>> To: 太田 真喜 Masaki Ota <masaki.ota@jp.alps.com>; linux-kernel
>>>>> <linux-kernel@vger.kernel.org>; linux-input@vger.kernel.org
>>>>> Subject: Re: [PATCH 1/2] Alps HID I2C T4 device support
>>>>>
>>>>> Hi Ota,
>>>>>
>>>>>> -Support Alps HID I2C T4 Touchpad device.
>>>>>> -Laptop names that use this Touchpad:HP Zbook Studio, Elitebook
>>>>>> Folio G1, Elitebook 1030 G1, Elitebook 1040 G3
>>>>>>
>>>>>> Signed-off-by: Masaki Ota <masaki.ota@xxxxxxxxxxx>
>>>>>> ---
>>>>>> drivers/hid/hid-alps.c | 500 +++++++++++++++++++++++++++++++++++++++----------
>>>>>> drivers/hid/hid-core.c | 3 +-
>>>>>> drivers/hid/hid-ids.h | 1 +
>>>>>> 3 files changed, 403 insertions(+), 101 deletions(-)
>>>>>
>>>>> I tried your patch on an HP Elitebook, but with rather limited
>>>>> success. Before, I was able to use the touchpad in limited fashion
>>>>> (https://bugs.freedesktop.org/show_bug.cgi?id=100345). With your
>>>>> patch (applied on top of 4.10), the touchpad no longer reacts at all.
>>>>>
>>>>> That said, I didn't find a patch 2/2 anywhere.. is there something missing?
>>>>>
>>>>> Thanks,
>>>>> -Nikolaus
>>>>>
>>>>> --
>>>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>>>
>>>>> »Time flies like an arrow, fruit flies like a Banana.«
>>>>
>>>>
>>>> --
>>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>>
>>>> »Time flies like an arrow, fruit flies like a Banana.«
>>>
>>>
>>> --
>>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>>
>>> »Time flies like an arrow, fruit flies like a Banana.«
>>
>>
>> --
>> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>>
>> »Time flies like an arrow, fruit flies like a Banana.«
>
>
> --
> GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
>
> »Time flies like an arrow, fruit flies like a Banana.«
--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F
»Time flies like an arrow, fruit flies like a Banana.«
[toc] | [prev] | [next] | [standalone]
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 2/6] hpet: remove unused writeq/readq function definitions |
| Message-ID | <ts97I-6L2-19@gated-at.bofh.it> |
| In reply to | #1615142 |
On all arch using hpet, only i386 miss writeq/readq.
Instead of rewriting them, use linux/io-64-nonatomic-lo-hi.h which
already have them.
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
drivers/char/hpet.c | 17 +----------------
1 file changed, 1 insertion(+), 16 deletions(-)
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index f0e6427..206d3a6 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -19,6 +19,7 @@
#include <linux/ioport.h>
#include <linux/fcntl.h>
#include <linux/init.h>
+#include <linux/io-64-nonatomic-lo-hi.h>
#include <linux/poll.h>
#include <linux/mm.h>
#include <linux/proc_fs.h>
@@ -123,22 +124,6 @@ static struct hpets *hpets;
#define HPET_PERIODIC 0x0004
#define HPET_SHARED_IRQ 0x0008
-
-#ifndef readq
-static inline unsigned long long readq(void __iomem *addr)
-{
- return readl(addr) | (((unsigned long long)readl(addr + 4)) << 32LL);
-}
-#endif
-
-#ifndef writeq
-static inline void writeq(unsigned long long v, void __iomem *addr)
-{
- writel(v & 0xffffffff, addr);
- writel(v >> 32, addr + 4);
-}
-#endif
-
static irqreturn_t hpet_interrupt(int irq, void *data)
{
struct hpet_dev *devp;
--
2.10.2
[toc] | [prev] | [next] | [standalone]
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 6/6] hpet: fix style issue about braces and alignment |
| Message-ID | <ts97J-6L2-27@gated-at.bofh.it> |
| In reply to | #1615142 |
This patch fix all style issue for braces and alignment
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
drivers/char/hpet.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index f6096e1..fe52f39 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -255,9 +255,9 @@ static int hpet_open(struct inode *inode, struct file *file)
for (devp = NULL, hpetp = hpets; hpetp && !devp; hpetp = hpetp->hp_next)
for (i = 0; i < hpetp->hp_ntimer; i++)
- if (hpetp->hp_dev[i].hd_flags & HPET_OPEN)
+ if (hpetp->hp_dev[i].hd_flags & HPET_OPEN) {
continue;
- else {
+ } else {
devp = &hpetp->hp_dev[i];
break;
}
@@ -304,9 +304,9 @@ hpet_read(struct file *file, char __user *buf, size_t count, loff_t *ppos)
devp->hd_irqdata = 0;
spin_unlock_irq(&hpet_lock);
- if (data)
+ if (data) {
break;
- else if (file->f_flags & O_NONBLOCK) {
+ } else if (file->f_flags & O_NONBLOCK) {
retval = -EAGAIN;
goto out;
} else if (signal_pending(current)) {
@@ -987,7 +987,8 @@ static acpi_status hpet_resources(struct acpi_resource *res, void *data)
break;
irq = acpi_register_gsi(NULL, irqp->interrupts[i],
- irqp->triggering, irqp->polarity);
+ irqp->triggering,
+ irqp->polarity);
if (irq < 0)
return AE_ERROR;
--
2.10.2
[toc] | [prev] | [next] | [standalone]
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2017-04-04 05:50 +0200 |
| Subject | Re: [PATCH v2 6/6] hpet: fix style issue about braces and alignment |
| Message-ID | <tsnDH-7L4-11@gated-at.bofh.it> |
| In reply to | #1615150 |
On Mon, 2017-04-03 at 14:15 +0200, Corentin Labbe wrote:
> This patch fix all style issue for braces and alignment
[]
> diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
[]
> @@ -255,9 +255,9 @@ static int hpet_open(struct inode *inode, struct file *file)
>
> for (devp = NULL, hpetp = hpets; hpetp && !devp; hpetp = hpetp->hp_next)
> for (i = 0; i < hpetp->hp_ntimer; i++)
> - if (hpetp->hp_dev[i].hd_flags & HPET_OPEN)
> + if (hpetp->hp_dev[i].hd_flags & HPET_OPEN) {
> continue;
> - else {
> + } else {
> devp = &hpetp->hp_dev[i];
> break;
> }
Perhaps this is clearer as:
for (devp = NULL, hpetp = hpets; hpetp && !devp; hpetp = hpetp->hp_next) {
for (i = 0; i < hpetp->hp_ntimer; i++) {
if (!(hpetp->hp_dev[i].hd_flags & HPET_OPEN)) {
devp = &hpetp->hp_dev[i];
break;
}
}
}
> @@ -304,9 +304,9 @@ hpet_read(struct file *file, char __user *buf, size_t count, loff_t *ppos)
> devp->hd_irqdata = 0;
> spin_unlock_irq(&hpet_lock);
>
> - if (data)
> + if (data) {
> break;
> - else if (file->f_flags & O_NONBLOCK) {
> + } else if (file->f_flags & O_NONBLOCK) {
break; else is almost always better as break
and reduced indentation
[toc] | [prev] | [next] | [standalone]
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 4/6] hpet: replace printk by their pr_xxx counterparts |
| Message-ID | <ts97J-6L2-31@gated-at.bofh.it> |
| In reply to | #1615142 |
This patch replace all printk by their pr_xxx counterparts.
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
drivers/char/hpet.c | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index 7a35739..59e89e5 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -491,7 +491,7 @@ static int hpet_ioctl_ieon(struct hpet_dev *devp)
irq_flags = devp->hd_flags & HPET_SHARED_IRQ ? IRQF_SHARED : 0;
if (request_irq(irq, hpet_interrupt, irq_flags,
devp->hd_name, (void *)devp)) {
- printk(KERN_ERR "hpet: IRQ %d is not free\n", irq);
+ pr_err("hpet: IRQ %d is not free\n", irq);
irq = 0;
}
}
@@ -841,8 +841,7 @@ int hpet_alloc(struct hpet_data *hdp)
* ACPI has also reported, then we catch it here.
*/
if (hpet_is_known(hdp)) {
- printk(KERN_DEBUG "%s: duplicate HPET ignored\n",
- __func__);
+ pr_debug("%s: duplicate HPET ignored\n", __func__);
return 0;
}
@@ -870,8 +869,7 @@ int hpet_alloc(struct hpet_data *hdp)
ntimer = ((cap & HPET_NUM_TIM_CAP_MASK) >> HPET_NUM_TIM_CAP_SHIFT) + 1;
if (hpetp->hp_ntimer != ntimer) {
- printk(KERN_WARNING "hpet: number irqs doesn't agree"
- " with number of timers\n");
+ pr_warn("hpet: number irqs doesn't agree with number of timers\n");
kfree(hpetp);
return -ENODEV;
}
@@ -890,7 +888,7 @@ int hpet_alloc(struct hpet_data *hdp)
do_div(temp, period);
hpetp->hp_tick_freq = temp; /* ticks per second */
- printk(KERN_INFO "hpet%d: at MMIO 0x%lx, IRQ%s",
+ pr_info("hpet%d: at MMIO 0x%lx, IRQ%s",
hpetp->hp_which, hdp->hd_phys_address,
hpetp->hp_ntimer > 1 ? "s" : "");
for (i = 0; i < hpetp->hp_ntimer; i++)
@@ -899,8 +897,7 @@ int hpet_alloc(struct hpet_data *hdp)
temp = hpetp->hp_tick_freq;
remainder = do_div(temp, 1000000);
- printk(KERN_INFO
- "hpet%u: %u comparators, %d-bit %u.%06u MHz counter\n",
+ pr_info("hpet%u: %u comparators, %d-bit %u.%06u MHz counter\n",
hpetp->hp_which, hpetp->hp_ntimer,
cap & HPET_COUNTER_SIZE_MASK ? 64 : 32,
(unsigned)temp, remainder);
@@ -1020,7 +1017,7 @@ static int hpet_acpi_add(struct acpi_device *device)
if (!data.hd_address || !data.hd_nirqs) {
if (data.hd_address)
iounmap(data.hd_address);
- printk("%s: no address or irqs in _CRS\n", __func__);
+ pr_err("%s: no address or irqs in _CRS\n", __func__);
return -ENODEV;
}
--
2.10.2
[toc] | [prev] | [next] | [standalone]
| From | Joe Perches <joe@perches.com> |
|---|---|
| Date | 2017-04-03 21:50 +0200 |
| Subject | Re: [PATCH v2 4/6] hpet: replace printk by their pr_xxx counterparts |
| Message-ID | <tsg9b-2Mf-3@gated-at.bofh.it> |
| In reply to | #1615153 |
On Mon, 2017-04-03 at 14:15 +0200, Corentin Labbe wrote:
> This patch replace all printk by their pr_xxx counterparts.
All? There are others in this file no?
printk(KERN_CONT and printk(KERN_WARNING
And the conversion of
printk(KERN_DEBUG
to
pr_debug(
is not equivalent. printk(KERN_DEBUG is always emitted.
pr_debug is only emitted with #define DEBUG or CONFIG_DYNAMIC_DEBUG
and a specific enabling of the line.
> Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
> ---
> drivers/char/hpet.c | 15 ++++++---------
> 1 file changed, 6 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
> index 7a35739..59e89e5 100644
> --- a/drivers/char/hpet.c
> +++ b/drivers/char/hpet.c
> @@ -491,7 +491,7 @@ static int hpet_ioctl_ieon(struct hpet_dev *devp)
> irq_flags = devp->hd_flags & HPET_SHARED_IRQ ? IRQF_SHARED : 0;
> if (request_irq(irq, hpet_interrupt, irq_flags,
> devp->hd_name, (void *)devp)) {
> - printk(KERN_ERR "hpet: IRQ %d is not free\n", irq);
> + pr_err("hpet: IRQ %d is not free\n", irq);
> irq = 0;
> }
> }
> @@ -841,8 +841,7 @@ int hpet_alloc(struct hpet_data *hdp)
> * ACPI has also reported, then we catch it here.
> */
> if (hpet_is_known(hdp)) {
> - printk(KERN_DEBUG "%s: duplicate HPET ignored\n",
> - __func__);
> + pr_debug("%s: duplicate HPET ignored\n", __func__);
> return 0;
> }
>
> @@ -870,8 +869,7 @@ int hpet_alloc(struct hpet_data *hdp)
> ntimer = ((cap & HPET_NUM_TIM_CAP_MASK) >> HPET_NUM_TIM_CAP_SHIFT) + 1;
>
> if (hpetp->hp_ntimer != ntimer) {
> - printk(KERN_WARNING "hpet: number irqs doesn't agree"
> - " with number of timers\n");
> + pr_warn("hpet: number irqs doesn't agree with number of timers\n");
> kfree(hpetp);
> return -ENODEV;
> }
> @@ -890,7 +888,7 @@ int hpet_alloc(struct hpet_data *hdp)
> do_div(temp, period);
> hpetp->hp_tick_freq = temp; /* ticks per second */
>
> - printk(KERN_INFO "hpet%d: at MMIO 0x%lx, IRQ%s",
> + pr_info("hpet%d: at MMIO 0x%lx, IRQ%s",
> hpetp->hp_which, hdp->hd_phys_address,
> hpetp->hp_ntimer > 1 ? "s" : "");
> for (i = 0; i < hpetp->hp_ntimer; i++)
> @@ -899,8 +897,7 @@ int hpet_alloc(struct hpet_data *hdp)
>
> temp = hpetp->hp_tick_freq;
> remainder = do_div(temp, 1000000);
> - printk(KERN_INFO
> - "hpet%u: %u comparators, %d-bit %u.%06u MHz counter\n",
> + pr_info("hpet%u: %u comparators, %d-bit %u.%06u MHz counter\n",
> hpetp->hp_which, hpetp->hp_ntimer,
> cap & HPET_COUNTER_SIZE_MASK ? 64 : 32,
> (unsigned)temp, remainder);
> @@ -1020,7 +1017,7 @@ static int hpet_acpi_add(struct acpi_device *device)
> if (!data.hd_address || !data.hd_nirqs) {
> if (data.hd_address)
> iounmap(data.hd_address);
> - printk("%s: no address or irqs in _CRS\n", __func__);
> + pr_err("%s: no address or irqs in _CRS\n", __func__);
> return -ENODEV;
> }
>
[toc] | [prev] | [next] | [standalone]
| From | Corentin Labbe <clabbe.montjoie@gmail.com> |
|---|---|
| Date | 2017-04-03 14:20 +0200 |
| Subject | [PATCH v2 3/6] hpet: fix checkpatch complains about spaces |
| Message-ID | <ts97J-6L2-41@gated-at.bofh.it> |
| In reply to | #1615142 |
This patch make checkpatch happy for spaces.
Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
---
drivers/char/hpet.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/char/hpet.c b/drivers/char/hpet.c
index 206d3a6..7a35739 100644
--- a/drivers/char/hpet.c
+++ b/drivers/char/hpet.c
@@ -51,7 +51,6 @@
#define HPET_RANGE_SIZE 1024 /* from HPET spec */
-
/* WARNING -- don't get confused. These macros are never used
* to write the (single) counter, and rarely to read it.
* They're badly named; to fix, someday.
@@ -83,6 +82,7 @@ static struct clocksource clocksource_hpet = {
.mask = CLOCKSOURCE_MASK(64),
.flags = CLOCK_SOURCE_IS_CONTINUOUS,
};
+
static struct clocksource *hpet_clocksource;
#endif
@@ -281,7 +281,7 @@ static int hpet_open(struct inode *inode, struct file *file)
}
static ssize_t
-hpet_read(struct file *file, char __user *buf, size_t count, loff_t * ppos)
+hpet_read(struct file *file, char __user *buf, size_t count, loff_t *ppos)
{
DECLARE_WAITQUEUE(wait, current);
unsigned long data;
@@ -327,7 +327,7 @@ hpet_read(struct file *file, char __user *buf, size_t count, loff_t * ppos)
return retval;
}
-static unsigned int hpet_poll(struct file *file, poll_table * wait)
+static unsigned int hpet_poll(struct file *file, poll_table *wait)
{
unsigned long v;
struct hpet_dev *devp;
@@ -687,6 +687,7 @@ hpet_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
if ((cmd == HPET_INFO) && !err) {
struct compat_hpet_info __user *u = compat_ptr(arg);
+
if (put_user(info.hi_ireqfreq, &u->hi_ireqfreq) ||
put_user(info.hi_flags, &u->hi_flags) ||
put_user(info.hi_hpet, &u->hi_hpet) ||
@@ -902,7 +903,7 @@ int hpet_alloc(struct hpet_data *hdp)
"hpet%u: %u comparators, %d-bit %u.%06u MHz counter\n",
hpetp->hp_which, hpetp->hp_ntimer,
cap & HPET_COUNTER_SIZE_MASK ? 64 : 32,
- (unsigned) temp, remainder);
+ (unsigned)temp, remainder);
mcfg = readq(&hpet->hpet_config);
if ((mcfg & HPET_ENABLE_CNF_MASK) == 0) {
--
2.10.2
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web