Show a patch.

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

{
    "id": 74530,
    "url": "https://patches.dpdk.org/api/patches/74530/",
    "web_url": "https://patches.dpdk.org/patch/74530/",
    "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": "<20200721074000.30449-8-guinanx.sun@intel.com>",
    "date": "2020-07-21T07:39:59",
    "name": "[7/8] net/i40e/base: replace AQ command for NVM update",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "30092d0dfd3779cc097293ff49d7a04028ec6781",
    "submitter": {
        "id": 1476,
        "url": "https://patches.dpdk.org/api/people/1476/",
        "name": "Guinan Sun",
        "email": "guinanx.sun@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/74530/mbox/",
    "series": [
        {
            "id": 11193,
            "url": "https://patches.dpdk.org/api/series/11193/",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=11193",
            "date": "2020-07-21T07:39:52",
            "name": "update i40e base code",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/11193/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/74530/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/74530/checks/",
    "tags": {},
    "headers": {
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9688\"; a=\"147586180\"",
            "E=Sophos;i=\"5.75,378,1589266800\"; d=\"scan'208\";a=\"147586180\"",
            "E=Sophos;i=\"5.75,378,1589266800\"; d=\"scan'208\";a=\"301541691\""
        ],
        "IronPort-SDR": [
            "\n 7/9tL/n8ID2ROKrMlPzYXHb5aRB/jYk4WtuE6u3d8Bj68y/4sjQXMHbvXiFxWxCm5fbzR2HFzM\n K/lzg2khGlbg==",
            "\n r5kP47QALDR68LwLgxP15vkf3Mq3GO6EExrNcxJsDXnHI+q4lvDzdR5jYpnmr24LIDeYc6VyQ6\n /YFVpS9wLttw=="
        ],
        "X-Amp-File-Uploaded": "False",
        "Precedence": "list",
        "X-Mailman-Version": "2.1.15",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "X-BeenThere": "dev@dpdk.org",
        "References": "<20200721074000.30449-1-guinanx.sun@intel.com>",
        "Subject": "[dpdk-dev] [PATCH 7/8] net/i40e/base: replace AQ command for NVM\n\tupdate",
        "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 E063FA0526;\n\tTue, 21 Jul 2020 10:05:42 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id C0F7B1C0AC;\n\tTue, 21 Jul 2020 10:04:50 +0200 (CEST)",
            "from mga04.intel.com (mga04.intel.com [192.55.52.120])\n by dpdk.org (Postfix) with ESMTP id 2DE4A1C07D\n for <dev@dpdk.org>; Tue, 21 Jul 2020 10:04:49 +0200 (CEST)",
            "from orsmga002.jf.intel.com ([10.7.209.21])\n by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 21 Jul 2020 01:04:48 -0700",
            "from intel.sh.intel.com ([10.239.255.18])\n by orsmga002.jf.intel.com with ESMTP; 21 Jul 2020 01:04:46 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "X-Mailer": "git-send-email 2.17.1",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "X-ExtLoop1": "1",
        "Date": "Tue, 21 Jul 2020 07:39:59 +0000",
        "To": "dev@dpdk.org",
        "From": "Guinan Sun <guinanx.sun@intel.com>",
        "In-Reply-To": "<20200721074000.30449-1-guinanx.sun@intel.com>",
        "Cc": "Beilei Xing <beilei.xing@intel.com>, Jeff Guo <jia.guo@intel.com>,\n Guinan Sun <guinanx.sun@intel.com>,\n Jaroslaw Ilgiewicz <jaroslaw.ilgiewicz@intel.com>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Message-Id": "<20200721074000.30449-8-guinanx.sun@intel.com>",
        "Return-Path": "<dev-bounces@dpdk.org>"
    },
    "content": "Add AQ command \"NVM update in process\"\nto replace the original AQ command \"NVM progress\".\n\nSigned-off-by: Jaroslaw Ilgiewicz <jaroslaw.ilgiewicz@intel.com>\nSigned-off-by: Guinan Sun <guinanx.sun@intel.com>\n---\n drivers/net/i40e/base/i40e_adminq_cmd.h | 12 +++++-\n drivers/net/i40e/base/i40e_common.c     | 53 +++++++++++++++----------\n drivers/net/i40e/base/i40e_prototype.h  |  6 ++-\n 3 files changed, 46 insertions(+), 25 deletions(-)",
    "diff": "diff --git a/drivers/net/i40e/base/i40e_adminq_cmd.h b/drivers/net/i40e/base/i40e_adminq_cmd.h\nindex c7686b0d3..0766e69a8 100644\n--- a/drivers/net/i40e/base/i40e_adminq_cmd.h\n+++ b/drivers/net/i40e/base/i40e_adminq_cmd.h\n@@ -240,7 +240,7 @@ enum i40e_admin_queue_opc {\n \ti40e_aqc_opc_nvm_update\t\t\t= 0x0703,\n \ti40e_aqc_opc_nvm_config_read\t\t= 0x0704,\n \ti40e_aqc_opc_nvm_config_write\t\t= 0x0705,\n-\ti40e_aqc_opc_nvm_progress\t\t= 0x0706,\n+\ti40e_aqc_opc_nvm_update_in_process\t= 0x0706,\n \ti40e_aqc_opc_oem_post_update\t\t= 0x0720,\n \ti40e_aqc_opc_thermal_sensor\t\t= 0x0721,\n \n@@ -2400,6 +2400,16 @@ struct i40e_aqc_nvm_config_data_feature {\n \n I40E_CHECK_STRUCT_LEN(0x6, i40e_aqc_nvm_config_data_feature);\n \n+/* NVM Update in Process (direct 0x0706) */\n+struct i40e_aqc_nvm_update_in_process {\n+\tu8\tcommand;\n+#define I40E_AQ_UPDATE_FLOW_END\t\t\t0x0\n+#define I40E_AQ_UPDATE_FLOW_START\t\t0x1\n+\tu8\treserved[15];\n+};\n+\n+I40E_CHECK_CMD_LENGTH(i40e_aqc_nvm_update_in_process);\n+\n struct i40e_aqc_nvm_config_data_immediate_field {\n \t__le32 field_id;\n \t__le32 field_value;\ndiff --git a/drivers/net/i40e/base/i40e_common.c b/drivers/net/i40e/base/i40e_common.c\nindex 65317f6c6..6c6fb4de4 100644\n--- a/drivers/net/i40e/base/i40e_common.c\n+++ b/drivers/net/i40e/base/i40e_common.c\n@@ -3686,6 +3686,37 @@ enum i40e_status_code i40e_aq_write_nvm_config(struct i40e_hw *hw,\n \treturn status;\n }\n \n+/**\n+ * i40e_aq_nvm_update_in_process\n+ * @hw: pointer to the hw struct\n+ * @update_flow_state: True indicates that update flow starts, false that ends\n+ * @cmd_details: pointer to command details structure or NULL\n+ *\n+ * Indicate NVM update in process.\n+ **/\n+enum i40e_status_code\n+i40e_aq_nvm_update_in_process(struct i40e_hw *hw,\n+\t\t\t      bool update_flow_state,\n+\t\t\t      struct i40e_asq_cmd_details *cmd_details)\n+{\n+\tstruct i40e_aq_desc desc;\n+\tstruct i40e_aqc_nvm_update_in_process *cmd =\n+\t\t(struct i40e_aqc_nvm_update_in_process *)&desc.params.raw;\n+\tenum i40e_status_code status;\n+\n+\ti40e_fill_default_direct_cmd_desc(&desc,\n+\t\t\t\t\t  i40e_aqc_opc_nvm_update_in_process);\n+\n+\tcmd->command = I40E_AQ_UPDATE_FLOW_END;\n+\n+\tif (update_flow_state)\n+\t\tcmd->command |= I40E_AQ_UPDATE_FLOW_START;\n+\n+\tstatus = i40e_asq_send_command(hw, &desc, NULL, 0, cmd_details);\n+\n+\treturn status;\n+}\n+\n /**\n  * i40e_aq_oem_post_update - triggers an OEM specific flow after update\n  * @hw: pointer to the hw struct\n@@ -4257,28 +4288,6 @@ enum i40e_status_code i40e_aq_rearrange_nvm(struct i40e_hw *hw,\n \treturn status;\n }\n \n-/**\n- * i40e_aq_nvm_progress\n- * @hw: pointer to the hw struct\n- * @progress: pointer to progress returned from AQ\n- * @cmd_details: pointer to command details structure or NULL\n- *\n- * Gets progress of flash rearrangement process\n- **/\n-enum i40e_status_code i40e_aq_nvm_progress(struct i40e_hw *hw, u8 *progress,\n-\t\t\t\tstruct i40e_asq_cmd_details *cmd_details)\n-{\n-\tenum i40e_status_code status;\n-\tstruct i40e_aq_desc desc;\n-\n-\tDEBUGFUNC(\"i40e_aq_nvm_progress\");\n-\n-\ti40e_fill_default_direct_cmd_desc(&desc, i40e_aqc_opc_nvm_progress);\n-\tstatus = i40e_asq_send_command(hw, &desc, NULL, 0, cmd_details);\n-\t*progress = desc.params.raw[0];\n-\treturn status;\n-}\n-\n /**\n  * i40e_aq_get_lldp_mib\n  * @hw: pointer to the hw struct\ndiff --git a/drivers/net/i40e/base/i40e_prototype.h b/drivers/net/i40e/base/i40e_prototype.h\nindex 91fa23491..9a89f3002 100644\n--- a/drivers/net/i40e/base/i40e_prototype.h\n+++ b/drivers/net/i40e/base/i40e_prototype.h\n@@ -254,8 +254,10 @@ enum i40e_status_code i40e_aq_update_nvm(struct i40e_hw *hw, u8 module_pointer,\n enum i40e_status_code i40e_aq_rearrange_nvm(struct i40e_hw *hw,\n \t\t\t\tu8 rearrange_nvm,\n \t\t\t\tstruct i40e_asq_cmd_details *cmd_details);\n-enum i40e_status_code i40e_aq_nvm_progress(struct i40e_hw *hw, u8 *progress,\n-\t\t\t\tstruct i40e_asq_cmd_details *cmd_details);\n+enum i40e_status_code\n+i40e_aq_nvm_update_in_process(struct i40e_hw *hw,\n+\t\t\t      bool update_flow_state,\n+\t\t\t      struct i40e_asq_cmd_details *cmd_details);\n enum i40e_status_code i40e_aq_get_lldp_mib(struct i40e_hw *hw, u8 bridge_type,\n \t\t\t\tu8 mib_type, void *buff, u16 buff_size,\n \t\t\t\tu16 *local_len, u16 *remote_len,\n",
    "prefixes": [
        "7/8"
    ]
}