#include <asm/timex.h>
#include <asm/io.h>
+#include <linux/mt_sched_mon.h>
+
#define CREATE_TRACE_POINTS
#include <trace/events/timer.h>
/* now that we have rounded, subtract the extra skew again */
j -= cpu * 3;
- if (j <= jiffies) /* rounding ate our timeout entirely; */
- return original;
- return j;
+ /*
+ * Make sure j is still in the future. Otherwise return the
+ * unmodified value.
+ */
+ return time_is_after_jiffies(j) ? j : original;
}
/**
bit = find_last_bit(&mask, BITS_PER_LONG);
- mask = (1 << bit) - 1;
+ mask = (1UL << bit) - 1;
expires_limit = expires_limit & ~(mask);
lock_map_acquire(&lockdep_map);
trace_timer_expire_entry(timer);
+ mt_trace_sft_start(fn);
fn(data);
+ mt_trace_sft_end(fn);
trace_timer_expire_exit(timer);
lock_map_release(&lockdep_map);