diff options
| author | Ingo Molnar <mingo@kernel.org> | 2018-10-29 07:20:52 +0100 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2018-10-29 07:20:52 +0100 |
| commit | f0718d792b8a6d4b5ddc929e418ac57cc4897375 (patch) | |
| tree | 3dbaa824ce380e99709fae47c047383ca39c983a /include/linux/string.h | |
| parent | efe8eaf7b525f1be26fe20d723d2bfbfcd7455fd (diff) | |
| parent | b59dfdaef173677b0b7e10f375226c0a1114fd20 (diff) | |
Merge branch 'linus' into perf/urgent, to pick up fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/string.h')
| -rw-r--r-- | include/linux/string.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/string.h b/include/linux/string.h index 4a5a0eb7df51..27d0482e5e05 100644 --- a/include/linux/string.h +++ b/include/linux/string.h @@ -131,6 +131,13 @@ static inline void *memset_p(void **p, void *v, __kernel_size_t n) return memset64((uint64_t *)p, (uintptr_t)v, n); } +extern void **__memcat_p(void **a, void **b); +#define memcat_p(a, b) ({ \ + BUILD_BUG_ON_MSG(!__same_type(*(a), *(b)), \ + "type mismatch in memcat_p()"); \ + (typeof(*a) *)__memcat_p((void **)(a), (void **)(b)); \ +}) + #ifndef __HAVE_ARCH_MEMCPY extern void * memcpy(void *,const void *,__kernel_size_t); #endif |
