Skip to contentSkip to conversation

input : wacom - Cleanup a return value for the old Bamboo

PATCH Applied Ping Cheng 4 participants 4 messages Jul 5, 2011 – Jul 7, 2011

Subsystems (2)
lore
Share & tools
lore

Ping Cheng

author
#0 lore raw

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

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.

---
 drivers/input/tablet/wacom_wac.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/input/tablet/wacom_wac.c +1 -1
index 19554a4..03ebcc8 100644
@@ -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:
Signature · 1 line
1.7.5.4
Reviewed-by on v2 3/3
#1 lore raw
Quoted 3 lines · Ping Cheng

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.

Quoted 23 lines

---
 drivers/input/tablet/wacom_wac.c |    2 +-

 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/input/tablet/wacom_wac.c +1 -1
index 19554a4..03ebcc8 100644
@@ -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

Quoted 5 lines

--
To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to [email protected]
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 [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Reviewed-by
#2 lore raw
Quoted 8 lines · Chris Bagwell
Quoted 3 lines · Ping Cheng

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.

The sync will not even reach userland, but the patch wont hurt. For all patches in the set:

Thanks Ping, thanks Chris.

Henrik

maintainer Applied
#3 lore raw
Quoted 8 lines · Henrik Rydberg
Quoted 7 lines · Chris Bagwell
Quoted 3 lines · Ping Cheng

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.

Quoted 9 lines
Quoted 1 line

The sync will not even reach userland, but the patch wont hurt. For all patches in the set:

Thanks Ping, thanks Chris.

Applied all 4, thanks everyone.

Signature · 1 line
Dmitry