Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp3301333ybi; Fri, 5 Jul 2019 05:13:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqyXoG+w6bOQBaIt2Qa5ijD7zhKz7DLb57rvlz96qf/fhONeSszxOyNapnEG8o5w0zIIBS+S X-Received: by 2002:a17:90a:216f:: with SMTP id a102mr5367926pje.29.1562328837301; Fri, 05 Jul 2019 05:13:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562328837; cv=none; d=google.com; s=arc-20160816; b=EzbZXORnm/fiBrlaveC8KLox5g9ulYZDvPGLSiAnQz8H9SDgH+ViiejfIvYQ3puSDB gLYjYjY7dM9pmIqZMaPBTWkKDon5uOWnN72Bv/xBghdwvuji7Oj8AJtYadsZm1pJXtnj 4cpMrYOqZifnMxYjVT4HLTe6Kg4QJTimssNViRpmo0NHh1FvpDD5wLmtEWR7Cj4d2EhJ IQjpmEl/iiSgD79TW64FmYQYH7nWnbAw+9ODt86FKxQWskirdjuF6wUP2iemVROpWihw +LudH50iJwXH8R0HKbXRstJuzekxFu1YeS0WZwuBlRvHCEBNxP7nwgJZDLUND9rlJagM 13lA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=T86XdJ8efDoll85FvdfuxVoAvnlka8CM+xoA0u9jJyI=; b=v5Y7D/Te9XWOzvAl6loOcsE+l6Z6LyOxb5aVI6QH4WcCXGvsxmc4ALaaapI4YUOT6b sViJfA722BRAhOxM2p7JT/uUuQXhAgmwcKJv8USS81TlYfun+PaaFb1PsgqYVoYJD5Qd 5l40JEh0sGV9rH8ndsr5D5PTU7amMfAT/HUv2SGpaWOPyza2LdTNPBKsoK3eDYQJazIk nw9cABQcfeMrfVpCYN1LKI3dZ6iv0qtWaXBUwtJcW6y02r5Mgy13dwDIQJ7bTuujzfKm oL2PD7nQzfdPaHjSMG7sPmpgGDTaCSquIxGtQ6maMLzQ0hObwY4eFVsCdB9xxHudMY9k W04A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z11si8835377pgl.7.2019.07.05.05.13.42; Fri, 05 Jul 2019 05:13:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728920AbfGEMJW (ORCPT + 99 others); Fri, 5 Jul 2019 08:09:22 -0400 Received: from relay12.mail.gandi.net ([217.70.178.232]:40053 "EHLO relay12.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728087AbfGEMJS (ORCPT ); Fri, 5 Jul 2019 08:09:18 -0400 Received: from mc-bl-xps13.lan (lfbn-1-17395-211.w86-250.abo.wanadoo.fr [86.250.200.211]) (Authenticated sender: maxime.chevallier@bootlin.com) by relay12.mail.gandi.net (Postfix) with ESMTPSA id 51EF7200017; Fri, 5 Jul 2019 12:09:16 +0000 (UTC) From: Maxime Chevallier To: davem@davemloft.net Cc: Maxime Chevallier , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Antoine Tenart , thomas.petazzoni@bootlin.com, gregory.clement@bootlin.com, miquel.raynal@bootlin.com, nadavh@marvell.com, stefanc@marvell.com, mw@semihalf.com Subject: [PATCH net-next 2/2] net: mvpp2: cls: Add support for ETHER_FLOW Date: Fri, 5 Jul 2019 14:09:13 +0200 Message-Id: <20190705120913.25013-3-maxime.chevallier@bootlin.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190705120913.25013-1-maxime.chevallier@bootlin.com> References: <20190705120913.25013-1-maxime.chevallier@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Users can specify classification actions based on the 'ether' flow type. In that case, this will apply to all ethernet traffic, superseeding flows such as 'udp4' or 'tcp6'. Add support for this flow type in the PPv2 classifier, by mapping the ETHER_FLOW value to the corresponding entries in the classifier. Signed-off-by: Maxime Chevallier --- drivers/net/ethernet/marvell/mvpp2/mvpp2_cls.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2_cls.c b/drivers/net/ethernet/marvell/mvpp2/mvpp2_cls.c index 6c088c903c15..35478cba2aa5 100644 --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_cls.c +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_cls.c @@ -548,6 +548,8 @@ void mvpp2_cls_c2_read(struct mvpp2 *priv, int index, static int mvpp2_cls_ethtool_flow_to_type(int flow_type) { switch (flow_type & ~(FLOW_EXT | FLOW_MAC_EXT | FLOW_RSS)) { + case ETHER_FLOW: + return MVPP22_FLOW_ETHERNET; case TCP_V4_FLOW: return MVPP22_FLOW_TCP4; case TCP_V6_FLOW: -- 2.20.1