summaryrefslogtreecommitdiff
path: root/drivers/staging/speakup
diff options
context:
space:
mode:
authorRobin Schroer <sulamiification@gmail.com>2014-06-13 01:17:30 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-06-19 17:12:01 -0700
commit3d3cb1bffde15ee6e69532457bee20b5d424952b (patch)
tree506545aea046ff1d47bf0cfeebedf172fd643552 /drivers/staging/speakup
parentc7f268df3f4e80513271aea8e91f3fd0701aae1b (diff)
drivers/staging/speakup/main: fixed jiffie comparison
speakup_key() used manual comparison of jiffies to determine the time since the last keypress, replaced it with time_after() Signed-off-by: Robin Schroer <sulamiification@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/speakup')
-rw-r--r--drivers/staging/speakup/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/speakup/main.c b/drivers/staging/speakup/main.c
index 7de79d59a4cd..0cd3cdba8644 100644
--- a/drivers/staging/speakup/main.c
+++ b/drivers/staging/speakup/main.c
@@ -2067,7 +2067,7 @@ speakup_key(struct vc_data *vc, int shift_state, int keycode, u_short keysym,
if (up_flag)
goto out;
if (last_keycode == keycode &&
- last_spk_jiffy + MAX_DELAY > jiffies) {
+ time_after(last_spk_jiffy + MAX_DELAY, jiffies)) {
spk_close_press = 1;
offset = spk_shift_table[shift_info + 32];
/* double press? */