Commit 6cdbe80e authored by Andrew Morton's avatar Andrew Morton Committed by James Bottomley

[PATCH] I2O: fixes compiler warning on x86_64 in i2o_config

From: Markus Lidel <Markus.Lidel@shadowconnect.com>

- use compat_ptr to convert 32-bit pointer to 64-bit pointer in
  i2o_cfg_passthru32.
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent 9019be28
...@@ -42,6 +42,7 @@ ...@@ -42,6 +42,7 @@
#include <linux/spinlock.h> #include <linux/spinlock.h>
#include <linux/smp_lock.h> #include <linux/smp_lock.h>
#include <linux/ioctl32.h> #include <linux/ioctl32.h>
#include <linux/compat.h>
#include <linux/syscalls.h> #include <linux/syscalls.h>
#include <asm/uaccess.h> #include <asm/uaccess.h>
...@@ -646,9 +647,11 @@ static int i2o_cfg_passthru32(unsigned fd, unsigned cmnd, unsigned long arg, ...@@ -646,9 +647,11 @@ static int i2o_cfg_passthru32(unsigned fd, unsigned cmnd, unsigned long arg,
cmd = (struct i2o_cmd_passthru32 __user *)arg; cmd = (struct i2o_cmd_passthru32 __user *)arg;
if (get_user(iop, &cmd->iop) || get_user(user_msg, &cmd->msg)) if (get_user(iop, &cmd->iop) || get_user(i, &cmd->msg))
return -EFAULT; return -EFAULT;
user_msg = compat_ptr(i);
c = i2o_find_iop(iop); c = i2o_find_iop(iop);
if (!c) { if (!c) {
pr_debug("controller %d not found\n", iop); pr_debug("controller %d not found\n", iop);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment