patch-2_6_7-vs1_9_1_12
[linux-2.6.git] / arch / x86_64 / kernel / ldt.c
index 1b6252c..4e43e53 100644 (file)
@@ -125,7 +125,7 @@ void destroy_context(struct mm_struct *mm)
        }
 }
 
-static int read_ldt(void * ptr, unsigned long bytecount)
+static int read_ldt(void __user * ptr, unsigned long bytecount)
 {
        int err;
        unsigned long size;
@@ -153,7 +153,7 @@ static int read_ldt(void * ptr, unsigned long bytecount)
        return bytecount;
 }
 
-static int read_default_ldt(void * ptr, unsigned long bytecount)
+static int read_default_ldt(void __user * ptr, unsigned long bytecount)
 {
        /* Arbitrary number */ 
        /* x86-64 default LDT is all zeros */
@@ -164,7 +164,7 @@ static int read_default_ldt(void * ptr, unsigned long bytecount)
        return bytecount; 
 }
 
-static int write_ldt(void * ptr, unsigned long bytecount, int oldmode)
+static int write_ldt(void __user * ptr, unsigned long bytecount, int oldmode)
 {
        struct task_struct *me = current;
        struct mm_struct * mm = me->mm;
@@ -225,7 +225,7 @@ out:
        return error;
 }
 
-asmlinkage int sys_modify_ldt(int func, void *ptr, unsigned long bytecount)
+asmlinkage int sys_modify_ldt(int func, void __user *ptr, unsigned long bytecount)
 {
        int ret = -ENOSYS;