]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
authorDavid S. Miller <davem@davemloft.net>
Sat, 24 Oct 2015 13:54:12 +0000 (06:54 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sat, 24 Oct 2015 13:54:12 +0000 (06:54 -0700)
Conflicts:
net/ipv6/xfrm6_output.c
net/openvswitch/flow_netlink.c
net/openvswitch/vport-gre.c
net/openvswitch/vport-vxlan.c
net/openvswitch/vport.c
net/openvswitch/vport.h

The openvswitch conflicts were overlapping changes.  One was
the egress tunnel info fix in 'net' and the other was the
vport ->send() op simplification in 'net-next'.

The xfrm6_output.c conflicts was also a simplification
overlapping a bug fix.

Signed-off-by: David S. Miller <davem@davemloft.net>
37 files changed:
1  2 
Documentation/devicetree/bindings/net/cpsw.txt
drivers/net/ethernet/amd/xgbe/xgbe-dev.c
drivers/net/ethernet/amd/xgbe/xgbe-drv.c
drivers/net/ethernet/broadcom/bcm63xx_enet.c
drivers/net/ethernet/intel/i40e/i40e_ethtool.c
drivers/net/ethernet/intel/i40e/i40e_main.c
drivers/net/ethernet/marvell/mv643xx_eth.c
drivers/net/ethernet/ti/cpsw.c
drivers/net/phy/Kconfig
drivers/net/phy/Makefile
drivers/net/usb/qmi_wwan.c
drivers/net/vxlan.c
drivers/net/xen-netfront.c
include/linux/netdevice.h
include/uapi/linux/openvswitch.h
net/core/dev.c
net/ipv4/netfilter/ipt_rpfilter.c
net/ipv4/tcp_output.c
net/ipv4/xfrm4_output.c
net/ipv6/ip6_fib.c
net/ipv6/ip6_output.c
net/ipv6/route.c
net/ipv6/xfrm6_output.c
net/ipv6/xfrm6_policy.c
net/netfilter/core.c
net/openvswitch/actions.c
net/openvswitch/conntrack.c
net/openvswitch/datapath.c
net/openvswitch/flow_netlink.c
net/openvswitch/vport-geneve.c
net/openvswitch/vport-gre.c
net/openvswitch/vport-internal_dev.c
net/openvswitch/vport-vxlan.c
net/openvswitch/vport.c
net/openvswitch/vport.h
net/tipc/msg.c
net/tipc/udp_media.c

index 55d2d8577d075719cc28e61430bbb1414e3750c8,874fb297e96c563525a5d275a8e2239b6ab41725..040fbc1e55080a4d025df2a2fae888da6151008c
@@@ -29,8 -29,8 +29,9 @@@
  #include <linux/workqueue.h>
  #include <linux/delay.h>
  #include <linux/pm_runtime.h>
 +#include <linux/gpio.h>
  #include <linux/of.h>
+ #include <linux/of_mdio.h>
  #include <linux/of_net.h>
  #include <linux/of_device.h>
  #include <linux/if_vlan.h>
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc net/core/dev.c
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index d0619632723a298cf2374874b2f4fb03fa18640f,946880ad48acda725eb66f9e2d0a8fd0f2b4ec40..2701cb3d88e9372cd226d0f5f58fbdc3d9f7582d
@@@ -1169,20 -1192,17 +1169,22 @@@ static struct rt6_info *ip6_pol_route_o
  struct dst_entry *ip6_route_output(struct net *net, const struct sock *sk,
                                    struct flowi6 *fl6)
  {
 +      struct dst_entry *dst;
        int flags = 0;
+       bool any_src;
  
 +      dst = l3mdev_rt6_dst_by_oif(net, fl6);
 +      if (dst)
 +              return dst;
 +
        fl6->flowi6_iif = LOOPBACK_IFINDEX;
  
+       any_src = ipv6_addr_any(&fl6->saddr);
        if ((sk && sk->sk_bound_dev_if) || rt6_need_strict(&fl6->daddr) ||
-           fl6->flowi6_oif)
+           (fl6->flowi6_oif && any_src))
                flags |= RT6_LOOKUP_F_IFACE;
  
-       if (!ipv6_addr_any(&fl6->saddr))
+       if (!any_src)
                flags |= RT6_LOOKUP_F_HAS_SADDR;
        else if (sk)
                flags |= rt6_srcprefs2flags(inet6_sk(sk)->srcprefs);
index 9db067a11b525c4bb026fa1d352c05a591e60124,e15feb7b413dd1a93a376f2ab6aabcbc3c3bb944..4d09ce6fa90e666bfdeda09cbdc8c7b0cb8b5824
@@@ -164,12 -164,11 +171,11 @@@ static int __xfrm6_output(struct net *n
                return -EMSGSIZE;
        }
  
-       if (x->props.mode == XFRM_MODE_TUNNEL &&
-           ((skb->len > mtu && !skb_is_gso(skb)) ||
-               dst_allfrag(skb_dst(skb)))) {
+       if (toobig || dst_allfrag(skb_dst(skb)))
 -              return ip6_fragment(sk, skb,
 -                                  x->outer_mode->afinfo->output_finish);
 +              return ip6_fragment(net, sk, skb,
 +                                  __xfrm6_output_finish);
-       }
+ skip_frag:
        return x->outer_mode->afinfo->output_finish(sk, skb);
  }
  
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index 80e1f09397c0e6c64ab7f8bea5814f3664571cb3,38536c137c54d0d4ebcebcce613fefdb89799b5a..907d6fd28ede695cc1b876570c101883ed0b4b0e
@@@ -798,14 -749,12 +798,13 @@@ static int ip_tun_to_nlattr(struct sk_b
        return 0;
  }
  
