Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c3a01ba9 authored by Dmitry Torokhov's avatar Dmitry Torokhov
Browse files

Input: penmount - simplify unregister procedure



Since touchscreen driver does not handle any events to be sent to the
device we can close serio port first and then unregister the input device.

Tested-by: default avatarJohn Sung <penmount.touch@gmail.com>
Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
parent 98b013eb
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -183,12 +183,12 @@ static void pm_disconnect(struct serio *serio)
{
	struct pm *pm = serio_get_drvdata(serio);

	input_get_device(pm->dev);
	input_unregister_device(pm->dev);
	serio_close(serio);
	serio_set_drvdata(serio, NULL);
	input_put_device(pm->dev);

	input_unregister_device(pm->dev);
	kfree(pm);

	serio_set_drvdata(serio, NULL);
}

/*