summaryrefslogtreecommitdiff
path: root/util-linux
diff options
context:
space:
mode:
authorEric Andersen2003-11-03 08:59:51 +0000
committerEric Andersen2003-11-03 08:59:51 +0000
commitf6067beaa9408730c4232620330453e756d6d4f9 (patch)
treead787350e1d7ac1bb56d3d374ff9808596d22a90 /util-linux
parente6dc439b3a3fa2a64f9e938ac4e5810025c04242 (diff)
downloadbusybox-f6067beaa9408730c4232620330453e756d6d4f9.zip
busybox-f6067beaa9408730c4232620330453e756d6d4f9.tar.gz
Avoid conflicts with the 2.6 kernel headers, which define
_IOR rather differently, thereby breaking the BLKGETSIZE64 ioctl. -Erik
Diffstat (limited to 'util-linux')
-rw-r--r--util-linux/fdisk.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/util-linux/fdisk.c b/util-linux/fdisk.c
index 02c5c10..6c28e02 100644
--- a/util-linux/fdisk.c
+++ b/util-linux/fdisk.c
@@ -55,6 +55,11 @@
#define BLKGETSIZE _IO(0x12,96) /* return device size */
#define BLKFLSBUF _IO(0x12,97) /* flush buffer cache */
#define BLKSSZGET _IO(0x12,104) /* get block device sector size */
+
+/* Avoid conflicts with the 2.6 kernel headers, which define
+ * _IOR rather differently */
+#undef _IOR
+#define _IOR(type,nr,size) _IOC(_IOC_READ,(type),(nr),sizeof(size))
#define BLKGETSIZE64 _IOR(0x12,114,8) /* 8 = sizeof(u64) */
/*