- int ovs_nla_put_egress_tunnel_key(struct sk_buff *skb,
-                                 const struct ip_tunnel_info *egress_tun_info,
-                                 const void *egress_tun_opts)
+ int ovs_nla_put_tunnel_info(struct sk_buff *skb,
+                           struct ip_tunnel_info *tun_info)
  {
-       return __ip_tun_to_nlattr(skb, &egress_tun_info->key,
-                                 egress_tun_opts,
-                                 egress_tun_info->options_len,
-                                 ip_tunnel_info_af(egress_tun_info));
 -      return __ipv4_tun_to_nlattr(skb, &tun_info->key,
 -                                  ip_tunnel_info_opts(tun_info),
 -                                  tun_info->options_len);
++      return __ip_tun_to_nlattr(skb, &tun_info->key,
++                                ip_tunnel_info_opts(tun_info),
++                                tun_info->options_len,
++                                ip_tunnel_info_af(tun_info));
  }
  
  static int metadata_from_nlattrs(struct net *net, struct sw_flow_match *match,
index 7a568ca8da54377cbc08e7dd69a27bc64868130b,5f8aaaaa0785385b89096925718d96b3335c1d32..efb736bb685545a0cb6a323d3eca87fc54eeb9f4
@@@ -128,9 -116,8 +116,8 @@@ static struct vport_ops ovs_geneve_vpor
        .create         = geneve_create,
        .destroy        = ovs_netdev_tunnel_destroy,
        .get_options    = geneve_get_options,
 -      .send           = ovs_netdev_send,
 +      .send           = dev_queue_xmit,
        .owner          = THIS_MODULE,
-       .get_egress_tun_info    = geneve_get_egress_tun_info,
  };
  
  static int __init ovs_geneve_tnl_init(void)
index cdb758ab01cfd64254acdd3b4b9a314868faca82,64225bf5eb405f4082547bbc8f09d920de72cdb8..c3257d78d3d28e6ed06e1be9c2e4a4f452c52886
@@@ -87,15 -87,7 +87,7 @@@ static struct vport *gre_create(const s
  static struct vport_ops ovs_gre_vport_ops = {
        .type           = OVS_VPORT_TYPE_GRE,
        .create         = gre_create,
 -      .send           = ovs_netdev_send,
 +      .send           = dev_queue_xmit,
-       .get_egress_tun_info    = gre_get_egress_tun_info,
        .destroy        = ovs_netdev_tunnel_destroy,
        .owner          = THIS_MODULE,
  };
Simple merge
index 6f700710d4137d074742ac93c5a88f3c77eb9d69,e1c9c08880373276e8430cadd93f03fe4a1e11a0..1605691d94144aee0fc50ffb17be05eca2b59675
@@@ -170,8 -151,7 +151,7 @@@ static struct vport_ops ovs_vxlan_netde
        .create                 = vxlan_create,
        .destroy                = ovs_netdev_tunnel_destroy,
        .get_options            = vxlan_get_options,
 -      .send                   = ovs_netdev_send,
 +      .send                   = dev_queue_xmit,
-       .get_egress_tun_info    = vxlan_get_egress_tun_info,
  };
  
  static int __init ovs_vxlan_tnl_init(void)
