Show a patch.

GET /api/patches/74713/
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 74713,
    "url": "https://patches.dpdk.org/api/patches/74713/",
    "web_url": "https://patches.dpdk.org/patch/74713/",
    "project": {
        "id": 1,
        "url": "https://patches.dpdk.org/api/projects/1/",
        "name": "DPDK",
        "link_name": "dpdk",
        "list_id": "dev.dpdk.org",
        "list_email": "dev@dpdk.org",
        "web_url": "http://core.dpdk.org",
        "scm_url": "git://dpdk.org/dpdk",
        "webscm_url": "http://git.dpdk.org/dpdk"
    },
    "msgid": "<20200724053235.71069-4-ajit.khaparde@broadcom.com>",
    "date": "2020-07-24T05:32:16",
    "name": "[v3,03/22] net/bnxt: configure parif for offload miss rules",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "fef73760cacd9400d080c9b6acdc8d42a24e26cd",
    "submitter": {
        "id": 501,
        "url": "https://patches.dpdk.org/api/people/501/",
        "name": "Ajit Khaparde",
        "email": "ajit.khaparde@broadcom.com"
    },
    "delegate": {
        "id": 1766,
        "url": "https://patches.dpdk.org/api/users/1766/",
        "username": "ajitkhaparde",
        "first_name": "Ajit",
        "last_name": "Khaparde",
        "email": "ajit.khaparde@broadcom.com"
    },
    "mbox": "https://patches.dpdk.org/patch/74713/mbox/",
    "series": [
        {
            "id": 11269,
            "url": "https://patches.dpdk.org/api/series/11269/",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=11269",
            "date": "2020-07-24T05:32:13",
            "name": "bnxt patches",
            "version": 3,
            "mbox": "https://patches.dpdk.org/series/11269/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/74713/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/74713/checks/",
    "tags": {},
    "headers": {
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "X-Gm-Message-State": "AOAM533ysPojdP4fVioFmTml4jmlkBt196F/KeWzMXpgmTP9RmlVJDML\n 0k5/iuiL9ry20qtqRKkI+m2GmIK3Vu/bJqy9mgeysbuoaSDudp4Tk4mjZ54DeaXvv2VE1aWAOmy\n rqNBu+jHEUmMvlaC+UFs3IOJ2FBgL3XpfZ+1xlZYr6VHKTSSaymJz7oY7uYBmXX0zTWOp45T8x2\n N+tA==",
        "X-Google-Smtp-Source": "\n ABdhPJxHOljz0uPUnR9CMQWWHJV2S/NLfN7fyrPr3vkcSVXamwNjvHvuNzylcZGqdU95NFnzwUOMrT2RjQlZ",
        "List-Post": "<mailto:dev@dpdk.org>",
        "MIME-Version": "1.0",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "X-BeenThere": "dev@dpdk.org",
        "References": "<20200723115639.22357-1-somnath.kotur@broadcom.com>\n <20200724053235.71069-1-ajit.khaparde@broadcom.com>",
        "Subject": "[dpdk-dev] [PATCH v3 03/22] net/bnxt: configure parif for offload\n\tmiss rules",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Received": [
            "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 73E21A0518;\n\tFri, 24 Jul 2020 07:33:19 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 71F4F1C069;\n\tFri, 24 Jul 2020 07:33:01 +0200 (CEST)",
            "from mail-vs1-f97.google.com (mail-vs1-f97.google.com\n [209.85.217.97]) by dpdk.org (Postfix) with ESMTP id 0BE111C033\n for <dev@dpdk.org>; Fri, 24 Jul 2020 07:32:58 +0200 (CEST)",
            "by mail-vs1-f97.google.com with SMTP id a17so4294015vsq.6\n for <dev@dpdk.org>; Thu, 23 Jul 2020 22:32:57 -0700 (PDT)",
            "from localhost.localdomain ([192.19.223.252])\n by smtp-relay.gmail.com with ESMTPS id h17sm592840vsk.0.2020.07.23.22.32.54\n (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128);\n Thu, 23 Jul 2020 22:32:57 -0700 (PDT)"
        ],
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "X-Mailer": "git-send-email 2.21.1 (Apple Git-122.3)",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20161025;\n h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n :references:mime-version:content-transfer-encoding;\n bh=yPlw7zKCs9xZnX0EY+Ul1xd9z8rV6ANE1DUYZEBLr44=;\n b=HddNlYGX9vuJmv/dKP3gdyZiLaA+XBCy/RK8W9A0aWgfktAMUqGI2FQ2qTJdeATHqx\n mp6YyqGYKXq/tbwKFnw4vcsiWR9K6p3CdynWskt91hjq34HN687YvDkyq/3h3XJhADPj\n Ue6uJ6mFFEiUzy8Q44x3oOXgskuG9/RXAP92lMdq3OcyR9GCSRz0EZoMpesjIzQIoCxM\n JkETuJl9ZHjhVmqpVugUZPr5p/X0oux12xCjof0CTmTgZe7reF5DqW87YnJNcNjlc8dI\n Pn3ikeTLzoq3TKl0xeUe7H63HxN50EAlZSj6cgOsWUQSJAu5Zf2t4iTFY/1Qzl7E7cW7\n IYaQ==",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com;\n s=google;\n h=from:to:cc:subject:date:message-id:in-reply-to:references\n :mime-version:content-transfer-encoding;\n bh=yPlw7zKCs9xZnX0EY+Ul1xd9z8rV6ANE1DUYZEBLr44=;\n b=eHzGWckIIRfpaZWQqbNukAV7AgBh4sJZYppGjaByQOADGYi2w4hRvkAxT1SWiTt00q\n v6NFgenb6uCOVyylN3Cnwlyb33aOQfkr33ipNJv1NIEzv+F/VqL9MN0AJ9AzM8dc1Thi\n dZBYh5x4aqNvYaNQsajS0pn+55KF+dVfJLftc=",
        "Date": "Thu, 23 Jul 2020 22:32:16 -0700",
        "Content-Transfer-Encoding": "8bit",
        "X-Received": "by 2002:a67:2e49:: with SMTP id u70mr6742180vsu.83.1595568777219;\n Thu, 23 Jul 2020 22:32:57 -0700 (PDT)",
        "To": "dev@dpdk.org",
        "X-Relaying-Domain": "broadcom.com",
        "From": "Ajit Khaparde <ajit.khaparde@broadcom.com>",
        "In-Reply-To": "<20200724053235.71069-1-ajit.khaparde@broadcom.com>",
        "Cc": "ferruh.yigit@intel.com,\n Kishore Padmanabha <kishore.padmanabha@broadcom.com>,\n Michael Baucom <michael.baucom@broadcom.com>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Message-Id": "<20200724053235.71069-4-ajit.khaparde@broadcom.com>",
        "Return-Path": "<dev-bounces@dpdk.org>"
    },
    "content": "From: Kishore Padmanabha <kishore.padmanabha@broadcom.com>\n\nPARIF is handler to a partition of the physical port.\nFor the offload miss rules, the parif miss path needs to be\nconsidered. The higher parif are reserved for handling this.\n\nSigned-off-by: Kishore Padmanabha <kishore.padmanabha@broadcom.com>\nReviewed-by: Michael Baucom <michael.baucom@broadcom.com>\nReviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>\n---\n drivers/net/bnxt/tf_ulp/ulp_def_rules.c  |  4 +--\n drivers/net/bnxt/tf_ulp/ulp_port_db.h    |  1 +\n drivers/net/bnxt/tf_ulp/ulp_rte_parser.c | 40 ++++++++++++++++++++++++\n 3 files changed, 43 insertions(+), 2 deletions(-)",
    "diff": "diff --git a/drivers/net/bnxt/tf_ulp/ulp_def_rules.c b/drivers/net/bnxt/tf_ulp/ulp_def_rules.c\nindex 4d4f7c4ea..d86e4c9ae 100644\n--- a/drivers/net/bnxt/tf_ulp/ulp_def_rules.c\n+++ b/drivers/net/bnxt/tf_ulp/ulp_def_rules.c\n@@ -12,8 +12,6 @@\n #include \"ulp_flow_db.h\"\n #include \"ulp_mapper.h\"\n \n-#define BNXT_ULP_FREE_PARIF_BASE 11\n-\n struct bnxt_ulp_def_param_handler {\n \tint32_t (*vfr_func)(struct bnxt_ulp_context *ulp_ctx,\n \t\t\t    struct ulp_tlv_param *param,\n@@ -85,6 +83,8 @@ ulp_set_parif_in_comp_fld(struct bnxt_ulp_context *ulp_ctx,\n \n \tif (parif_type == BNXT_ULP_PHY_PORT_PARIF) {\n \t\tidx = BNXT_ULP_CF_IDX_PHY_PORT_PARIF;\n+\t\t/* Parif needs to be reset to a free partition */\n+\t\tparif += BNXT_ULP_FREE_PARIF_BASE;\n \t} else if (parif_type == BNXT_ULP_DRV_FUNC_PARIF) {\n \t\tidx = BNXT_ULP_CF_IDX_DRV_FUNC_PARIF;\n \t\t/* Parif needs to be reset to a free partition */\ndiff --git a/drivers/net/bnxt/tf_ulp/ulp_port_db.h b/drivers/net/bnxt/tf_ulp/ulp_port_db.h\nindex 393d01b7c..2b323d168 100644\n--- a/drivers/net/bnxt/tf_ulp/ulp_port_db.h\n+++ b/drivers/net/bnxt/tf_ulp/ulp_port_db.h\n@@ -10,6 +10,7 @@\n \n #define BNXT_PORT_DB_MAX_INTF_LIST\t\t256\n #define BNXT_PORT_DB_MAX_FUNC\t\t\t2048\n+#define BNXT_ULP_FREE_PARIF_BASE\t\t11\n \n enum bnxt_ulp_svif_type {\n \tBNXT_ULP_DRV_FUNC_SVIF = 0,\ndiff --git a/drivers/net/bnxt/tf_ulp/ulp_rte_parser.c b/drivers/net/bnxt/tf_ulp/ulp_rte_parser.c\nindex 3891bcdc1..39f801b2f 100644\n--- a/drivers/net/bnxt/tf_ulp/ulp_rte_parser.c\n+++ b/drivers/net/bnxt/tf_ulp/ulp_rte_parser.c\n@@ -158,6 +158,43 @@ bnxt_ulp_rte_parser_act_parse(const struct rte_flow_action actions[],\n \treturn BNXT_TF_RC_SUCCESS;\n }\n \n+/*\n+ * Function to handle the post processing of the computed\n+ * fields for the interface.\n+ */\n+static void\n+bnxt_ulp_comp_fld_intf_update(struct ulp_rte_parser_params *params)\n+{\n+\tuint32_t ifindex;\n+\tuint16_t port_id, parif;\n+\tenum bnxt_ulp_direction_type dir;\n+\n+\t/* get the direction details */\n+\tdir = ULP_COMP_FLD_IDX_RD(params, BNXT_ULP_CF_IDX_DIRECTION);\n+\n+\tif (dir == BNXT_ULP_DIR_INGRESS) {\n+\t\t/* read the port id details */\n+\t\tport_id = ULP_COMP_FLD_IDX_RD(params,\n+\t\t\t\t\t      BNXT_ULP_CF_IDX_INCOMING_IF);\n+\t\tif (ulp_port_db_dev_port_to_ulp_index(params->ulp_ctx,\n+\t\t\t\t\t\t      port_id,\n+\t\t\t\t\t\t      &ifindex)) {\n+\t\t\tBNXT_TF_DBG(ERR, \"ParseErr:Portid is not valid\\n\");\n+\t\t\treturn;\n+\t\t}\n+\t\t/* Set port PARIF */\n+\t\tif (ulp_port_db_parif_get(params->ulp_ctx, ifindex,\n+\t\t\t\t\t  BNXT_ULP_PHY_PORT_PARIF, &parif)) {\n+\t\t\tBNXT_TF_DBG(ERR, \"ParseErr:ifindex is not valid\\n\");\n+\t\t\treturn;\n+\t\t}\n+\t\t/* Parif needs to be reset to a free partition */\n+\t\tparif += BNXT_ULP_FREE_PARIF_BASE;\n+\t\tULP_COMP_FLD_IDX_WR(params, BNXT_ULP_CF_IDX_PHY_PORT_PARIF,\n+\t\t\t\t    parif);\n+\t}\n+}\n+\n /*\n  * Function to handle the post processing of the parsing details\n  */\n@@ -213,6 +250,9 @@ bnxt_ulp_rte_parser_post_process(struct ulp_rte_parser_params *params)\n \t/* Merge the hdr_fp_bit into the proto header bit */\n \tparams->hdr_bitmap.bits |= params->hdr_fp_bit.bits;\n \n+\t/* Update the computed interface parameters */\n+\tbnxt_ulp_comp_fld_intf_update(params);\n+\n \t/* TBD: Handle the flow rejection scenarios */\n \treturn 0;\n }\n",
    "prefixes": [
        "v3",
        "03/22"
    ]
}