summaryrefslogtreecommitdiffstats
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
parentc9e86a9b95f198d7df49b25fcd808ee39cba218f (diff)
downloadop-kernel-dev-c41ab6a1b9028de33e74101cb0aae13098a56fdb.zip
op-kernel-dev-c41ab6a1b9028de33e74101cb0aae13098a56fdb.tar.gz
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>
-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 631b77f..70e4efa 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);
int flex_array_shrink(struct flex_array *fa);
#define flex_array_put_ptr(fa, nr, src, gfp) \
- flex_array_put(fa, nr, &(void *)(src), gfp)
+ flex_array_put(fa, nr, (void *)&(src), gfp)
void *flex_array_get_ptr(struct flex_array *fa, unsigned int element_nr);
OpenPOWER on IntegriCloud