index ef19d0b77d13fd4f3f1e4bef987dd2adbcca3760,320c765ce44a07e71daedfd457d37c81ea2e4c49..0ac0fd004d7ed885c009560d966da5b29b47f242
@@@ -479,91 -479,3 +479,33 @@@ void ovs_vport_deferred_free(struct vpo
        call_rcu(&vport->rcu, free_vport_rcu);
  }
  EXPORT_SYMBOL_GPL(ovs_vport_deferred_free);
- int ovs_tunnel_get_egress_info(struct dp_upcall_info *upcall,
-                              struct net *net,
-                              struct sk_buff *skb,
-                              u8 ipproto,
-                              __be16 tp_src,
-                              __be16 tp_dst)
- {
-       struct ip_tunnel_info *egress_tun_info = upcall->egress_tun_info;
-       const struct ip_tunnel_info *tun_info = skb_tunnel_info(skb);
-       const struct ip_tunnel_key *tun_key;
-       u32 skb_mark = skb->mark;
-       struct rtable *rt;
-       struct flowi4 fl;
-       if (unlikely(!tun_info))
-               return -EINVAL;
-       if (ip_tunnel_info_af(tun_info) != AF_INET)
-               return -EINVAL;
-       tun_key = &tun_info->key;
-       /* Route lookup to get srouce IP address.
-        * The process may need to be changed if the corresponding process
-        * in vports ops changed.
-        */
-       rt = ovs_tunnel_route_lookup(net, tun_key, skb_mark, &fl, ipproto);
-       if (IS_ERR(rt))
-               return PTR_ERR(rt);
-       ip_rt_put(rt);
-       /* Generate egress_tun_info based on tun_info,
-        * saddr, tp_src and tp_dst
-        */
-       ip_tunnel_key_init(&egress_tun_info->key,
-                          fl.saddr, tun_key->u.ipv4.dst,
-                          tun_key->tos,
-                          tun_key->ttl,
-                          tp_src, tp_dst,
-                          tun_key->tun_id,
-                          tun_key->tun_flags);
-       egress_tun_info->options_len = tun_info->options_len;
-       egress_tun_info->mode = tun_info->mode;
-       upcall->egress_tun_opts = ip_tunnel_info_opts(egress_tun_info);
-       return 0;
- }
- EXPORT_SYMBOL_GPL(ovs_tunnel_get_egress_info);
- int ovs_vport_get_egress_tun_info(struct vport *vport, struct sk_buff *skb,
-                                 struct dp_upcall_info *upcall)
- {
-       /* get_egress_tun_info() is only implemented on tunnel ports. */
-       if (unlikely(!vport->ops->get_egress_tun_info))
-               return -EINVAL;
-       return vport->ops->get_egress_tun_info(vport, skb, upcall);
- }
 +
 +static unsigned int packet_length(const struct sk_buff *skb)
 +{
 +      unsigned int length = skb->len - ETH_HLEN;
 +
 +      if (skb->protocol == htons(ETH_P_8021Q))
 +              length -= VLAN_HLEN;
 +
 +      return length;
 +}
 +
 +void ovs_vport_send(struct vport *vport, struct sk_buff *skb)
 +{
 +      int mtu = vport->dev->mtu;
 +
 +      if (unlikely(packet_length(skb) > mtu && !skb_is_gso(skb))) {
 +              net_warn_ratelimited("%s: dropped over-mtu packet: %d > %d\n",
 +                                   vport->dev->name,
 +                                   packet_length(skb), mtu);
 +              vport->dev->stats.tx_errors++;
 +              goto drop;
 +      }
 +
 +      skb->dev = vport->dev;
 +      vport->ops->send(skb);
 +      return;
 +
 +drop:
 +      kfree_skb(skb);
 +}
index 885607f28d56a149d5e872c5254c9b3fbddb5dec,d341ad6f3afe5734f587c1df347fd72dc2ba2c38..bdfd82a7c064948dc1dc83acbc85b6534c1bcf9b
@@@ -153,10 -140,7 +140,7 @@@ struct vport_ops 
        int (*set_options)(struct vport *, struct nlattr *);
        int (*get_options)(const struct vport *, struct sk_buff *);
  
 -      void (*send)(struct vport *, struct sk_buff *);
 +      netdev_tx_t (*send) (struct sk_buff *skb);
-       int (*get_egress_tun_info)(struct vport *, struct sk_buff *,
-                                  struct dp_upcall_info *upcall);
        struct module *owner;
        struct list_head list;
  };
diff --cc net/tipc/msg.c
Simple merge
Simple merge