diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2016-09-23 15:57:16 +0300 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2016-09-23 15:57:16 +0300 |
commit | 0565f49cfe937640c2347f6d7f40ad2f4e4f088b (patch) | |
tree | 6067447df39c37946bc2de3ee004f45957bf123e /include/linux/compiler.h | |
parent | ccf1e9e1c0072088420aad42797986d6e74366b5 (diff) | |
parent | 9395452b4aab7bc2475ef8935b4a4fb99d778d70 (diff) | |
download | linux-0565f49cfe937640c2347f6d7f40ad2f4e4f088b.tar.xz |
Merge tag 'v4.8-rc6' into devel
Linux 4.8-rc6
Diffstat (limited to 'include/linux/compiler.h')
-rw-r--r-- | include/linux/compiler.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/compiler.h b/include/linux/compiler.h index 1bb954842725..436aa4e42221 100644 --- a/include/linux/compiler.h +++ b/include/linux/compiler.h @@ -527,13 +527,13 @@ static __always_inline void __write_once_size(volatile void *p, void *res, int s * object's lifetime is managed by something other than RCU. That * "something other" might be reference counting or simple immortality. * - * The seemingly unused void * variable is to validate @p is indeed a pointer - * type. All pointer types silently cast to void *. + * The seemingly unused size_t variable is to validate @p is indeed a pointer + * type by making sure it can be dereferenced. */ #define lockless_dereference(p) \ ({ \ typeof(p) _________p1 = READ_ONCE(p); \ - __maybe_unused const void * const _________p2 = _________p1; \ + size_t __maybe_unused __size_of_ptr = sizeof(*(p)); \ smp_read_barrier_depends(); /* Dependency order vs. p above. */ \ (_________p1); \ }) |