[PATCH 3/3 v2] input : wacom - Cleanup a return value for the old Bamboo

Subsystems: input (keyboard, mouse, joystick, touchscreen) drivers, the rest

STALE5537d

4 messages, 4 authors, 2011-07-07 · open the first message on its own page

[PATCH 3/3 v2] input : wacom - Cleanup a return value for the old Bamboo

From: Ping Cheng <hidden>
Date: 2011-07-05 23:24:28

The old code may call input_sync without sending any other events.
Although the sync event will be ignored in the userland, eliminating
unnecessary kernel events is the right way to go.

Signed-off-by: Ping Cheng <redacted>
---
 drivers/input/tablet/wacom_wac.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
index 19554a4..03ebcc8 100644
--- a/drivers/input/tablet/wacom_wac.c
+++ b/drivers/input/tablet/wacom_wac.c
@@ -300,8 +300,8 @@ static int wacom_graphire_irq(struct wacom_wac *wacom)
 				wacom->id[1] = 0;
 			input_report_abs(input, ABS_MISC, wacom->id[1]);
 			input_event(input, EV_MSC, MSC_SERIAL, 0xf0);
+			retval = 1;
 		}
-		retval = 1;
 		break;
 	}
 exit:
-- 
1.7.5.4

Re: [PATCH 3/3 v2] input : wacom - Cleanup a return value for the old Bamboo

From: Chris Bagwell <hidden>
Date: 2011-07-06 02:34:09

On Tue, Jul 5, 2011 at 6:26 PM, Ping Cheng [off-list ref] wrote:
The old code may call input_sync without sending any other events.
Although the sync event will be ignored in the userland, eliminating
unnecessary kernel events is the right way to go.
Aligns the code block with previous case statement as well.

Reviewed-by: Chris Bagwell <redacted>
quoted hunk
Signed-off-by: Ping Cheng <redacted>
---
 drivers/input/tablet/wacom_wac.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/input/tablet/wacom_wac.c b/drivers/input/tablet/wacom_wac.c
index 19554a4..03ebcc8 100644
--- a/drivers/input/tablet/wacom_wac.c
+++ b/drivers/input/tablet/wacom_wac.c
@@ -300,8 +300,8 @@ static int wacom_graphire_irq(struct wacom_wac *wacom)
                               wacom->id[1] = 0;
                       input_report_abs(input, ABS_MISC, wacom->id[1]);
                       input_event(input, EV_MSC, MSC_SERIAL, 0xf0);
+                       retval = 1;
               }
-               retval = 1;
               break;
       }
 exit:
--
1.7.5.4

--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Re: [PATCH 3/3 v2] input : wacom - Cleanup a return value for the old Bamboo

From: Henrik Rydberg <hidden>
Date: 2011-07-06 05:50:15

On Tue, Jul 05, 2011 at 09:34:08PM -0500, Chris Bagwell wrote:
On Tue, Jul 5, 2011 at 6:26 PM, Ping Cheng [off-list ref] wrote:
quoted
The old code may call input_sync without sending any other events.
Although the sync event will be ignored in the userland, eliminating
unnecessary kernel events is the right way to go.
Aligns the code block with previous case statement as well.

Reviewed-by: Chris Bagwell <redacted>
The sync will not even reach userland, but the patch wont hurt. For
all patches in the set:

    Reviewed-by: Henrik Rydberg [off-list ref]

Thanks Ping, thanks Chris.

Henrik

Re: [PATCH 3/3 v2] input : wacom - Cleanup a return value for the old Bamboo

From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Date: 2011-07-07 05:20:00

On Wed, Jul 06, 2011 at 07:52:09AM +0200, Henrik Rydberg wrote:
On Tue, Jul 05, 2011 at 09:34:08PM -0500, Chris Bagwell wrote:
quoted
On Tue, Jul 5, 2011 at 6:26 PM, Ping Cheng [off-list ref] wrote:
quoted
The old code may call input_sync without sending any other events.
Although the sync event will be ignored in the userland, eliminating
unnecessary kernel events is the right way to go.
Aligns the code block with previous case statement as well.

Reviewed-by: Chris Bagwell <redacted>
The sync will not even reach userland, but the patch wont hurt. For
all patches in the set:

    Reviewed-by: Henrik Rydberg [off-list ref]

Thanks Ping, thanks Chris.
Applied all 4, thanks everyone.

-- 
Dmitry
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help