aboutsummaryrefslogtreecommitdiffstats
path: root/net/openvswitch
diff options
context:
space:
mode:
Diffstat (limited to 'net/openvswitch')
-rw-r--r--net/openvswitch/datapath.c5
-rw-r--r--net/openvswitch/vport-internal_dev.c3
2 files changed, 3 insertions, 5 deletions
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c
index f996db343247..9dc537df46c4 100644
--- a/net/openvswitch/datapath.c
+++ b/net/openvswitch/datapath.c
@@ -301,7 +301,7 @@ static int queue_gso_packets(struct net *net, int dp_ifindex,
301 struct sk_buff *segs, *nskb; 301 struct sk_buff *segs, *nskb;
302 int err; 302 int err;
303 303
304 segs = skb_gso_segment(skb, NETIF_F_SG | NETIF_F_HW_CSUM); 304 segs = __skb_gso_segment(skb, NETIF_F_SG | NETIF_F_HW_CSUM, false);
305 if (IS_ERR(segs)) 305 if (IS_ERR(segs))
306 return PTR_ERR(segs); 306 return PTR_ERR(segs);
307 307
@@ -1989,10 +1989,9 @@ static struct pernet_operations ovs_net_ops = {
1989 1989
1990static int __init dp_init(void) 1990static int __init dp_init(void)
1991{ 1991{
1992 struct sk_buff *dummy_skb;
1993 int err; 1992 int err;
1994 1993
1995 BUILD_BUG_ON(sizeof(struct ovs_skb_cb) > sizeof(dummy_skb->cb)); 1994 BUILD_BUG_ON(sizeof(struct ovs_skb_cb) > FIELD_SIZEOF(struct sk_buff, cb));
1996 1995
1997 pr_info("Open vSwitch switching datapath\n"); 1996 pr_info("Open vSwitch switching datapath\n");
1998 1997
diff --git a/net/openvswitch/vport-internal_dev.c b/net/openvswitch/vport-internal_dev.c
index 5d460c37df07..0531de6c7a4a 100644
--- a/net/openvswitch/vport-internal_dev.c
+++ b/net/openvswitch/vport-internal_dev.c
@@ -69,7 +69,6 @@ static int internal_dev_mac_addr(struct net_device *dev, void *p)
69 69
70 if (!is_valid_ether_addr(addr->sa_data)) 70 if (!is_valid_ether_addr(addr->sa_data))
71 return -EADDRNOTAVAIL; 71 return -EADDRNOTAVAIL;
72 dev->addr_assign_type &= ~NET_ADDR_RANDOM;
73 memcpy(dev->dev_addr, addr->sa_data, dev->addr_len); 72 memcpy(dev->dev_addr, addr->sa_data, dev->addr_len);
74 return 0; 73 return 0;
75} 74}
@@ -98,7 +97,7 @@ static int internal_dev_stop(struct net_device *netdev)
98static void internal_dev_getinfo(struct net_device *netdev, 97static void internal_dev_getinfo(struct net_device *netdev,
99 struct ethtool_drvinfo *info) 98 struct ethtool_drvinfo *info)
100{ 99{
101 strcpy(info->driver, "openvswitch"); 100 strlcpy(info->driver, "openvswitch", sizeof(info->driver));
102} 101}
103 102
104static const struct ethtool_ops internal_dev_ethtool_ops = { 103static const struct ethtool_ops internal_dev_ethtool_ops = {