From: Sergei Trofimovich <slyfox@xxxxxxxxxx>
Header breakage noticed by cynede. Reproducible as:
$ gcc -c /usr/include/btrfs/ioctl.h -o /tmp/a.o
/usr/include/btrfs/ioctl.h:42:14: error: expected declaration specifiers or '...' before 'sizeof'
BUILD_ASSERT(sizeof(struct btrfs_ioctl_vol_args) == 4096);
^~~~~~
Basically gcc tries to say us BUILD_ASSERT is not visible.
BUILD_ASSERT lives in kerncompat.h which this change adds.
Reported-by: Mikhail Pukhlikov <cynede@xxxxxxxxxx>
Signed-off-by: Sergei Trofimovich <slyfox@xxxxxxxxxx>
---
ioctl.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/ioctl.h b/ioctl.h
index 238e7ef..ee650a9 100644
--- a/ioctl.h
+++ b/ioctl.h
@@ -26,6 +26,12 @@ extern "C" {
#include <asm/types.h>
#include <linux/ioctl.h>
+#if BTRFS_FLAT_INCLUDES
+#include "kerncompat.h"
+#else
+#include <btrfs/kerncompat.h>
+#endif /* BTRFS_FLAT_INCLUDES */
+
#ifndef __user
#define __user
#endif
--
2.10.1
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html