From patchwork Fri Mar 29 20:45:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin 'ldir' Darbyshire-Bryant X-Patchwork-Id: 1070152 Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=darbyshire-bryant.me.uk Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=darbyshire-bryant.me.uk header.i=@darbyshire-bryant.me.uk header.b="LESg5eGR"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 44WDJV5lZ3z9sPc for ; Sat, 30 Mar 2019 07:45:14 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730202AbfC2UpM (ORCPT ); Fri, 29 Mar 2019 16:45:12 -0400 Received: from mail-eopbgr50079.outbound.protection.outlook.com ([40.107.5.79]:28589 "EHLO EUR03-VE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729996AbfC2UpM (ORCPT ); Fri, 29 Mar 2019 16:45:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=darbyshire-bryant.me.uk; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=58Y8bi2MqvhPTr0pd7U823QN+foyUMcoRtKGHDIuXWw=; b=LESg5eGRoPzmBP8oceHXd4naqvIoip1Kdu6tosJZYrkiyEDKaz9SwFTla9A+NlR4xUk0XyWZsDcAMtA3dPP2LJ4G+ADrWzCvym1wmt4B+QHC1NHqRXVKyf/xHpnDTLZXiQYpQLsW4viZMoOWotZ76bDBWJzK3W6EAQJ9l12atqA= Received: from VI1PR0302MB2750.eurprd03.prod.outlook.com (10.171.105.143) by VI1PR0302MB2752.eurprd03.prod.outlook.com (10.171.105.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1750.16; Fri, 29 Mar 2019 20:45:07 +0000 Received: from VI1PR0302MB2750.eurprd03.prod.outlook.com ([fe80::a8fc:70f:5750:d2d8]) by VI1PR0302MB2750.eurprd03.prod.outlook.com ([fe80::a8fc:70f:5750:d2d8%9]) with mapi id 15.20.1750.017; Fri, 29 Mar 2019 20:45:07 +0000 From: Kevin 'ldir' Darbyshire-Bryant To: Kevin 'ldir' Darbyshire-Bryant CC: "jhs@mojatatu.com" , "jiri@resnulli.us" , "netdev@vger.kernel.org" , "xiyou.wangcong@gmail.com" Subject: [RFC net-next 0/1] net: sched: Introduce conntrack action Thread-Topic: [RFC net-next 0/1] net: sched: Introduce conntrack action Thread-Index: AQHU5nBKHLLjO9PJ3UqJ6q86Y3KTng== Date: Fri, 29 Mar 2019 20:45:06 +0000 Message-ID: <20190329204438.68777-1-ldir@darbyshire-bryant.me.uk> References: In-Reply-To: Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: VI1P195CA0075.EURP195.PROD.OUTLOOK.COM (2603:10a6:802:59::28) To VI1PR0302MB2750.eurprd03.prod.outlook.com (2603:10a6:800:e2::15) authentication-results: spf=none (sender IP is ) smtp.mailfrom=ldir@darbyshire-bryant.me.uk; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.20.1 (Apple Git-117) x-originating-ip: [2a02:c7f:1240:ee00::dc83] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 81172ce0-7284-4544-b4b2-08d6b4876d1a x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(7021145)(8989299)(5600127)(711020)(4605104)(4534185)(7022145)(4603075)(4627221)(201702281549075)(8990200)(2017052603328)(7153060)(7193020); SRVR:VI1PR0302MB2752; x-ms-traffictypediagnostic: VI1PR0302MB2752: x-microsoft-antispam-prvs: x-forefront-prvs: 0991CAB7B3 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(366004)(346002)(376002)(396003)(136003)(39830400003)(189003)(199004)(8936002)(71190400001)(4744005)(2616005)(53936002)(6486002)(97736004)(6862004)(14454004)(2906002)(25786009)(305945005)(476003)(478600001)(6436002)(106356001)(6512007)(105586002)(6116002)(7736002)(7049001)(68736007)(4326008)(50226002)(74482002)(54906003)(186003)(52116002)(256004)(46003)(76176011)(81166006)(86362001)(37006003)(5660300002)(1076003)(6200100001)(8676002)(386003)(102836004)(71200400001)(6506007)(99286004)(36756003)(316002)(81156014)(446003)(486006)(11346002); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR0302MB2752; H:VI1PR0302MB2750.eurprd03.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: darbyshire-bryant.me.uk does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: DqvksMl2dLLL58sf3e9MMqL/6FNVvd5+50On8h3XtUkQaZPy6qAhIbQPFV+aRI+UUkCEbIoXkelyC8TBoXR3takF0eQIZNgRlZ4uml9y2ytnbvAaAj0avMq2xINSqnZ/v5FTUi91dRFoRsiE/9Uaj7zINmdulx4n8tfmfyc+8mSuME3hv2gOOGq7JreHFKjtCj6o2piXKzH8iqS3yULupNkhi5N915a3qlmOTIUe6iUrKOtEBdml/cGbFb5JVvATlP+DWwnYwh2lXlUg+dk8Fh8fPv3JaJGbz2q+13IX4knUE7vA0cK7+2rYDoau91MvLrOl5ah4l9/v5lHbVDXbUKujW07asE7zwA6GOrhJEXC9KDGc1QB+Q5+9G5jQVVBM/UYTCxKBd4nUPhU/KRl8bofVyTj6NqnrqxbPpz8+d9U= MIME-Version: 1.0 X-OriginatorOrg: darbyshire-bryant.me.uk X-MS-Exchange-CrossTenant-Network-Message-Id: 81172ce0-7284-4544-b4b2-08d6b4876d1a X-MS-Exchange-CrossTenant-originalarrivaltime: 29 Mar 2019 20:45:07.0320 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 9151708b-c553-406f-8e56-694f435154a4 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0302MB2752 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Hi Cong, OK, so I've renamed conndscp to conntrack and hopefully this are flexible enough for future conntrack->skb operations to be added in the future. How does this one fly? Cheers, Kevin Kevin Darbyshire-Bryant (1): net: sched: Introduce conntrack action include/net/tc_act/tc_conntrack.h | 19 ++ include/uapi/linux/pkt_cls.h | 1 + include/uapi/linux/tc_act/tc_conntrack.h | 30 ++ net/sched/Kconfig | 13 + net/sched/Makefile | 1 + net/sched/act_conntrack.c | 324 ++++++++++++++++++++++ tools/testing/selftests/tc-testing/config | 1 + 7 files changed, 389 insertions(+) create mode 100644 include/net/tc_act/tc_conntrack.h create mode 100644 include/uapi/linux/tc_act/tc_conntrack.h create mode 100644 net/sched/act_conntrack.c