From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f54.google.com (mail-wm0-f54.google.com [74.125.82.54]) by dpdk.org (Postfix) with ESMTP id D0B9C377E; Tue, 2 May 2017 11:28:49 +0200 (CEST) Received: by mail-wm0-f54.google.com with SMTP id u65so105915234wmu.1; Tue, 02 May 2017 02:28:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=p7FvxujQWnL2riYsVLs7cd4o8IGtxGCSB2SVpF4Um1A=; b=eGmJ4XwFaNAKcM28tUz5yKu7xgqI0d/JjGRUHjr4NcrRLbk0qQ5QHDpvgslFrsjdpx d8VDtEquqsLfarNkH/gyNxQcI8P1cSooAsWOXjoX5gsbkvxMrZpriRchWBBQdFCtji+i tv2ywp3XKa1chv47vbwES0AkmYp2Qv32l5HGumXwkhQLzWNeWMfBj9hX7mdxGI0FasSt iuNR0E3zOp18CmczW8kjtiFFJMaI0mikbIrqBsQ8Lsrtid0GlEdnwnfwRcjirzdK+WSZ f1T34Bl19xJJ4gUMGQBH+FJCCGt66u/u1Z3oqzeMVmn7cLAJHNa+TTwYMdwAgFkPIM7B oy4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=p7FvxujQWnL2riYsVLs7cd4o8IGtxGCSB2SVpF4Um1A=; b=VeCrztpjJePjQSgW73yRw7qlaVtREYZ2cQI9Man0oL4CepQyhdDr181nMjQujc8drn LWk5B6CGBKctZq79uIAXo8cxOp/VkFxTGVO7hla3xlESso4p95XL5pjClg5g1SKXmYdy bdS4s1JobYIqBfwyEJlLrtbu67DHLN/jw4uu/ZcHl6uli+wVWw337UQOZ3nd7i+HwrLg 1irDZ4Ml68UQ4PtMM/6VJ7BJM0B7bbaTrHFjH9ZL52YLaUdisQNGvTDbZwyERcPgIgcN TxNuB7eqe11AppL87yFmu/mEj37DTN3tBKY70oyoHvT5slOP/pgtzYPTZ4fRP8aR/NcY 9leQ== X-Gm-Message-State: AN3rC/7QHz3krGxdIIqz+zxZ19FPhYQ6DEDyoo+A4qDOiRaTYgekROSG ZGv4YlywHXCdJrXuujIwFEU+7Smwdg== X-Received: by 10.28.198.10 with SMTP id w10mr1420703wmf.1.1493717329659; Tue, 02 May 2017 02:28:49 -0700 (PDT) MIME-Version: 1.0 Received: by 10.223.130.42 with HTTP; Tue, 2 May 2017 02:28:48 -0700 (PDT) In-Reply-To: <54CBAA185211B4429112C315DA58FF6D31B5BCDF@IRSMSX103.ger.corp.intel.com> References: <54CBAA185211B4429112C315DA58FF6D31B5BCDF@IRSMSX103.ger.corp.intel.com> From: Nidhia Varghese Date: Tue, 2 May 2017 14:58:48 +0530 Message-ID: To: "Singh, Jasvinder" Cc: "dev@dpdk.org" , "users@dpdk.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-users] Adding multiple fields as key in ip_pipeline application 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: , X-List-Received-Date: Tue, 02 May 2017 09:28:50 -0000 Hi, Can we do the append/prepend (of the port id with vlan id) through config file? Thanks, Nidhia On Fri, Apr 28, 2017 at 7:24 PM, Singh, Jasvinder wrote: > Hi Nidhia, > > > I am developing an application in which I need to use both incoming port > and vlan as the key for the flow table. Port field is available at 24th > byte of mbuf and vlan(single tagged) will be at 268th byte (128 mbuf + 128 > headroom + 12 ethernet header). > How can I represent this in my config file in the src_mask field? > Is there any way to take these fields separately and keep in headroom and > then use them to calculate hash for lookup? > > > [Jasvinder] - If you look at edge_router_upstream.cfg, pass-through > pipeline have mask and offset defined for extracting the key from the > packet header and storing in the headroom at the offset 128. This key is > used in flow_classification pipeline to classify the flows. You can follow > similar approach by using pass-through pipeline doing that action at the > input port. For that, define mask (00000000FFFFFFFF) and offset fields for > extracting the vlan-tag from the packet in pass-through pipeline and store > at the desired offset in the headroom and prepend the vlan tag stored in > the metadata with port id read from mbuf. In flow-classification pipeline, > you can specify the headroom offset and mask to read the final key > (portid+vlan tag) stored in the packet-metadata for classification. > > > > Thanks for your reply and help. > > > Regards, > Nidhia Varghese > -- Regards, Nidhia Varghese