diff options
author | Mariusz Skamra <mariuszx.skamra@intel.com> | 2017-05-26 12:15:59 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-06-03 11:08:04 +0200 |
commit | fa72e6afa795dbb35d0cc6332606e83e4415e45e (patch) | |
tree | 53092ad9c42474e38982c96adb4b12b2abe5a26a /drivers/usb/host/fotg210-hcd.c | |
parent | usb: typec: Add a sysfs node to manage port type (diff) | |
download | linux-fa72e6afa795dbb35d0cc6332606e83e4415e45e.tar.xz linux-fa72e6afa795dbb35d0cc6332606e83e4415e45e.zip |
usb: Make use of ktime_* comparison functions
Start using ktime_* compare functions to make the code backportable.
Now that may be a bit tricky due to recent change of ktime_t.
Signed-off-by: Mariusz Skamra <mariuszx.skamra@intel.com>
Acked-by: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@intel.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host/fotg210-hcd.c')
-rw-r--r-- | drivers/usb/host/fotg210-hcd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/host/fotg210-hcd.c b/drivers/usb/host/fotg210-hcd.c index ced08dc229ad..457cc6525abd 100644 --- a/drivers/usb/host/fotg210-hcd.c +++ b/drivers/usb/host/fotg210-hcd.c @@ -1380,7 +1380,7 @@ static enum hrtimer_restart fotg210_hrtimer_func(struct hrtimer *t) */ now = ktime_get(); for_each_set_bit(e, &events, FOTG210_HRTIMER_NUM_EVENTS) { - if (now >= fotg210->hr_timeouts[e]) + if (ktime_compare(now, fotg210->hr_timeouts[e]) >= 0) event_handlers[e](fotg210); else fotg210_enable_event(fotg210, e, false); |