diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index dc52e13d58e021ac5cf7951d44c66c8e8d9a4993..3881610b64384cee634367c3c35d237a4fa2f2aa 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -680,7 +680,8 @@ static int do_i2c_rdwr_ioctl(unsigned int fd, unsigned int cmd, struct i2c_msg __user *tmsgs; struct i2c_msg32 __user *umsgs; compat_caddr_t datap; - int nmsgs, i; + u32 nmsgs; + int i; if (get_user(nmsgs, &udata->nmsgs)) return -EFAULT;