]> git.hungrycats.org Git - linux/commitdiff
[PATCH] dm: 64 bit ioctl fixes
authorAndrew Morton <akpm@osdl.org>
Thu, 7 Aug 2003 04:12:39 +0000 (21:12 -0700)
committerLinus Torvalds <torvalds@home.osdl.org>
Thu, 7 Aug 2003 04:12:39 +0000 (21:12 -0700)
From: Joe Thornber <thornber@sistina.com>

Update the ioctl32 handlers for the 64-bit architectures to recognize
the new Device-Mapper version 4 ioctls. The version 1 ioctls are still
there.  If/When the version 1 ioctls are removed, these same files
will need to be updated again.

I have been unable to test this patch yet, since I have not had any
luck getting 2.6.0-test2 to compile on my ppc64 box (not a dm-related
problem).  But the patch is pretty trivial, so I'm pretty confident it
will work. If anyone else can test this (on mips64, sparc64, parisc,
or x86-64), let me know if you have any problems.  [Kevin Corry]

arch/sparc64/kernel/ioctl32.c
include/linux/compat_ioctl.h

index eae736c34895c1a6fb983d9cffafccda1f90eb4e..aa3056345ef1b50f915ed431a3bacf7e847f4736 100644 (file)
@@ -1546,6 +1546,21 @@ COMPATIBLE_IOCTL(BNEPCONNDEL)
 COMPATIBLE_IOCTL(BNEPGETCONNLIST)
 COMPATIBLE_IOCTL(BNEPGETCONNINFO)
 /* device-mapper */
+#if defined(CONFIG_DM_IOCTL_V4)
+COMPATIBLE_IOCTL(DM_VERSION)
+COMPATIBLE_IOCTL(DM_REMOVE_ALL)
+COMPATIBLE_IOCTL(DM_LIST_DEVICES)
+COMPATIBLE_IOCTL(DM_DEV_CREATE)
+COMPATIBLE_IOCTL(DM_DEV_REMOVE)
+COMPATIBLE_IOCTL(DM_DEV_RENAME)
+COMPATIBLE_IOCTL(DM_DEV_SUSPEND)
+COMPATIBLE_IOCTL(DM_DEV_STATUS)
+COMPATIBLE_IOCTL(DM_DEV_WAIT)
+COMPATIBLE_IOCTL(DM_TABLE_LOAD)
+COMPATIBLE_IOCTL(DM_TABLE_CLEAR)
+COMPATIBLE_IOCTL(DM_TABLE_DEPS)
+COMPATIBLE_IOCTL(DM_TABLE_STATUS)
+#else
 COMPATIBLE_IOCTL(DM_VERSION)
 COMPATIBLE_IOCTL(DM_REMOVE_ALL)
 COMPATIBLE_IOCTL(DM_DEV_CREATE)
@@ -1557,6 +1572,7 @@ COMPATIBLE_IOCTL(DM_DEV_DEPS)
 COMPATIBLE_IOCTL(DM_DEV_STATUS)
 COMPATIBLE_IOCTL(DM_TARGET_STATUS)
 COMPATIBLE_IOCTL(DM_TARGET_WAIT)
+#endif
 /* And these ioctls need translation */
 HANDLE_IOCTL(HDIO_GETGEO_BIG_RAW, hdio_getgeo_big)
 /* NCPFS */
index 3fb888cc0c34b7e12563b225b652ad620191c925..8a96df26f4466ce4a55f56d6fabda3500a443955 100644 (file)
@@ -119,6 +119,20 @@ COMPATIBLE_IOCTL(STOP_ARRAY_RO)
 COMPATIBLE_IOCTL(RESTART_ARRAY_RW)
 #ifdef CONFIG_BLK_DEV_DM
 /* DM */
+#ifdef CONFIG_DM_IOCTL_V4
+COMPATIBLE_IOCTL(DM_VERSION)
+COMPATIBLE_IOCTL(DM_LIST_DEVICES)
+COMPATIBLE_IOCTL(DM_DEV_CREATE)
+COMPATIBLE_IOCTL(DM_DEV_REMOVE)
+COMPATIBLE_IOCTL(DM_DEV_RENAME)
+COMPATIBLE_IOCTL(DM_DEV_SUSPEND)
+COMPATIBLE_IOCTL(DM_DEV_STATUS)
+COMPATIBLE_IOCTL(DM_DEV_WAIT)
+COMPATIBLE_IOCTL(DM_TABLE_LOAD)
+COMPATIBLE_IOCTL(DM_TABLE_CLEAR)
+COMPATIBLE_IOCTL(DM_TABLE_DEPS)
+COMPATIBLE_IOCTL(DM_TABLE_STATUS)
+#else
 COMPATIBLE_IOCTL(DM_VERSION)
 COMPATIBLE_IOCTL(DM_REMOVE_ALL)
 COMPATIBLE_IOCTL(DM_DEV_CREATE)
@@ -131,6 +145,7 @@ COMPATIBLE_IOCTL(DM_DEV_STATUS)
 COMPATIBLE_IOCTL(DM_TARGET_STATUS)
 COMPATIBLE_IOCTL(DM_TARGET_WAIT)
 #endif
+#endif
 /* Big K */
 COMPATIBLE_IOCTL(PIO_FONT)
 COMPATIBLE_IOCTL(GIO_FONT)