[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1433000370-19509-87-git-send-email-mikko.rapeli@iki.fi>
Date: Sat, 30 May 2015 17:39:18 +0200
From: Mikko Rapeli <mikko.rapeli@....fi>
To: linux-kernel@...r.kernel.org
Cc: Mikko Rapeli <mikko.rapeli@....fi>, Chris Mason <clm@...com>,
David Sterba <dsterba@...e.cz>,
Anand Jain <Anand.Jain@...cle.com>,
Takeuchi Satoru <takeuchi_satoru@...fujitsu.com>,
Eryu Guan <guaneryu@...il.com>,
Gerhard Heift <gerhard@...ft.name>, linux-api@...r.kernel.org
Subject: [PATCH 86/98] include/uapi/linux/btrfs.h: define NULL
Copied the NULL definition from include/linux/stddef.h which does not have
it in userspace.
Fixes userspace compilation error:
error: ‘NULL’ undeclared (first use in this function)
return NULL;
Signed-off-by: Mikko Rapeli <mikko.rapeli@....fi>
---
include/uapi/linux/btrfs.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/include/uapi/linux/btrfs.h b/include/uapi/linux/btrfs.h
index b6dec05..a8ae69b 100644
--- a/include/uapi/linux/btrfs.h
+++ b/include/uapi/linux/btrfs.h
@@ -20,6 +20,12 @@
#define _UAPI_LINUX_BTRFS_H
#include <linux/types.h>
#include <linux/ioctl.h>
+#include <linux/stddef.h>
+
+/* for userspace where linux/stddef.h doesn't define this */
+#ifndef NULL
+#define NULL ((void *)0)
+#endif
#define BTRFS_IOCTL_MAGIC 0x94
#define BTRFS_VOL_NAME_MAX 255
--
2.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists