get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 21931,
    "url": "http://patches.dpdk.org/api/patches/21931/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1489820786-14226-23-git-send-email-rasesh.mody@cavium.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": "<1489820786-14226-23-git-send-email-rasesh.mody@cavium.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1489820786-14226-23-git-send-email-rasesh.mody@cavium.com",
    "date": "2017-03-18T07:05:47",
    "name": "[dpdk-dev,v2,22/61] net/qede/base: check active VF queues before stopping",
    "commit_ref": null,
    "pull_url": null,
    "state": "changes-requested",
    "archived": true,
    "hash": "d85f9e7f4b829c9e9010e58887c0dfc0eb170ec0",
    "submitter": {
        "id": 569,
        "url": "http://patches.dpdk.org/api/people/569/?format=api",
        "name": "Mody, Rasesh",
        "email": "rasesh.mody@cavium.com"
    },
    "delegate": {
        "id": 319,
        "url": "http://patches.dpdk.org/api/users/319/?format=api",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@amd.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1489820786-14226-23-git-send-email-rasesh.mody@cavium.com/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/21931/comments/",
    "check": "fail",
    "checks": "http://patches.dpdk.org/api/patches/21931/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id 19B97D040;\n\tSat, 18 Mar 2017 08:12:12 +0100 (CET)",
            "from mx0b-0016ce01.pphosted.com (mx0a-0016ce01.pphosted.com\n\t[67.231.148.157]) by dpdk.org (Postfix) with ESMTP id 35A46CFD8\n\tfor <dev@dpdk.org>; Sat, 18 Mar 2017 08:11:56 +0100 (CET)",
            "from pps.filterd (m0095336.ppops.net [127.0.0.1])\n\tby mx0a-0016ce01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id\n\tv2I7Bqr2018373; Sat, 18 Mar 2017 00:11:53 -0700",
            "from avcashub1.qlogic.com ([198.186.0.117])\n\tby mx0a-0016ce01.pphosted.com with ESMTP id 29909vr001-1\n\t(version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT);\n\tSat, 18 Mar 2017 00:11:49 -0700",
            "from avluser05.qlc.com (10.1.113.115) by qlc.com (10.1.4.192) with\n\tMicrosoft SMTP Server id 14.3.235.1;\n\tSat, 18 Mar 2017 00:11:48 -0700",
            "(from rmody@localhost)\tby avluser05.qlc.com (8.14.4/8.14.4/Submit)\n\tid v2I7Bl6O014686;\tSat, 18 Mar 2017 00:11:47 -0700"
        ],
        "X-Authentication-Warning": "avluser05.qlc.com: rmody set sender to\n\trasesh.mody@cavium.com using -f",
        "From": "Rasesh Mody <rasesh.mody@cavium.com>",
        "To": "<dev@dpdk.org>, <ferruh.yigit@intel.com>",
        "CC": "Rasesh Mody <rasesh.mody@cavium.com>, <Dept-EngDPDKDev@cavium.com>",
        "Date": "Sat, 18 Mar 2017 00:05:47 -0700",
        "Message-ID": "<1489820786-14226-23-git-send-email-rasesh.mody@cavium.com>",
        "X-Mailer": "git-send-email 1.7.10.3",
        "In-Reply-To": "<162b5be7-d8a5-0e89-a32f-b1a992aef2a3@intel.com>",
        "References": "<162b5be7-d8a5-0e89-a32f-b1a992aef2a3@intel.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain",
        "disclaimer": "bypass",
        "X-Proofpoint-Virus-Version": "vendor=nai engine=5800 definitions=8470\n\tsignatures=668448",
        "X-Proofpoint-Spam-Details": "rule=notspam policy=default score=0\n\tpriorityscore=1501 malwarescore=0\n\tsuspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015\n\tlowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam\n\tadjust=0\n\treason=mlx scancount=1 engine=8.0.1-1702020001\n\tdefinitions=main-1703180075",
        "Subject": "[dpdk-dev] [PATCH v2 22/61] net/qede/base: check active VF queues\n\tbefore stopping",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Make sure VF queue are closed before stopping vport.\n\nSigned-off-by: Rasesh Mody <rasesh.mody@cavium.com>\n---\n drivers/net/qede/base/ecore_sriov.c |   37 ++++++++++++++++++++++++++++++++++-\n 1 file changed, 36 insertions(+), 1 deletion(-)",
    "diff": "diff --git a/drivers/net/qede/base/ecore_sriov.c b/drivers/net/qede/base/ecore_sriov.c\nindex 365be25..73c4015 100644\n--- a/drivers/net/qede/base/ecore_sriov.c\n+++ b/drivers/net/qede/base/ecore_sriov.c\n@@ -232,6 +232,30 @@ static bool ecore_iov_validate_sb(struct ecore_hwfn *p_hwfn,\n \treturn false;\n }\n \n+static bool ecore_iov_validate_active_rxq(struct ecore_hwfn *p_hwfn,\n+\t\t\t\t\t  struct ecore_vf_info *p_vf)\n+{\n+\tu8 i;\n+\n+\tfor (i = 0; i < p_vf->num_rxqs; i++)\n+\t\tif (p_vf->vf_queues[i].rxq_active)\n+\t\t\treturn true;\n+\n+\treturn false;\n+}\n+\n+static bool ecore_iov_validate_active_txq(struct ecore_hwfn *p_hwfn,\n+\t\t\t\t\t  struct ecore_vf_info *p_vf)\n+{\n+\tu8 i;\n+\n+\tfor (i = 0; i < p_vf->num_rxqs; i++)\n+\t\tif (p_vf->vf_queues[i].txq_active)\n+\t\t\treturn true;\n+\n+\treturn false;\n+}\n+\n /* TODO - this is linux crc32; Need a way to ifdef it out for linux */\n u32 ecore_crc32(u32 crc, u8 *ptr, u32 length)\n {\n@@ -1365,8 +1389,10 @@ static void ecore_iov_vf_cleanup(struct ecore_hwfn *p_hwfn,\n \n \tp_vf->num_active_rxqs = 0;\n \n-\tfor (i = 0; i < ECORE_MAX_VF_CHAINS_PER_PF; i++)\n+\tfor (i = 0; i < ECORE_MAX_VF_CHAINS_PER_PF; i++) {\n \t\tp_vf->vf_queues[i].rxq_active = 0;\n+\t\tp_vf->vf_queues[i].txq_active = 0;\n+\t}\n \n \tOSAL_MEMSET(&p_vf->shadow_config, 0, sizeof(p_vf->shadow_config));\n \tOSAL_MEMSET(&p_vf->acquire, 0, sizeof(p_vf->acquire));\n@@ -1943,6 +1969,15 @@ static void ecore_iov_vf_mbx_stop_vport(struct ecore_hwfn *p_hwfn,\n \tvf->vport_instance--;\n \tvf->spoof_chk = false;\n \n+\tif ((ecore_iov_validate_active_rxq(p_hwfn, vf)) ||\n+\t    (ecore_iov_validate_active_txq(p_hwfn, vf))) {\n+\t\tvf->b_malicious = true;\n+\t\tDP_NOTICE(p_hwfn, false,\n+\t\t\t  \"VF [%02x] - considered malicious;\"\n+\t\t\t  \" Unable to stop RX/TX queuess\\n\",\n+\t\t\t  vf->abs_vf_id);\n+\t}\n+\n \trc = ecore_sp_vport_stop(p_hwfn, vf->opaque_fid, vf->vport_id);\n \tif (rc != ECORE_SUCCESS) {\n \t\tDP_ERR(p_hwfn,\n",
    "prefixes": [
        "dpdk-dev",
        "v2",
        "22/61"
    ]
}