]> Pileus Git - ~andy/linux/blobdiff - net/ipv4/arp.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 into for-linus
[~andy/linux] / net / ipv4 / arp.c
index 6f0827b2b154c298869f825d3585a41002008f55..8e17f65f400215a72c3ac3effb908071255d2747 100644 (file)
@@ -402,7 +402,6 @@ static int arp_ignore(struct in_device *in_dev, __be32 sip, __be32 tip)
        case 3: /* Do not reply for scope host addresses */
                sip = 0;
                scope = RT_SCOPE_LINK;
-               in_dev = NULL;
                break;
        case 4: /* Reserved */
        case 5:
@@ -425,7 +424,7 @@ static int arp_filter(__be32 sip, __be32 tip, struct net_device *dev)
        int flag = 0;
        /*unsigned long now; */
 
-       if (ip_route_output_key(&rt, &fl) < 0)
+       if (ip_route_output_key(&init_net, &rt, &fl) < 0)
                return 1;
        if (rt->u.dst.dev != dev) {
                NET_INC_STATS_BH(LINUX_MIB_ARPFILTER);
@@ -559,8 +558,9 @@ static inline int arp_fwd_proxy(struct in_device *in_dev, struct rtable *rt)
  */
 struct sk_buff *arp_create(int type, int ptype, __be32 dest_ip,
                           struct net_device *dev, __be32 src_ip,
-                          unsigned char *dest_hw, unsigned char *src_hw,
-                          unsigned char *target_hw)
+                          const unsigned char *dest_hw,
+                          const unsigned char *src_hw,
+                          const unsigned char *target_hw)
 {
        struct sk_buff *skb;
        struct arphdr *arp;
@@ -673,8 +673,8 @@ void arp_xmit(struct sk_buff *skb)
  */
 void arp_send(int type, int ptype, __be32 dest_ip,
              struct net_device *dev, __be32 src_ip,
-             unsigned char *dest_hw, unsigned char *src_hw,
-             unsigned char *target_hw)
+             const unsigned char *dest_hw, const unsigned char *src_hw,
+             const unsigned char *target_hw)
 {
        struct sk_buff *skb;
 
@@ -1003,7 +1003,7 @@ static int arp_req_set(struct net *net, struct arpreq *r,
                struct flowi fl = { .nl_u = { .ip4_u = { .daddr = ip,
                                                         .tos = RTO_ONLINK } } };
                struct rtable * rt;
-               if ((err = ip_route_output_key(&rt, &fl)) != 0)
+               if ((err = ip_route_output_key(net, &rt, &fl)) != 0)
                        return err;
                dev = rt->u.dst.dev;
                ip_rt_put(rt);
@@ -1110,7 +1110,7 @@ static int arp_req_delete(struct net *net, struct arpreq *r,
                struct flowi fl = { .nl_u = { .ip4_u = { .daddr = ip,
                                                         .tos = RTO_ONLINK } } };
                struct rtable * rt;
-               if ((err = ip_route_output_key(&rt, &fl)) != 0)
+               if ((err = ip_route_output_key(net, &rt, &fl)) != 0)
                        return err;
                dev = rt->u.dst.dev;
                ip_rt_put(rt);