diff options
author | Chris Wright <chrisw@sous-sol.org> | 2006-01-31 19:10:23 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-31 19:30:25 -0800 |
commit | bd3f8f2b12bcf4ea25c89b84adeaafad232662c8 (patch) | |
tree | 1fa8f8b784b5d47191a5dea07042ccbe0c1fd745 /include/linux/time.h | |
parent | 078a9b0388619c6c4c347458c6861833b911313b (diff) | |
download | op-kernel-dev-bd3f8f2b12bcf4ea25c89b84adeaafad232662c8.zip op-kernel-dev-bd3f8f2b12bcf4ea25c89b84adeaafad232662c8.tar.gz |
[PATCH] Make sure to always check upper bits of tv_nsec in timespec_valid.
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/linux/time.h')
-rw-r--r-- | include/linux/time.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/time.h b/include/linux/time.h index 614dd84..7b4dc365 100644 --- a/include/linux/time.h +++ b/include/linux/time.h @@ -48,7 +48,7 @@ extern void set_normalized_timespec(struct timespec *ts, time_t sec, long nsec); * Returns true if the timespec is norm, false if denorm: */ #define timespec_valid(ts) \ - (((ts)->tv_sec >= 0) && (((unsigned) (ts)->tv_nsec) < NSEC_PER_SEC)) + (((ts)->tv_sec >= 0) && (((unsigned long) (ts)->tv_nsec) < NSEC_PER_SEC)) /* * 64-bit nanosec type. Large enough to span 292+ years in nanosecond |