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 23448A0471 for ; Fri, 16 Aug 2019 14:28:18 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 825181BEFD; Fri, 16 Aug 2019 14:28:16 +0200 (CEST) Received: from mail-vs1-f66.google.com (mail-vs1-f66.google.com [209.85.217.66]) by dpdk.org (Postfix) with ESMTP id 4B7A81BEF7 for ; Fri, 16 Aug 2019 14:28:15 +0200 (CEST) Received: by mail-vs1-f66.google.com with SMTP id q16so3611448vsm.2 for ; Fri, 16 Aug 2019 05:28:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to:cc; bh=tPy7vd3m7h/h3T5iGsrhucDzoUIAQw0BeDnf7ECmozY=; b=hN9LHjcDp9L1iuLZ+ZxmcIAId7qdEKs8l+2erFtGs5rIH7FVDmWYQIXuZ3BGfC60K6 0Zyk55l4edAF+xDBdHMZwdZv5kKHJl4zxMFgwCqfheC1/UPbeZjq+f3V3eSnL+ryABv3 D2D0rEgcYbiNMABNAXyjuywnUUGcuSxhAPZnHA52DHdF20zFw49MGGWkkk5goQ02lHxo zA+/xif7leWKcT5AfqkgPgzdBAjn+ujCljC5K770uyFLQNuqwIVmxXdwdpi4vFi+nDez yAgbvFTNh0Zp9+L7M6/CThYNGM8BYLxLKoHskF9Sda9umO9nOa4FqwqsRKFTxXUcp2t1 Qr7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=tPy7vd3m7h/h3T5iGsrhucDzoUIAQw0BeDnf7ECmozY=; b=WXqzeUtudsnPemzwLZ4Co/hdP7sNg6/I0RDgcnpweI48pnf/Y8OHrhJexRO3LXvdYt pjLBkkPcmhE4IyQMm8nnS3hVaArtG04336mGCv9wpgKOpBYYyPmkZ0d5i+pN9crnTUqE Dwjxm6pJKZ4M3plgxAAtLEGVKWhI5McQ/MpHuRC/DfbAOVE4AHuU+yvMLH/LxyTG0LPQ hF4YAlxkukAUGgoGUjDOoOC4nKnzS9C8FZSRgbnAfrqNd9VcifQBm2IZe08qWE+iKc2m VH9zqY9hAGmo/qJHYeIJ0LSGBAQv7hvshuyi7eu3CObHzWl0fxADt0CXzOov8xTTBdRE qpTw== X-Gm-Message-State: APjAAAUdxw9hij2mzIZaygD2WFKRMHOp9/qxX8YfEu84CRZ6S7ub1Lc7 QzJgPrgpXEs8//gsWdgqWVQnLmXpInuM6PxXNZBroNkk X-Google-Smtp-Source: APXvYqyOk33rtZk/PH7wDyMnQb3bP4HtCbPIKGHUWSqvlFlcawcHam9gZeQfR2mcg5JHTJPVR9C1lloyG4kEs2rme8o= X-Received: by 2002:a67:fc4b:: with SMTP id p11mr5967252vsq.2.1565958494431; Fri, 16 Aug 2019 05:28:14 -0700 (PDT) MIME-Version: 1.0 From: Victor Huertas Date: Fri, 16 Aug 2019 14:28:03 +0200 Message-ID: To: users@dpdk.org Cc: Vikutoru Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [dpdk-users] Understanding the 'offset' field on 'struct rte_acl_field_def' when creating an acl table in a pipeline X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: users-bounces@dpdk.org Sender: "users" Hi all, I am developing an application with DPDK (v17.11) using a concatenation of pipelines. Now I find myself on the definition of an ACL table and more precisely the format of the ACL fields. One of the parameters of this field format is the 'offset', which indicates the number of bytes till the start of the field to check. Now I have two questions: - It is possible to specify an ACL field placed on the headroom (ad-hoc fields defined by myself) or inside the rte_mbuf (like for example the VLAN TCI when VLAN stripping is enabled at the NIC)? All the examples I have seen so far assume that an offset value of 0 means the start of Ethernet header and not the start of rte_mbuf struct. Is there a way to place the offset start at the rte_mbuf struct? - If the type of the ACL field is RTE_ACL_FIELD_TYPE_RANGE, it seems to me that it can only be used if the length of the field is at least 1 byte and it is aligned with the 1 byte granularity that imposes the 'offset' field. Does the DPDK library allow me to define a RANGE of values of VLAN tag or Priority field in the 802.1Q header? It is true that it may be solved if I use RTE_ACL_FIELD_TYPE_BITMASK but this solution would obligue me to put N flows, one for each VLAN tag I want to filter. This is not efficient as depending on the range length it could translated it into hundreds of entries. A simple range would simplify it a lot. These to questions are important to me as it conditions the design of the pipelines of my application. I would appreciate it if some expert could help me clarify these two questions. Thanks a lot for your attention. -- Victor