[bootlin/training-materials updates] master: Kernel input lab: use input_report_key() instead of input_event() (9557dae1)

Michael Opdenacker michael.opdenacker at bootlin.com
Thu Apr 29 12:56:39 CEST 2021


Repository : https://github.com/bootlin/training-materials
On branch  : master
Link       : https://github.com/bootlin/training-materials/commit/9557dae1d27f1e62584aec55e85b2b2b7b64c1a0

>---------------------------------------------------------------

commit 9557dae1d27f1e62584aec55e85b2b2b7b64c1a0
Author: Michael Opdenacker <michael.opdenacker at bootlin.com>
Date:   Thu Apr 29 12:55:20 2021 +0200

    Kernel input lab: use input_report_key() instead of input_event()
    
    As recommended in the slides
    
    Signed-off-by: Michael Opdenacker <michael.opdenacker at bootlin.com>
    Reported-by: Miquèl Raynal <miquel.raynal at bootlin.com>


>---------------------------------------------------------------

9557dae1d27f1e62584aec55e85b2b2b7b64c1a0
 labs/kernel-i2c-input-interface/input-notification.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/labs/kernel-i2c-input-interface/input-notification.c b/labs/kernel-i2c-input-interface/input-notification.c
index ffcccfa6..f02ddc5b 100644
--- a/labs/kernel-i2c-input-interface/input-notification.c
+++ b/labs/kernel-i2c-input-interface/input-notification.c
@@ -1,3 +1,3 @@
-input_event(input, EV_KEY, BTN_Z, zpressed);
-input_event(input, EV_KEY, BTN_C, cpressed);
+input_report_key(input, BTN_Z, zpressed);
+input_report_key(input, BTN_C, cpressed);
 input_sync(input);




More information about the training-materials-updates mailing list