get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 81645,
    "url": "http://patches.dpdk.org/api/patches/81645/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20201020224846.1592682-15-qi.z.zhang@intel.com/",
    "project": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/projects/1/?format=api",
        "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",
        "list_archive_url": "https://inbox.dpdk.org/dev",
        "list_archive_url_format": "https://inbox.dpdk.org/dev/{}",
        "commit_url_format": ""
    },
    "msgid": "<20201020224846.1592682-15-qi.z.zhang@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20201020224846.1592682-15-qi.z.zhang@intel.com",
    "date": "2020-10-20T22:48:39",
    "name": "[14/21] net/ice/base: recognize 860 as iSCSI port in CEE mode",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "771f119fa1dd780d362a5e9419cb4a041de543d9",
    "submitter": {
        "id": 504,
        "url": "http://patches.dpdk.org/api/people/504/?format=api",
        "name": "Qi Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "delegate": {
        "id": 1540,
        "url": "http://patches.dpdk.org/api/users/1540/?format=api",
        "username": "qzhan15",
        "first_name": "Qi",
        "last_name": "Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/20201020224846.1592682-15-qi.z.zhang@intel.com/mbox/",
    "series": [
        {
            "id": 13156,
            "url": "http://patches.dpdk.org/api/series/13156/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=13156",
            "date": "2020-10-20T22:48:25",
            "name": "ice: update base code",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/13156/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/81645/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/81645/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@inbox.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 9CB49A04DD;\n\tWed, 21 Oct 2020 00:49:23 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id A70EEAD04;\n\tWed, 21 Oct 2020 00:45:26 +0200 (CEST)",
            "from mga14.intel.com (mga14.intel.com [192.55.52.115])\n by dpdk.org (Postfix) with ESMTP id 186E7ACD6\n for <dev@dpdk.org>; Wed, 21 Oct 2020 00:45:11 +0200 (CEST)",
            "from orsmga005.jf.intel.com ([10.7.209.41])\n by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 20 Oct 2020 15:45:11 -0700",
            "from dpdk51.sh.intel.com ([10.67.111.142])\n by orsmga005.jf.intel.com with ESMTP; 20 Oct 2020 15:45:10 -0700"
        ],
        "IronPort-SDR": [
            "\n BPLOsG2bFH1FGUnx+jTWmHBUoostddOEDJoHWuo5VITp7vzYdaNvpzLFOKSpH7t5cknTkzFVmf\n hMo2pcCIpv/A==",
            "\n bpXhTVkLVhRsDXKbJIfJXls5Gsh0wMazBFMOVUCE9IJqyXa3n11EZ7/r0kVHnx0x2+wydahyVb\n h/oTpZf53ZNg=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9780\"; a=\"166510627\"",
            "E=Sophos;i=\"5.77,399,1596524400\"; d=\"scan'208\";a=\"166510627\"",
            "E=Sophos;i=\"5.77,399,1596524400\"; d=\"scan'208\";a=\"533254675\""
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "From": "Qi Zhang <qi.z.zhang@intel.com>",
        "To": "qiming.yang@intel.com",
        "Cc": "dev@dpdk.org, Qi Zhang <qi.z.zhang@intel.com>,\n Chinh T Cao <chinh.t.cao@intel.com>",
        "Date": "Wed, 21 Oct 2020 06:48:39 +0800",
        "Message-Id": "<20201020224846.1592682-15-qi.z.zhang@intel.com>",
        "X-Mailer": "git-send-email 2.25.4",
        "In-Reply-To": "<20201020224846.1592682-1-qi.z.zhang@intel.com>",
        "References": "<20201020224846.1592682-1-qi.z.zhang@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH 14/21] net/ice/base: recognize 860 as iSCSI port\n\tin CEE mode",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "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-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "iSCSI can use both TCP ports 860 and 3260. However, in our current\nimplementation, the ice_aqc_opc_get_cee_dcb_cfg (0x0A07) AQ command\ndoesn't provide a way to communicate the protocol port number to the\nAQ's caller. Thus, we assume that 3260 is the iSCSI port number at the\nAQ's caller layer.\n\nIn this patch, we will rely on the dcbx-willing mode, desired QOS and\nremote QOS configuration to determine which port number that iSCSI will\nuse.\n\nSigned-off-by: Chinh T Cao <chinh.t.cao@intel.com>\nSigned-off-by: Qi Zhang <qi.z.zhang@intel.com>\n---\n drivers/net/ice/base/ice_dcb.c  | 38 +++++++++++++++++++++++++--------\n drivers/net/ice/base/ice_type.h | 35 +++++++++++++++++++-----------\n 2 files changed, 51 insertions(+), 22 deletions(-)",
    "diff": "diff --git a/drivers/net/ice/base/ice_dcb.c b/drivers/net/ice/base/ice_dcb.c\nindex f5f375a7a5..351038528b 100644\n--- a/drivers/net/ice/base/ice_dcb.c\n+++ b/drivers/net/ice/base/ice_dcb.c\n@@ -738,22 +738,27 @@ ice_aq_get_cee_dcb_cfg(struct ice_hw *hw,\n /**\n  * ice_cee_to_dcb_cfg\n  * @cee_cfg: pointer to CEE configuration struct\n- * @dcbcfg: DCB configuration struct\n+ * @pi: port information structure\n  *\n  * Convert CEE configuration from firmware to DCB configuration\n  */\n static void\n ice_cee_to_dcb_cfg(struct ice_aqc_get_cee_dcb_cfg_resp *cee_cfg,\n-\t\t   struct ice_dcbx_cfg *dcbcfg)\n+\t\t   struct ice_port_info *pi)\n {\n \tu32 status, tlv_status = LE32_TO_CPU(cee_cfg->tlv_status);\n \tu32 ice_aqc_cee_status_mask, ice_aqc_cee_status_shift;\n+\tu8 i, j, err, sync, oper, app_index, ice_app_sel_type;\n \tu16 app_prio = LE16_TO_CPU(cee_cfg->oper_app_prio);\n-\tu8 i, err, sync, oper, app_index, ice_app_sel_type;\n \tu16 ice_aqc_cee_app_mask, ice_aqc_cee_app_shift;\n+\tstruct ice_dcbx_cfg *cmp_dcbcfg, *dcbcfg;\n \tu16 ice_app_prot_id_type;\n \n-\t/* CEE PG data to ETS config */\n+\tdcbcfg = &pi->qos_cfg.local_dcbx_cfg;\n+\tdcbcfg->dcbx_mode = ICE_DCBX_MODE_CEE;\n+\tdcbcfg->tlv_status = tlv_status;\n+\n+\t/* CEE PG data */\n \tdcbcfg->etscfg.maxtcs = cee_cfg->oper_num_tc;\n \n \t/* Note that the FW creates the oper_prio_tc nibbles reversed\n@@ -780,10 +785,16 @@ ice_cee_to_dcb_cfg(struct ice_aqc_get_cee_dcb_cfg_resp *cee_cfg,\n \t\t}\n \t}\n \n-\t/* CEE PFC data to ETS config */\n+\t/* CEE PFC data */\n \tdcbcfg->pfc.pfcena = cee_cfg->oper_pfc_en;\n \tdcbcfg->pfc.pfccap = ICE_MAX_TRAFFIC_CLASS;\n \n+\t/* CEE APP TLV data */\n+\tif (dcbcfg->app_mode == ICE_DCBX_APPS_NON_WILLING)\n+\t\tcmp_dcbcfg = &pi->qos_cfg.desired_dcbx_cfg;\n+\telse\n+\t\tcmp_dcbcfg = &pi->qos_cfg.remote_dcbx_cfg;\n+\n \tapp_index = 0;\n \tfor (i = 0; i < 3; i++) {\n \t\tif (i == 0) {\n@@ -802,6 +813,18 @@ ice_cee_to_dcb_cfg(struct ice_aqc_get_cee_dcb_cfg_resp *cee_cfg,\n \t\t\tice_aqc_cee_app_shift = ICE_AQC_CEE_APP_ISCSI_S;\n \t\t\tice_app_sel_type = ICE_APP_SEL_TCPIP;\n \t\t\tice_app_prot_id_type = ICE_APP_PROT_ID_ISCSI;\n+\n+\t\t\tfor (j = 0; j < cmp_dcbcfg->numapps; j++) {\n+\t\t\t\tu16 prot_id = cmp_dcbcfg->app[j].prot_id;\n+\t\t\t\tu8 sel = cmp_dcbcfg->app[j].selector;\n+\n+\t\t\t\tif  (sel == ICE_APP_SEL_TCPIP &&\n+\t\t\t\t     (prot_id == ICE_APP_PROT_ID_ISCSI ||\n+\t\t\t\t      prot_id == ICE_APP_PROT_ID_ISCSI_860)) {\n+\t\t\t\t\tice_app_prot_id_type = prot_id;\n+\t\t\t\t\tbreak;\n+\t\t\t\t}\n+\t\t\t}\n \t\t} else {\n \t\t\t/* FIP APP */\n \t\t\tice_aqc_cee_status_mask = ICE_AQC_CEE_FIP_STATUS_M;\n@@ -892,11 +915,8 @@ enum ice_status ice_get_dcb_cfg(struct ice_port_info *pi)\n \tret = ice_aq_get_cee_dcb_cfg(pi->hw, &cee_cfg, NULL);\n \tif (ret == ICE_SUCCESS) {\n \t\t/* CEE mode */\n-\t\tdcbx_cfg = &pi->qos_cfg.local_dcbx_cfg;\n-\t\tdcbx_cfg->dcbx_mode = ICE_DCBX_MODE_CEE;\n-\t\tdcbx_cfg->tlv_status = LE32_TO_CPU(cee_cfg.tlv_status);\n-\t\tice_cee_to_dcb_cfg(&cee_cfg, dcbx_cfg);\n \t\tret = ice_get_ieee_or_cee_dcb_cfg(pi, ICE_DCBX_MODE_CEE);\n+\t\tice_cee_to_dcb_cfg(&cee_cfg, pi);\n \t} else if (pi->hw->adminq.sq_last_status == ICE_AQ_RC_ENOENT) {\n \t\t/* CEE mode not enabled try querying IEEE data */\n \t\tdcbx_cfg = &pi->qos_cfg.local_dcbx_cfg;\ndiff --git a/drivers/net/ice/base/ice_type.h b/drivers/net/ice/base/ice_type.h\nindex 3d231db61a..7545235635 100644\n--- a/drivers/net/ice/base/ice_type.h\n+++ b/drivers/net/ice/base/ice_type.h\n@@ -755,19 +755,28 @@ struct ice_dcb_app_priority_table {\n \tu8 selector;\n };\n \n-#define ICE_MAX_USER_PRIORITY\t8\n-#define ICE_DCBX_MAX_APPS\t32\n-#define ICE_LLDPDU_SIZE\t\t1500\n-#define ICE_TLV_STATUS_OPER\t0x1\n-#define ICE_TLV_STATUS_SYNC\t0x2\n-#define ICE_TLV_STATUS_ERR\t0x4\n-#define ICE_APP_PROT_ID_FCOE\t0x8906\n-#define ICE_APP_PROT_ID_ISCSI\t0x0cbc\n-#define ICE_APP_PROT_ID_FIP\t0x8914\n-#define ICE_APP_SEL_ETHTYPE\t0x1\n-#define ICE_APP_SEL_TCPIP\t0x2\n-#define ICE_CEE_APP_SEL_ETHTYPE\t0x0\n-#define ICE_CEE_APP_SEL_TCPIP\t0x1\n+#define ICE_MAX_USER_PRIORITY\t\t8\n+#define ICE_DCBX_MAX_APPS\t\t32\n+#define ICE_LLDPDU_SIZE\t\t\t1500\n+#define ICE_TLV_STATUS_OPER\t\t0x1\n+#define ICE_TLV_STATUS_SYNC\t\t0x2\n+#define ICE_TLV_STATUS_ERR\t\t0x4\n+#ifndef ICE_APP_PROT_ID_FCOE\n+#define ICE_APP_PROT_ID_FCOE\t\t0x8906\n+#endif /* ICE_APP_PROT_ID_FCOE */\n+#ifndef ICE_APP_PROT_ID_ISCSI\n+#define ICE_APP_PROT_ID_ISCSI\t\t0x0cbc\n+#endif /* ICE_APP_PROT_ID_ISCSI */\n+#ifndef ICE_APP_PROT_ID_ISCSI_860\n+#define ICE_APP_PROT_ID_ISCSI_860\t0x035c\n+#endif /* ICE_APP_PROT_ID_ISCSI_860 */\n+#ifndef ICE_APP_PROT_ID_FIP\n+#define ICE_APP_PROT_ID_FIP\t\t0x8914\n+#endif /* ICE_APP_PROT_ID_FIP */\n+#define ICE_APP_SEL_ETHTYPE\t\t0x1\n+#define ICE_APP_SEL_TCPIP\t\t0x2\n+#define ICE_CEE_APP_SEL_ETHTYPE\t\t0x0\n+#define ICE_CEE_APP_SEL_TCPIP\t\t0x1\n \n struct ice_dcbx_cfg {\n \tu32 numapps;\n",
    "prefixes": [
        "14/21"
    ]
}