Show a patch.

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

{
    "id": 73417,
    "url": "https://patches.dpdk.org/api/patches/73417/",
    "web_url": "https://patches.dpdk.org/patch/73417/",
    "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": "<20200707094048.17690-3-wei.zhao1@intel.com>",
    "date": "2020-07-07T09:40:48",
    "name": "[2/2] net/ice/base: fix add special words for tunnel rule",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "387dccdc7be5781ea8337b952f3e017d6be66ef9",
    "submitter": {
        "id": 495,
        "url": "https://patches.dpdk.org/api/people/495/",
        "name": "Zhao1, Wei",
        "email": "wei.zhao1@intel.com"
    },
    "delegate": {
        "id": 1540,
        "url": "https://patches.dpdk.org/api/users/1540/",
        "username": "qzhan15",
        "first_name": "Qi",
        "last_name": "Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "mbox": "https://patches.dpdk.org/patch/73417/mbox/",
    "series": [
        {
            "id": 10844,
            "url": "https://patches.dpdk.org/api/series/10844/",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=10844",
            "date": "2020-07-07T09:40:46",
            "name": "update base code batch 4",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/10844/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/73417/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/73417/checks/",
    "tags": {},
    "headers": {
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "Return-Path": "<dev-bounces@dpdk.org>",
        "IronPort-SDR": [
            "\n eOvxBRx5F+RVtzO1UhsyqJY7As0Zi3jCROVg8G521pE2gE61HCzHzL9FqR9MDVJwKKewTUT1E7\n EM6ldAvxvGOA==",
            "\n Z419xhmxMbhm3erLNcjZ2ErYUYJFv9Us+SSrfjip+BgKV0rvyRyc7TKjTemZsFYvOBghlzSRW5\n aDEgGCuRl04g=="
        ],
        "X-Mailer": "git-send-email 2.19.1",
        "To": "dev@dpdk.org",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Received": [
            "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 1B8C9A00BE;\n\tTue,  7 Jul 2020 12:06:10 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 0E58D1DDAC;\n\tTue,  7 Jul 2020 12:06:00 +0200 (CEST)",
            "from mga09.intel.com (mga09.intel.com [134.134.136.24])\n by dpdk.org (Postfix) with ESMTP id AA30E1DD92;\n Tue,  7 Jul 2020 12:05:57 +0200 (CEST)",
            "from fmsmga008.fm.intel.com ([10.253.24.58])\n by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 07 Jul 2020 03:05:57 -0700",
            "from unknown (HELO localhost.localdomain.bj.intel.com)\n ([172.16.182.123])\n by fmsmga008.fm.intel.com with ESMTP; 07 Jul 2020 03:05:55 -0700"
        ],
        "X-BeenThere": "dev@dpdk.org",
        "X-Amp-File-Uploaded": "False",
        "Subject": "[dpdk-dev] [PATCH 2/2] net/ice/base: fix add special words for\n\ttunnel rule",
        "Cc": "qi.z.zhang@intel.com, nannan.lu@intel.com, stable@dpdk.org,\n Wei Zhao <wei.zhao1@intel.com>",
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "In-Reply-To": "<20200707094048.17690-1-wei.zhao1@intel.com>",
        "Precedence": "list",
        "X-ExtLoop1": "1",
        "From": "Wei Zhao <wei.zhao1@intel.com>",
        "Content-Transfer-Encoding": "8bit",
        "MIME-Version": "1.0",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9674\"; a=\"149075715\"",
            "E=Sophos;i=\"5.75,323,1589266800\"; d=\"scan'208\";a=\"149075715\"",
            "E=Sophos;i=\"5.75,323,1589266800\"; d=\"scan'208\";a=\"268159352\""
        ],
        "References": "<20200707094048.17690-1-wei.zhao1@intel.com>",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "Errors-To": "dev-bounces@dpdk.org",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "Message-Id": "<20200707094048.17690-3-wei.zhao1@intel.com>",
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Date": "Tue,  7 Jul 2020 17:40:48 +0800",
        "X-Mailman-Version": "2.1.15"
    },
    "content": "if we download a NVGRE rule like \"eth / ipv4 / nvgre / eth / ipv4 src\nis 192.168.1.2 dst is 192.168.1.3 / end actions queue index 3 / end\"\nthe special word will not be added because of rm->n_grp_count = 1,\nso we have to change the ice_add_special_words() function before\nice_create_recipe_group(), then the special words will be add\ninto rm->rg_list, btw the flag match_tun_mask is useless now\nand no need to add special words in function\nice_add_sw_recipe() duplicatly.\n\nFixes: eda40e22b858 (\"net/ice/base: improve switch chained recipe\")\nCc: stable@dpdk.org\n\nSigned-off-by: Wei Zhao <wei.zhao1@intel.com>\n---\n drivers/net/ice/base/ice_switch.c | 38 ++++++++-----------------------\n 1 file changed, 9 insertions(+), 29 deletions(-)",
    "diff": "diff --git a/drivers/net/ice/base/ice_switch.c b/drivers/net/ice/base/ice_switch.c\nindex caa080da2..296aa5484 100644\n--- a/drivers/net/ice/base/ice_switch.c\n+++ b/drivers/net/ice/base/ice_switch.c\n@@ -5993,12 +5993,11 @@ ice_find_free_recp_res_idx(struct ice_hw *hw, const ice_bitmap_t *profiles,\n  * ice_add_sw_recipe - function to call AQ calls to create switch recipe\n  * @hw: pointer to hardware structure\n  * @rm: recipe management list entry\n- * @match_tun_mask: tunnel mask that needs to be programmed\n  * @profiles: bitmap of profiles that will be associated.\n  */\n static enum ice_status\n ice_add_sw_recipe(struct ice_hw *hw, struct ice_sw_recipe *rm,\n-\t\t  u16 match_tun_mask, ice_bitmap_t *profiles)\n+\t\t  ice_bitmap_t *profiles)\n {\n \tice_declare_bitmap(result_idx_bm, ICE_MAX_FV_WORDS);\n \tstruct ice_aqc_recipe_data_elem *tmp;\n@@ -6213,15 +6212,6 @@ ice_add_sw_recipe(struct ice_hw *hw, struct ice_sw_recipe *rm,\n \t\t}\n \t\tbuf[recps].content.act_ctrl_fwd_priority = rm->priority;\n \n-\t\t/* To differentiate among different UDP tunnels, a meta data ID\n-\t\t * flag is used.\n-\t\t */\n-\t\tif (match_tun_mask) {\n-\t\t\tbuf[recps].content.lkup_indx[i] = ICE_TUN_FLAG_FV_IND;\n-\t\t\tbuf[recps].content.mask[i] =\n-\t\t\t\tCPU_TO_LE16(match_tun_mask);\n-\t\t}\n-\n \t\trecps++;\n \t\trm->root_rid = (u8)rid;\n \t}\n@@ -6596,8 +6586,6 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups,\n \tstruct ice_sw_fv_list_entry *tmp;\n \tenum ice_status status = ICE_SUCCESS;\n \tstruct ice_sw_recipe *rm;\n-\tu16 match_tun_mask = 0;\n-\tu16 mask;\n \tu8 i;\n \n \tif (!ice_is_prof_rule(rinfo->tun_type) && !lkups_cnt)\n@@ -6648,6 +6636,13 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups,\n \tif (status)\n \t\tgoto err_unroll;\n \n+\t/* Create any special protocol/offset pairs, such as looking at tunnel\n+\t * bits by extracting metadata\n+\t */\n+\tstatus = ice_add_special_words(rinfo, lkup_exts);\n+\tif (status)\n+\t\tgoto err_free_lkup_exts;\n+\n \t/* Group match words into recipes using preferred recipe grouping\n \t * criteria.\n \t */\n@@ -6655,14 +6650,6 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups,\n \tif (status)\n \t\tgoto err_unroll;\n \n-\t/* For certain tunnel types it is necessary to use a metadata ID flag to\n-\t * differentiate different tunnel types. A separate recipe needs to be\n-\t * used for the metadata.\n-\t */\n-\tif (ice_tun_type_match_word(rinfo->tun_type, &mask) &&\n-\t    rm->n_grp_count > 1)\n-\t\tmatch_tun_mask = mask;\n-\n \t/* set the recipe priority if specified */\n \trm->priority = (u8)rinfo->priority;\n \n@@ -6701,13 +6688,6 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups,\n \t\tice_set_bit((u16)fvit->profile_id, profiles);\n \t}\n \n-\t/* Create any special protocol/offset pairs, such as looking at tunnel\n-\t * bits by extracting metadata\n-\t */\n-\tstatus = ice_add_special_words(rinfo, lkup_exts);\n-\tif (status)\n-\t\tgoto err_free_lkup_exts;\n-\n \t/* Look for a recipe which matches our requested fv / mask list */\n \t*rid = ice_find_recp(hw, lkup_exts, rinfo->tun_type);\n \tif (*rid < ICE_MAX_NUM_RECIPES)\n@@ -6716,7 +6696,7 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups,\n \n \trm->tun_type = rinfo->tun_type;\n \t/* Recipe we need does not exist, add a recipe */\n-\tstatus = ice_add_sw_recipe(hw, rm, match_tun_mask, profiles);\n+\tstatus = ice_add_sw_recipe(hw, rm, profiles);\n \tif (status)\n \t\tgoto err_unroll;\n \n",
    "prefixes": [
        "2/2"
    ]
}