patch-2_6_7-vs1_9_1_12
[linux-2.6.git] / net / ipv4 / devinet.c
index b97526d..37581ba 100644 (file)
@@ -516,7 +516,7 @@ static inline int devinet_notiproot (struct in_ifaddr *ifa)
 }
 
 
-int devinet_ioctl(unsigned int cmd, void *arg)
+int devinet_ioctl(unsigned int cmd, void __user *arg)
 {
        struct ifreq ifr;
        struct sockaddr_in sin_orig;
@@ -742,7 +742,7 @@ rarok:
        goto out;
 }
 
-static int inet_gifconf(struct net_device *dev, char *buf, int len)
+static int inet_gifconf(struct net_device *dev, char __user *buf, int len)
 {
        struct in_device *in_dev = __in_dev_get(dev);
        struct in_ifaddr *ifa;
@@ -1169,7 +1169,7 @@ void inet_forward_change(void)
 }
 
 static int devinet_sysctl_forward(ctl_table *ctl, int write,
-                                 struct file* filp, void *buffer,
+                                 struct file* filp, void __user *buffer,
                                  size_t *lenp)
 {
        int *valp = ctl->data;
@@ -1187,7 +1187,7 @@ static int devinet_sysctl_forward(ctl_table *ctl, int write,
 }
 
 int ipv4_doint_and_flush(ctl_table *ctl, int write,
-                        struct file* filp, void *buffer,
+                        struct file* filp, void __user *buffer,
                         size_t *lenp)
 {
        int *valp = ctl->data;
@@ -1200,9 +1200,9 @@ int ipv4_doint_and_flush(ctl_table *ctl, int write,
        return ret;
 }
 
-int ipv4_doint_and_flush_strategy(ctl_table *table, int *name, int nlen,
-                                 void *oldval, size_t *oldlenp,
-                                 void *newval, size_t newlen, 
+int ipv4_doint_and_flush_strategy(ctl_table *table, int __user *name, int nlen,
+                                 void __user *oldval, size_t __user *oldlenp,
+                                 void __user *newval, size_t newlen, 
                                  void **context)
 {
        int *valp = table->data;
@@ -1214,7 +1214,7 @@ int ipv4_doint_and_flush_strategy(ctl_table *table, int *name, int nlen,
        if (newlen != sizeof(int))
                return -EINVAL;
 
-       if (get_user(new, (int *)newval))
+       if (get_user(new, (int __user *)newval))
                return -EFAULT;
 
        if (new == *valp)