diff options
| -rw-r--r-- | drivers/input/serio/i8042.c | 7 | ||||
| -rw-r--r-- | drivers/input/serio/serio.c | 7 |
2 files changed, 8 insertions, 6 deletions
diff --git a/drivers/input/serio/i8042.c b/drivers/input/serio/i8042.c index f919bf57293c..582245c497eb 100644 --- a/drivers/input/serio/i8042.c +++ b/drivers/input/serio/i8042.c | |||
| @@ -934,10 +934,11 @@ static bool i8042_suspended; | |||
| 934 | 934 | ||
| 935 | static int i8042_suspend(struct platform_device *dev, pm_message_t state) | 935 | static int i8042_suspend(struct platform_device *dev, pm_message_t state) |
| 936 | { | 936 | { |
| 937 | if (!i8042_suspended && state.event == PM_EVENT_SUSPEND) { | 937 | if (!i8042_suspended && state.event == PM_EVENT_SUSPEND) |
| 938 | i8042_controller_reset(); | 938 | i8042_controller_reset(); |
| 939 | i8042_suspended = true; | 939 | |
| 940 | } | 940 | i8042_suspended = state.event == PM_EVENT_SUSPEND || |
| 941 | state.event == PM_EVENT_FREEZE; | ||
| 941 | 942 | ||
| 942 | return 0; | 943 | return 0; |
| 943 | } | 944 | } |
diff --git a/drivers/input/serio/serio.c b/drivers/input/serio/serio.c index fb17573f8f2d..d66f4944f2a0 100644 --- a/drivers/input/serio/serio.c +++ b/drivers/input/serio/serio.c | |||
| @@ -935,10 +935,11 @@ static int serio_suspend(struct device *dev, pm_message_t state) | |||
| 935 | { | 935 | { |
| 936 | struct serio *serio = to_serio_port(dev); | 936 | struct serio *serio = to_serio_port(dev); |
| 937 | 937 | ||
| 938 | if (!serio->suspended && state.event == PM_EVENT_SUSPEND) { | 938 | if (!serio->suspended && state.event == PM_EVENT_SUSPEND) |
| 939 | serio_cleanup(serio); | 939 | serio_cleanup(serio); |
| 940 | serio->suspended = true; | 940 | |
| 941 | } | 941 | serio->suspended = state.event == PM_EVENT_SUSPEND || |
| 942 | state.event == PM_EVENT_FREEZE; | ||
| 942 | 943 | ||
| 943 | return 0; | 944 | return 0; |
| 944 | } | 945 | } |
