get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 94624,
    "url": "https://patches.dpdk.org/api/patches/94624/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20210621150619.463430-2-qi.z.zhang@intel.com/",
    "project": {
        "id": 1,
        "url": "https://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": "<20210621150619.463430-2-qi.z.zhang@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20210621150619.463430-2-qi.z.zhang@intel.com",
    "date": "2021-06-21T15:06:16",
    "name": "[1/4] net/ice/base: add function for DSCP configure",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "c3feedc298278af6aa1b626ebf7121ef71ddc6bb",
    "submitter": {
        "id": 504,
        "url": "https://patches.dpdk.org/api/people/504/?format=api",
        "name": "Qi Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "delegate": {
        "id": 1540,
        "url": "https://patches.dpdk.org/api/users/1540/?format=api",
        "username": "qzhan15",
        "first_name": "Qi",
        "last_name": "Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20210621150619.463430-2-qi.z.zhang@intel.com/mbox/",
    "series": [
        {
            "id": 17425,
            "url": "https://patches.dpdk.org/api/series/17425/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=17425",
            "date": "2021-06-21T15:06:17",
            "name": "ice base code update",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/17425/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/94624/comments/",
    "check": "warning",
    "checks": "https://patches.dpdk.org/api/patches/94624/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 mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 61108A0547;\n\tMon, 21 Jun 2021 17:03:37 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 2C8DD411CA;\n\tMon, 21 Jun 2021 17:03:31 +0200 (CEST)",
            "from mga17.intel.com (mga17.intel.com [192.55.52.151])\n by mails.dpdk.org (Postfix) with ESMTP id 24D18411C3\n for <dev@dpdk.org>; Mon, 21 Jun 2021 17:03:27 +0200 (CEST)",
            "from fmsmga008.fm.intel.com ([10.253.24.58])\n by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 21 Jun 2021 08:03:07 -0700",
            "from dpdk51.sh.intel.com ([10.67.111.142])\n by fmsmga008.fm.intel.com with ESMTP; 21 Jun 2021 08:03:05 -0700"
        ],
        "IronPort-SDR": [
            "\n Gu4z315mLjey2XCHOGILrAVv9CbnXBclTaV+VCgfakceswIJ3jCex45DziPGVkf5tQXiab6/Dt\n T6l9D6j6Mc5A==",
            "\n UoiC8ivLl9QQKpcDUUhfnm9Zva/PX45MDbhI76yMfnuP0LrtMbVbomnli1Q9LQisOIvEF5aeK5\n pBeg45JEl0kw=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6200,9189,10022\"; a=\"187239567\"",
            "E=Sophos;i=\"5.83,289,1616482800\"; d=\"scan'208\";a=\"187239567\"",
            "E=Sophos;i=\"5.83,289,1616482800\"; d=\"scan'208\";a=\"453911985\""
        ],
        "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 Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>",
        "Date": "Mon, 21 Jun 2021 23:06:16 +0800",
        "Message-Id": "<20210621150619.463430-2-qi.z.zhang@intel.com>",
        "X-Mailer": "git-send-email 2.26.2",
        "In-Reply-To": "<20210621150619.463430-1-qi.z.zhang@intel.com>",
        "References": "<20210621150619.463430-1-qi.z.zhang@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH 1/4] net/ice/base: add function for DSCP configure",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.29",
        "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": "ice_aq_set_pfc_mode is used to configure DSCP.\n\nSigned-off-by: Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>\nSigned-off-by: Qi Zhang <qi.z.zhang@intel.com>\n---\n drivers/net/ice/base/ice_dcb.c | 41 ++++++++++++++++++++++++++++++++++\n drivers/net/ice/base/ice_dcb.h |  2 ++\n 2 files changed, 43 insertions(+)",
    "diff": "diff --git a/drivers/net/ice/base/ice_dcb.c b/drivers/net/ice/base/ice_dcb.c\nindex 0aaa5ae8c1..c73fc095ff 100644\n--- a/drivers/net/ice/base/ice_dcb.c\n+++ b/drivers/net/ice/base/ice_dcb.c\n@@ -735,6 +735,47 @@ ice_aq_get_cee_dcb_cfg(struct ice_hw *hw,\n \treturn ice_aq_send_cmd(hw, &desc, (void *)buff, sizeof(*buff), cd);\n }\n \n+/**\n+ * ice_aq_set_pfc_mode - Set PFC mode\n+ * @hw: pointer to the HW struct\n+ * @pfc_mode: value of PFC mode to set\n+ * @cd: pointer to command details structure or NULL\n+ *\n+ * This AQ call configures the PFC mdoe to DSCP-based PFC mode or VLAN\n+ * -based PFC (0x0303)\n+ */\n+enum ice_status\n+ice_aq_set_pfc_mode(struct ice_hw *hw, u8 pfc_mode, struct ice_sq_cd *cd)\n+{\n+\tstruct ice_aqc_set_query_pfc_mode *cmd;\n+\tstruct ice_aq_desc desc;\n+\tenum ice_status status;\n+\n+\tif (pfc_mode > ICE_AQC_PFC_DSCP_BASED_PFC)\n+\t\treturn ICE_ERR_PARAM;\n+\n+\tcmd = &desc.params.set_query_pfc_mode;\n+\n+\tice_fill_dflt_direct_cmd_desc(&desc, ice_aqc_opc_set_pfc_mode);\n+\n+\tcmd->pfc_mode = pfc_mode;\n+\n+\tstatus = ice_aq_send_cmd(hw, &desc, NULL, 0, cd);\n+\tif (status)\n+\t\treturn status;\n+\n+\t/* The spec isn't clear about whether the FW will return an error code\n+\t * if the PFC mode requested by the driver was not set. The spec just\n+\t * says that the FW will write the PFC mode set back into cmd->pfc_mode,\n+\t * so after the AQ has been executed, check if cmd->pfc_mode is what was\n+\t * requested.\n+\t */\n+\tif (cmd->pfc_mode != pfc_mode)\n+\t\treturn ICE_ERR_NOT_SUPPORTED;\n+\n+\treturn ICE_SUCCESS;\n+}\n+\n /**\n  * ice_cee_to_dcb_cfg\n  * @cee_cfg: pointer to CEE configuration struct\ndiff --git a/drivers/net/ice/base/ice_dcb.h b/drivers/net/ice/base/ice_dcb.h\nindex a053adbb30..24c8da2dc8 100644\n--- a/drivers/net/ice/base/ice_dcb.h\n+++ b/drivers/net/ice/base/ice_dcb.h\n@@ -196,6 +196,8 @@ enum ice_status\n ice_aq_get_cee_dcb_cfg(struct ice_hw *hw,\n \t\t       struct ice_aqc_get_cee_dcb_cfg_resp *buff,\n \t\t       struct ice_sq_cd *cd);\n+enum ice_status\n+ice_aq_set_pfc_mode(struct ice_hw *hw, u8 pfc_mode, struct ice_sq_cd *cd);\n enum ice_status ice_lldp_to_dcb_cfg(u8 *lldpmib, struct ice_dcbx_cfg *dcbcfg);\n u8 ice_get_dcbx_status(struct ice_hw *hw);\n enum ice_status\n",
    "prefixes": [
        "1/4"
    ]
}