]> Git Repo - linux.git/blobdiff - include/linux/compiler_types.h
Merge branch 'slab/for-6.1/slub_validation_locking' into slab/for-next
[linux.git] / include / linux / compiler_types.h
index 4f2a819fd60a34ca40067bdc2ceecf68578f893a..0717534f8364cc353745849350884dbf54241f00 100644 (file)
@@ -271,14 +271,16 @@ struct ftrace_likely_data {
 
 /*
  * Any place that could be marked with the "alloc_size" attribute is also
- * a place to be marked with the "malloc" attribute. Do this as part of the
- * __alloc_size macro to avoid redundant attributes and to avoid missing a
- * __malloc marking.
+ * a place to be marked with the "malloc" attribute, except those that may
+ * be performing a _reallocation_, as that may alias the existing pointer.
+ * For these, use __realloc_size().
  */
 #ifdef __alloc_size__
 # define __alloc_size(x, ...)  __alloc_size__(x, ## __VA_ARGS__) __malloc
+# define __realloc_size(x, ...)        __alloc_size__(x, ## __VA_ARGS__)
 #else
 # define __alloc_size(x, ...)  __malloc
+# define __realloc_size(x, ...)
 #endif
 
 #ifndef asm_volatile_goto
This page took 0.034683 seconds and 4 git commands to generate.