diff options
author | Len Brown <len.brown@intel.com> | 2005-12-06 17:31:30 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2005-12-06 17:31:30 -0500 |
commit | 3d5271f9883cba7b54762bc4fe027d4172f06db7 (patch) | |
tree | ab8a881a14478598a0c8bda0d26c62cdccfffd6d /include/linux/timex.h | |
parent | 378b2556f4e09fa6f87ff0cb5c4395ff28257d02 (diff) | |
parent | 9115a6c787596e687df03010d97fccc5e0762506 (diff) |
Pull release into acpica branch
Diffstat (limited to 'include/linux/timex.h')
-rw-r--r-- | include/linux/timex.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/timex.h b/include/linux/timex.h index 7e050a2cc35b..04a4a8cb4ed3 100644 --- a/include/linux/timex.h +++ b/include/linux/timex.h | |||
@@ -282,6 +282,13 @@ static inline int ntp_synced(void) | |||
282 | return !(time_status & STA_UNSYNC); | 282 | return !(time_status & STA_UNSYNC); |
283 | } | 283 | } |
284 | 284 | ||
285 | /* Required to safely shift negative values */ | ||
286 | #define shift_right(x, s) ({ \ | ||
287 | __typeof__(x) __x = (x); \ | ||
288 | __typeof__(s) __s = (s); \ | ||
289 | __x < 0 ? -(-__x >> __s) : __x >> __s; \ | ||
290 | }) | ||
291 | |||
285 | 292 | ||
286 | #ifdef CONFIG_TIME_INTERPOLATION | 293 | #ifdef CONFIG_TIME_INTERPOLATION |
287 | 294 | ||