vserver 2.0 rc7
[linux-2.6.git] / drivers / isdn / act2000 / act2000_isa.c
index df7923c..bc98d77 100644 (file)
@@ -401,7 +401,6 @@ int
 act2000_isa_download(act2000_card * card, act2000_ddef __user * cb)
 {
         unsigned int length;
-        int ret;
         int l;
         int c;
         long timeout;
@@ -413,12 +412,12 @@ act2000_isa_download(act2000_card * card, act2000_ddef __user * cb)
         if (!act2000_isa_reset(card->port))
                 return -ENXIO;
         msleep_interruptible(500);
-        if(copy_from_user(&cblock, cb, sizeof(cblock)))
+        if (copy_from_user(&cblock, cb, sizeof(cblock)))
                return -EFAULT;
         length = cblock.length;
         p = cblock.buffer;
-        if ((ret = verify_area(VERIFY_READ, p, length)))
-                return ret;
+        if (!access_ok(VERIFY_READ, p, length))
+                return -EFAULT;
         buf = (u_char *) kmalloc(1024, GFP_KERNEL);
         if (!buf)
                 return -ENOMEM;