diff options
author | Texas Instruments Auto Merger <lcpd_integration@list.ti.com> | 2015-01-29 20:12:15 -0600 |
---|---|---|
committer | Texas Instruments Auto Merger <lcpd_integration@list.ti.com> | 2015-01-29 20:12:15 -0600 |
commit | e9edf40c6f6cb39d7fe92da46c4b37c3e3ba32f6 (patch) | |
tree | aa89d744151bd9359a0a55b9b05c3d64d84f5ade /include/linux/time.h | |
parent | d298c0aeede322df16c97226784dba6e3ef66504 (diff) | |
parent | 016ea480c9ca2344006d3ef592a0154ba03b507a (diff) |
Merge tag 'v3.14.31' of http://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable into ti-linux-3.14.y
This is the 3.14.31 stable release
* tag 'v3.14.31' of http://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable: (77 commits)
Linux 3.14.31
md/raid5: fetch_block must fetch all the blocks handle_stripe_dirtying wants.
mm: get rid of radix tree gfp mask for pagecache_get_page
mm: page_alloc: reduce cost of the fair zone allocation policy
mm: page_alloc: abort fair zone allocation policy when remotes nodes are encountered
mm: vmscan: only update per-cpu thresholds for online CPU
mm: move zone->pages_scanned into a vmstat counter
mm: rearrange zone fields into read-only, page alloc, statistics and page reclaim lines
mm: pagemap: avoid unnecessary overhead when tracepoints are deactivated
memcg, vmscan: Fix forced scan of anonymous pages
vmalloc: use rcu list iterator to reduce vmap_area_lock contention
mm: make copy_pte_range static again
mm, thp: only collapse hugepages to nodes with affinity for zone_reclaim_mode
mm/memory.c: use entry = ACCESS_ONCE(*pte) in handle_pte_fault()
shmem: fix init_page_accessed use to stop !PageLRU bug
mm: avoid unnecessary atomic operations during end_page_writeback()
mm: non-atomically mark page accessed during page cache allocation where possible
fs: buffer: do not use unnecessary atomic operations when discarding buffers
mm: do not use unnecessary atomic operations when adding pages to the LRU
mm: do not use atomic operations when releasing pages
...
Signed-off-by: Texas Instruments Auto Merger <lcpd_integration@list.ti.com>
Diffstat (limited to 'include/linux/time.h')
-rw-r--r-- | include/linux/time.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/linux/time.h b/include/linux/time.h index d5d229b2e5a..7d532a32ff3 100644 --- a/include/linux/time.h +++ b/include/linux/time.h @@ -173,6 +173,19 @@ extern void getboottime(struct timespec *ts); extern void monotonic_to_bootbased(struct timespec *ts); extern void get_monotonic_boottime(struct timespec *ts); +static inline bool timeval_valid(const struct timeval *tv) +{ + /* Dates before 1970 are bogus */ + if (tv->tv_sec < 0) + return false; + + /* Can't have more microseconds then a second */ + if (tv->tv_usec < 0 || tv->tv_usec >= USEC_PER_SEC) + return false; + + return true; +} + extern struct timespec timespec_trunc(struct timespec t, unsigned gran); extern int timekeeping_valid_for_hres(void); extern u64 timekeeping_max_deferment(void); |