From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9C762A04F6; Wed, 11 Dec 2019 12:36:33 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id C8A9D2C6A; Wed, 11 Dec 2019 12:36:32 +0100 (CET) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by dpdk.org (Postfix) with ESMTP id D57B81D9E for ; Wed, 11 Dec 2019 12:36:29 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Dec 2019 03:36:28 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,301,1571727600"; d="scan'208";a="215888420" Received: from orsmsx106.amr.corp.intel.com ([10.22.225.133]) by orsmga003.jf.intel.com with ESMTP; 11 Dec 2019 03:36:28 -0800 Received: from orsmsx155.amr.corp.intel.com (10.22.240.21) by ORSMSX106.amr.corp.intel.com (10.22.225.133) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 11 Dec 2019 03:36:28 -0800 Received: from ORSEDG001.ED.cps.intel.com (10.7.248.4) by ORSMSX155.amr.corp.intel.com (10.22.240.21) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 11 Dec 2019 03:36:28 -0800 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (104.47.58.106) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (TLS) id 14.3.439.0; Wed, 11 Dec 2019 03:36:28 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KBRqlI7OXLRPPK+i2poCMhkRTkbWKOStooioDev8t5zREqQFRDch+sh+VSg+Yg4aNZI2wJTKxGBcjApr17MLDe8Qp7kgwvECKV3B5KJpLpHx9an44dYKOKVOvdBaZZKIkxhuiXdw1meVHgS9I43IS4hiS1IYzQivO8JVINDYrJi4tO87hlhe/TPwXZMzu6pK8Bv8Yy0di/PlpLIyyjj0HC6dIGWpiPIl/PlYZp1Nw9EpIy3rZ9wGhrmuYIsL2HhvjlvTxqHHYaip4g+ebQZ52PZ9cKjIMvBRoKb55tgY1M9ngS6euOhNCtVvkPuKYPsCa2qtDvSdc+hXc0GuHPQBuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2hJ1Y7wKLCSFscxZ30kNyU27AfP1taOLcJtzl4iWuGM=; b=J6KkWeNVb4NT6EG2+BuF9tWtwAqIHH+o+ztwZ50bVaXVaoi1+c59X3P2U4rUs0skx8G6vNtMv4U3znxXLY+PRYTbYIy4CxO66nLXuqY1NQrhw7EPIR6+pRl7Q6H9l8kh4/P7n116QP+q/DRuAHlXqzhrlmlKHniFQkE1mVy07mrlzE5tuXm2+jUGBGdI8OiQSGGsQq4P9c0vQOKgfM9yOGqMRCVWltP+rfV+7NLVfEOQ6n7idCSSB6qf2SPr1Tpw6dJOSIe/t09YjEx1H/+KDhBFPnJS2X9cKBIkIiZC+u8OgVVV3vBbndNmLD0Yua1aoYWVY7darSB0m+R6X0qqKw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2hJ1Y7wKLCSFscxZ30kNyU27AfP1taOLcJtzl4iWuGM=; b=cJt+ncVawE82g54WXd9BAmTpppqN3MWDyr4yQhcfRxzdO1s4UjoZwNH8vfEnMRzeB0AT4ZjdC3OkP2OU/6Y1s/nA2iJF70OB5vONkaHNzPVeVF3LcYsuAX+xlmhuBbEIgx0JqQEepd2WMnMePpEAOrZwBiok/sywO+M8iRR+gdM= Received: from BYAPR11MB3671.namprd11.prod.outlook.com (20.178.206.79) by BYAPR11MB3030.namprd11.prod.outlook.com (20.177.225.91) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2516.12; Wed, 11 Dec 2019 11:36:26 +0000 Received: from BYAPR11MB3671.namprd11.prod.outlook.com ([fe80::5c22:16b9:2d35:4f0e]) by BYAPR11MB3671.namprd11.prod.outlook.com ([fe80::5c22:16b9:2d35:4f0e%3]) with mapi id 15.20.2516.018; Wed, 11 Dec 2019 11:36:26 +0000 From: "Sexton, Rory" To: Ori Kam , "dev@dpdk.org" CC: "Zhang, Qi Z" , "Xing, Beilei" , Adrien Mazarguil , "Jagus, DariuszX" Thread-Topic: [dpdk-dev] [PATCH] ethdev: add L2TPv3 header to flow API Thread-Index: AQHVqq1WuGnZL6ab8EC6Oc0BGrrb+aezMF2AgABIiPCAAGOWgIAA9PeQ Date: Wed, 11 Dec 2019 11:36:26 +0000 Message-ID: References: <20191204141055.3647-1-rory.sexton@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMmUzNmVmNDEtZDg1Yi00MzUyLWE0NzAtNjgyMDU5Njk3ZjExIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiVDFvbjByWEJzTmNIaHNTZyt4ZHpUVE1UOUpabFhHdldOaXJsVDY5TlB1Qm9YYitkT2FNUWhmcVlPVmo1N3VSZyJ9 dlp-reaction: no-action dlp-version: 11.2.0.6 dlp-product: dlpe-windows x-ctpclassification: CTP_NT authentication-results: spf=none (sender IP is ) smtp.mailfrom=rory.sexton@intel.com; x-originating-ip: [192.198.151.177] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 6f2bfe63-468f-4abf-78cc-08d77e2e5b6a x-ms-traffictypediagnostic: BYAPR11MB3030: x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:9508; x-forefront-prvs: 024847EE92 x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(39860400002)(136003)(346002)(376002)(366004)(396003)(51444003)(189003)(199004)(8676002)(5660300002)(110136005)(81166006)(26005)(64756008)(54906003)(9686003)(81156014)(186003)(7696005)(2906002)(55016002)(66446008)(316002)(6506007)(71200400001)(33656002)(107886003)(8936002)(52536014)(66946007)(4326008)(76116006)(86362001)(478600001)(66476007)(66556008); DIR:OUT; SFP:1102; SCL:1; SRVR:BYAPR11MB3030; H:BYAPR11MB3671.namprd11.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: KTzz2Fkle/nFVL3ktKuW8SAnYdl9azNDx0kSM18F8DUByRgimeu3fhJshyx1LJl5uanpH3Vu2jr4lQSWCEkoBrVuyfb5BDCTOcOGTStQrt2XeS9X5iyTTlP2udFfl1Cp8DKCi+T4W5npFWyLEDQ52sSZJpKEvLtzaAKGVeoqvmyKI/E28g2hQ7Sir643aF0JATW9PZZes7r4zCp48TUqKHHOO+1s4fQOR1lKJVNXxi669aSVrwYcg8NK/sZC1q+Ow69TzzG9HjryNLirgjPuGJnKh7p0//+6bLel1Msukbpk83B/Mrb81CxL+ycCzCfTAqrH1rQMx4cUnVBH6vyhLA9y5GAZnYACnzWdZ468r8OWV7D+5NZm8smK/eixQxpINuZY/vgBCA9zbkTzU96xeijGnSQNNCmDtf3C0NgEZs09HH32j07QVkl1g0n3OJAmk3DjYeyYkV3jhBSCbH3Jz8gGlPrIm1P1UrP3SPoa6gbcCyFsBnXCInpR7Ik5iQ3v Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 6f2bfe63-468f-4abf-78cc-08d77e2e5b6a X-MS-Exchange-CrossTenant-originalarrivaltime: 11 Dec 2019 11:36:26.2015 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: QGlaTPilQZ3xPJ7CUKjoi8RHsn5Wb7oD0WEBygK2acm8XeOzotNB0E95Te4TE6wHz1AUczfxXiPSBOOrLOWcAA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR11MB3030 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH] ethdev: add L2TPv3 header to flow API X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi Ori, See my comments below. Regards, Rory >>=20 >>> One general question why do we want to support only v3 and not also v2? >> l2tpv3 is more widely used as a tunneling protocol hence it's inclusion. >> A specific example is the cable industry where DOCSIS cable traffic is=20 >> encapsulated using depi and uepi protocols which both make use of=20 >> l2tpv3 session ids. >> Directing flows based on l2tpv3 can be very useful in these cases. >>=20 > >I'm not saying that v3 is not used more, I just thought from looking at th= e spec that both can be supported and the only difference is the version, s= o matching on the version we will be able to support both versions. >Your decision. > There is more difference between l2tpv2 and l2tpv3 than just the version nu= mber. In L2TPv2 there exists a 16 bit Tunnel ID and 16 bit Session ID. This is ch= anged to a 32 bit Session ID in L2TPv3 Please see difference in headers below for v2 and v3. Due to the differences between v2 and v3 I don't think both can be supporte= d with same flow item. L2TPv2 0...............................................15, 16.................= .....................31 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |T|L|x|x|S|x|O|P|x|x|x|x| Ver | Length (opt) = | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Tunnel ID | Session = ID | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Ns (opt) | Nr (o= pt) | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Offset Size (opt) | Offset pad... (opt)= | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ L2TPv3 0...............................................15, 16.................= .....................31 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Session ID = | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Cookie (optional, maximum 64 bits)... +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ = | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ >> >> +/** >> >> + * RTE_FLOW_ITEM_TYPE_L2TPV3. >> >> + * >> >> + * Matches a L2TPv3 header. >> >> + */ >> >> +struct rte_flow_item_l2tpv3 { >> >> + rte_be32_t session_id; /**< Session ID. */ }; >> > >> >Does it make sense that in future we will want to match on the T / L=20 >> >/ ver / >> Ns / Nr? >> > >> >Please also consider that any change will be ABI / API breakage,=20 >> >which will >> be allowed only next year. >> > >>=20 >> I don't foresee us wanting to match on any of the other fields, T / L=20 >> / ver / Ns/ Nr. >> The session id would typically be the only field of interest in the=20 >> l2tpv3 header. > > I think that adding all fields to the structure will solve the possible i= ssue with adding matching later. > Also and even more important you will be able to use it for creating the = raw_encap / raw_decap buffers. > >What do you think? Based on the differences between v2 and v3 the only field of interest in l2= tpv3 over IP is the Session ID. I agree it would make sense to add all fields if we were implementing l2tpv= 2 however v2 would require a different implementation to v3 due to the diff= erences between both Protocols.