aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/flex_array.h
diff options
context:
space:
mode:
authorEric Paris <eparis@redhat.com>2010-11-29 15:47:09 -0500
committerEric Paris <eparis@redhat.com>2010-11-30 17:28:57 -0500
commitc41ab6a1b9028de33e74101cb0aae13098a56fdb (patch)
treef56d5af7c2743623018b04b14cc4f47895c3bb3e /include/linux/flex_array.h
parentc9e86a9b95f198d7df49b25fcd808ee39cba218f (diff)
flex_array: fix flex_array_put_ptr macro to be valid C
Using flex_array_put_ptr() results in a compile error "error: lvalue required as unary ‘&’ operand" fix the casting order to fix this. Signed-off-by: Eric Paris <eparis@redhat.com>
Diffstat (limited to 'include/linux/flex_array.h')
-rw-r--r--include/linux/flex_array.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/flex_array.h b/include/linux/flex_array.h
index 631b77f2ac70..70e4efabe0fb 100644
--- a/include/linux/flex_array.h
+++ b/include/linux/flex_array.h
@@ -71,7 +71,7 @@ void *flex_array_get(struct flex_array *fa, unsigned int element_nr);
71int flex_array_shrink(struct flex_array *fa); 71int flex_array_shrink(struct flex_array *fa);
72 72
73#define flex_array_put_ptr(fa, nr, src, gfp) \ 73#define flex_array_put_ptr(fa, nr, src, gfp) \
74 flex_array_put(fa, nr, &(void *)(src), gfp) 74 flex_array_put(fa, nr, (void *)&(src), gfp)
75 75
76void *flex_array_get_ptr(struct flex_array *fa, unsigned int element_nr); 76void *flex_array_get_ptr(struct flex_array *fa, unsigned int element_nr);
77 77