From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Ahern Subject: [PATCH net-next 3/3] net: veth: Set features for MPLS Date: Fri, 19 Aug 2016 10:09:02 -0700 Message-ID: <1471626542-13335-4-git-send-email-dsa@cumulusnetworks.com> References: <1471626542-13335-1-git-send-email-dsa@cumulusnetworks.com> Cc: buytenh@wantstofly.org, simon.horman@netronome.com, ebiederm@xmission.com, rshearma@brocade.com, tom@herbertland.com, tgraf@suug.ch, olivier.dugeon@orange.com, alexander.duyck@gmail.com, roopa@cumulusnetworks.com, David Ahern To: netdev@vger.kernel.org, davem@davemloft.net Return-path: Received: from mail-pf0-f176.google.com ([209.85.192.176]:34118 "EHLO mail-pf0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754466AbcHSRPv (ORCPT ); Fri, 19 Aug 2016 13:15:51 -0400 Received: by mail-pf0-f176.google.com with SMTP id p64so11264335pfb.1 for ; Fri, 19 Aug 2016 10:15:51 -0700 (PDT) In-Reply-To: <1471626542-13335-1-git-send-email-dsa@cumulusnetworks.com> Sender: netdev-owner@vger.kernel.org List-ID: veth does not really transmit packets only moves the skb from one netdev to another so gso and checksum is not really needed. Add the features to mpls_features to get the same benefit and performance with MPLS as without it. Reported-by: Lennert Buytenhek Signed-off-by: David Ahern --- drivers/net/veth.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/veth.c b/drivers/net/veth.c index f37a6e61d4ad..5db320a4d5cf 100644 --- a/drivers/net/veth.c +++ b/drivers/net/veth.c @@ -340,6 +340,7 @@ static void veth_setup(struct net_device *dev) dev->hw_features = VETH_FEATURES; dev->hw_enc_features = VETH_FEATURES; + dev->mpls_features = NETIF_F_HW_CSUM | NETIF_F_GSO_SOFTWARE; } /* -- 2.1.4