[PATCH] net: Avoid compiler warning for mmsghdr when CONFIG_COMPAT is not selected

From: Arnaldo Carvalho de Melo
Date: Fri Oct 16 2009 - 22:07:15 EST


Reported-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
Signed-off-by: Arnaldo Carvalho de Melo <acme@xxxxxxxxxxxxxxxxxx>
---
include/net/compat.h | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/include/net/compat.h b/include/net/compat.h
index 9679f05..3c7d4e3 100644
--- a/include/net/compat.h
+++ b/include/net/compat.h
@@ -33,7 +33,11 @@ extern int compat_sock_get_timestamp(struct sock *, struct timeval __user *);
extern int compat_sock_get_timestampns(struct sock *, struct timespec __user *);

#else /* defined(CONFIG_COMPAT) */
-#define compat_msghdr msghdr /* to avoid compiler warnings */
+/*
+ * To avoid compiler warnings:
+ */
+#define compat_msghdr msghdr
+#define compat_mmsghdr mmsghdr
#endif /* defined(CONFIG_COMPAT) */

extern int get_compat_msghdr(struct msghdr *, struct compat_msghdr __user *);
--
1.6.2.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/