aboutsummaryrefslogtreecommitdiffstats
path: root/mm/sparse.c
diff options
context:
space:
mode:
authorJulia Lawall <[email protected]>2008-04-28 09:11:59 +0000
committerLinus Torvalds <[email protected]>2008-04-28 15:58:17 +0000
commitdca03a51549bc645685fb8a77efa64df531666c3 (patch)
tree558985a9c87d132de23719b6dfe49e2379a6e8e1 /mm/sparse.c
parentrtc: add the support for alarm time relative to current time in sysfs (diff)
downloadkernel-dca03a51549bc645685fb8a77efa64df531666c3.tar.gz
kernel-dca03a51549bc645685fb8a77efa64df531666c3.zip
drivers/char/rtc.c: use time_before, time_before_eq, etc
The functions time_before, time_before_eq, time_after, and time_after_eq are more robust for comparing jiffies against other values. A simplified version of the semantic patch making this change is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @ change_compare_np @ expression E; @@ ( - jiffies <= E + time_before_eq(jiffies,E) | - jiffies >= E + time_after_eq(jiffies,E) | - jiffies < E + time_before(jiffies,E) | - jiffies > E + time_after(jiffies,E) ) @ include depends on change_compare_np @ @@ #include <linux/jiffies.h> @ no_include depends on !include && change_compare_np @ @@ #include <linux/...> + #include <linux/jiffies.h> // </smpl> Signed-off-by: Julia Lawall <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Alessandro Zummo <[email protected]> Cc: David Brownell <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'mm/sparse.c')
0 files changed, 0 insertions, 0 deletions