[SCSI] aacraid: Fix parenthesis placement error
authorMark Haverkamp <markh@osdl.org>
Mon, 27 Mar 2006 17:44:33 +0000 (09:44 -0800)
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>
Thu, 13 Apr 2006 15:13:21 +0000 (10:13 -0500)
Received from Mark Salyzyn

On 64 bit machines, when a 32 bit application tries to acquire the AIF,
they will always get and EFAULT error response from the driver.

Signed-off-by: Mark Haverkamp <markh@osdl.org>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/scsi/aacraid/linit.c

index 364232858f71651df4013d76d79230f3f38023a1..8d41064406ccc7f2a0eff80935cd0dcd1be48457 100644 (file)
@@ -571,12 +571,12 @@ static long aac_compat_do_ioctl(struct aac_dev *dev, unsigned cmd, unsigned long
                
                f = compat_alloc_user_space(sizeof(*f));
                ret = 0;
-               if (clear_user(f, sizeof(*f) != sizeof(*f)))
+               if (clear_user(f, sizeof(*f)) != sizeof(*f))
                        ret = -EFAULT;
                if (copy_in_user(f, (void __user *)arg, sizeof(struct fib_ioctl) - sizeof(u32)))
                        ret = -EFAULT;
                if (!ret)
-                       ret = aac_do_ioctl(dev, cmd, (void __user *)arg);
+                       ret = aac_do_ioctl(dev, cmd, f);
                break;
        }