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 73B2BA04F0; Mon, 13 Jan 2020 00:08:54 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B61001D57A; Mon, 13 Jan 2020 00:08:53 +0100 (CET) Received: from mail-qk1-f194.google.com (mail-qk1-f194.google.com [209.85.222.194]) by dpdk.org (Postfix) with ESMTP id 4B3CC1D550 for ; Mon, 13 Jan 2020 00:08:53 +0100 (CET) Received: by mail-qk1-f194.google.com with SMTP id a203so7020523qkc.3 for ; Sun, 12 Jan 2020 15:08:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id; bh=+2NlACIpI8i3hsImDMMo29JbtCOumORHUqIFSnkkDno=; b=Bc1cHweyHF3k8orPoDE/oxeJ5txVB9knsqeiNDvX/VxEbH6genP2bkwYe+ukqB5sjf hYNMvO7bmrFaYBtPGphr0aglpC0Vttk8sS+uxsbLaaC13cJcROex4UqkDSqVZCzR0TqQ U/5U7TwOZt/0InxrxbzH6VJ1kKsATaVbky7tbAkTsdgt8hiVmLL4h/ribmi9jdtwxNRR OuGGmNb8jWTvTk2+kciqb//1nWoBgp+OmfSX/a6Wgca8Gowr1oxLvFRzdnn8YGJS1Frx bmEuwrQyKKkqAoELlTAY9ORhRblLHaeTlbSVLcF0Ogv1mQwYDR5/+9MDDrf83kMkx1gf UjaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=+2NlACIpI8i3hsImDMMo29JbtCOumORHUqIFSnkkDno=; b=LJ8P83k0E1F7V/czgW45HPsEZxxOfb8yGA4qY/ROd/gVS8KN+JMNu5slAFjiPZRdh2 irN8/tobDf5Z5ChU772/qBBp3UPnBgszV5FzwEQzp08bOPJPumE6d2R+ylN2Deaxhv2a +Jzyi7opaQe42LKVyPCTY8jzlDT60ek+78aICMlYGqNDzM/b+FkX48wJ5FpqXCwdNLya P3tpeN3/PO92Vq++NxE50lRE6gHQ1WnAP1jlC9qjxmuUoJ+KKVkr/O0TinS9iVNayxhe JcexCzAhezP2hEp4PIM2iAj4xla4LTOWo1Q3tPVvMYXePeEjLBBr/RZ6v40HvyYhTx8R XSdQ== X-Gm-Message-State: APjAAAUJA3pX5PEFje1lb4AUJ91HB7TQRTZ7BOGnApP2jFGV7XN3X+HB 566AVMkQMPj4Wbwpd+FClE0= X-Google-Smtp-Source: APXvYqwxIXrNscbb8Ev7tnv2XLNgDlh7IvnO+DpwA6tBBdAxTc+lliz2tam4sRiN50aOAhf+IAm48Q== X-Received: by 2002:a05:620a:1327:: with SMTP id p7mr13679049qkj.148.1578870532693; Sun, 12 Jan 2020 15:08:52 -0800 (PST) Received: from sovaradhvm.ojp4suxva1celnnpiyhedynfde.bx.internal.cloudapp.net ([104.211.12.148]) by smtp.gmail.com with ESMTPSA id i23sm4174549qka.113.2020.01.12.15.08.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 12 Jan 2020 15:08:52 -0800 (PST) From: Sowmini Varadhan To: sowmini05@gmail.com, dev@dpdk.org Date: Sun, 12 Jan 2020 23:08:37 +0000 Message-Id: X-Mailer: git-send-email 2.17.1 Subject: [dpdk-dev] [PATCH RFC 0/2] TCP flow classification using 4-tuple and flags 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" An interesting class of problems is TCP flow tracking and classification based on TCP state, which requires the ability to classify TCP flows on more packet properties than just the 4-tuple This patch-set investigates the set of changes needed in the examples/flow_classify.c needed to achieve one instance of this class of problems by adding hooks to filter/classify on both the 4-tuple and tcp flags. Patch 1 extends examples/flow_classify.c to allow constraints on tcp flags. Patch 2 extends the ACL handling in librte_flow_classify to include keys on the properties in addition to the tcp 4-tuple. Note that one particular part of this patch-set where feedback is requested is in allocate_acl_ipv4_tcp_5tuple_rule(): we need to add a key for the 8 bit flags, but the multibit trie lookup moves in steps of 4 bytes, so it took some hackery to figure out what byte-ordering was expected, and there were no documentation/examples to provide guidelines. Comments/suggestions would be particularly helpful. Sowmini Varadhan (2): Hooks to allow the setting of filters on tcp flags Allow the flow_classify example to add an ACL table for tcp. examples/flow_classify/flow_classify.c | 113 ++++++++++++++++-- examples/flow_classify/ipv4_rules_file.txt | 22 ++-- lib/librte_flow_classify/rte_flow_classify.c | 84 +++++++++++++ lib/librte_flow_classify/rte_flow_classify.h | 19 +++ .../rte_flow_classify_parse.c | 8 +- 5 files changed, 221 insertions(+), 25 deletions(-) -- 2.20.1