[DRBD-cvs] drbd by phil; Micro patch to make it more 2.6 like by ...

drbd-user@lists.linbit.com drbd-user@lists.linbit.com
Tue, 30 Mar 2004 13:46:57 +0200 (CEST)


DRBD CVS committal

Author  : phil
Module  : drbd

Dir     : drbd/drbd


Modified Files:
      Tag: rel-0_7-branch
	drbd_main.c 


Log Message:
Micro patch to make it more 2.6 like by LMB

===================================================================
RCS file: /var/lib/cvs/drbd/drbd/drbd/drbd_main.c,v
retrieving revision 1.73.2.147
retrieving revision 1.73.2.148
diff -u -3 -r1.73.2.147 -r1.73.2.148
--- drbd_main.c	29 Mar 2004 16:15:57 -0000	1.73.2.147
+++ drbd_main.c	30 Mar 2004 11:46:51 -0000	1.73.2.148
@@ -53,7 +53,15 @@
 #include <linux/slab.h>
 #include <linux/devfs_fs_kernel.h>
 
-#if defined(CONFIG_PPC64) || defined(CONFIG_SPARC64) || defined(CONFIG_X86_64)
+#define __KERNEL_SYSCALLS__
+#include <linux/unistd.h>
+#include <linux/vmalloc.h>
+
+#include <linux/drbd.h>
+#include "drbd_int.h"
+
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
+# if defined(CONFIG_PPC64) || defined(CONFIG_SPARC64) || defined(CONFIG_X86_64)
 extern int register_ioctl32_conversion(unsigned int cmd,
 				       int (*handler)(unsigned int,
 						      unsigned int,
@@ -61,14 +69,12 @@
 						      struct file *));
 extern int unregister_ioctl32_conversion(unsigned int cmd);
 extern asmlinkage int sys_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg);
+# endif
+#else
+# ifdef CONFIG_COMPAT
+#  include <linux/ioctl32.h>
+# endif
 #endif
-
-#define __KERNEL_SYSCALLS__
-#include <linux/unistd.h>
-#include <linux/vmalloc.h>
-
-#include <linux/drbd.h>
-#include "drbd_int.h"
 
 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
 static devfs_handle_t devfs_handle;