Commit 9902747e authored by Thomas Gleixner's avatar Thomas Gleixner

Revert "ktime: Simplify ktime_compare implementation"

Thierry bisected boot failures to this simplification commit.

Reverts: 3f1d4720 ("ktime: Simplify ktime_compare implementation")
Reported-by: default avatarThierry Reding <thierry.reding@gmail.com>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Cc: Mariusz Skamra <mariuszx.skamra@intel.com>
parent b7dcc4ea
......@@ -108,7 +108,11 @@ static inline ktime_t timeval_to_ktime(struct timeval tv)
*/
static inline int ktime_compare(const ktime_t cmp1, const ktime_t cmp2)
{
return ktime_sub(cmp1, cmp2);
if (cmp1 < cmp2)
return -1;
if (cmp1 > cmp2)
return 1;
return 0;
}
/**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment