diff options
author | Dmitry Shmidt <dimitrysh@google.com> | 2016-09-07 14:37:52 -0700 |
---|---|---|
committer | Dmitry Shmidt <dimitrysh@google.com> | 2016-09-07 14:37:52 -0700 |
commit | cade80573cf8a76e46a95f8a714dd264c67bcb96 (patch) | |
tree | 7e7b236076db5b9f6630a3269d5cdc02a2adfb08 /include/linux/thread_info.h | |
parent | 5c0fc54c9b67e04d533b5ebec718d37f747a9170 (diff) | |
parent | 6b93f8214eabf0f363eab5283c2ad18b5bc33135 (diff) |
Merge remote-tracking branch 'common/android-4.4' into android-4.4.y
Diffstat (limited to 'include/linux/thread_info.h')
-rw-r--r-- | include/linux/thread_info.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/include/linux/thread_info.h b/include/linux/thread_info.h index ff307b548ed3..0ae29ff9ccfd 100644 --- a/include/linux/thread_info.h +++ b/include/linux/thread_info.h @@ -145,6 +145,30 @@ static inline bool test_and_clear_restore_sigmask(void) #error "no set_restore_sigmask() provided and default one won't work" #endif +#ifndef CONFIG_HAVE_ARCH_WITHIN_STACK_FRAMES +static inline int arch_within_stack_frames(const void * const stack, + const void * const stackend, + const void *obj, unsigned long len) +{ + return 0; +} +#endif + +#ifdef CONFIG_HARDENED_USERCOPY +extern void __check_object_size(const void *ptr, unsigned long n, + bool to_user); + +static inline void check_object_size(const void *ptr, unsigned long n, + bool to_user) +{ + __check_object_size(ptr, n, to_user); +} +#else +static inline void check_object_size(const void *ptr, unsigned long n, + bool to_user) +{ } +#endif /* CONFIG_HARDENED_USERCOPY */ + #endif /* __KERNEL__ */ #endif /* _LINUX_THREAD_INFO_H */ |