Show a patch.

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

{
    "id": 73605,
    "url": "https://patches.dpdk.org/api/patches/73605/",
    "web_url": "https://patches.dpdk.org/patch/73605/",
    "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": "<20200709080046.65879-9-guinanx.sun@intel.com>",
    "date": "2020-07-09T08:00:35",
    "name": "[v3,08/19] net/ixgbe/base: move increments after evaluations",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "688b54329b2671fb9b3761086faa21ccf6ac2e67",
    "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/73605/mbox/",
    "series": [
        {
            "id": 10915,
            "url": "https://patches.dpdk.org/api/series/10915/",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=10915",
            "date": "2020-07-09T08:00:27",
            "name": "update ixgbe base code",
            "version": 3,
            "mbox": "https://patches.dpdk.org/series/10915/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/73605/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/73605/checks/",
    "tags": {},
    "headers": {
        "X-Mailman-Version": "2.1.15",
        "X-ExtLoop1": "1",
        "Errors-To": "dev-bounces@dpdk.org",
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Mailer": "git-send-email 2.17.1",
        "Received": [
            "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id A4665A0526;\n\tThu,  9 Jul 2020 10:15:23 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id B18581DE31;\n\tThu,  9 Jul 2020 10:14:14 +0200 (CEST)",
            "from mga07.intel.com (mga07.intel.com [134.134.136.100])\n by dpdk.org (Postfix) with ESMTP id ED8471DDDA\n for <dev@dpdk.org>; Thu,  9 Jul 2020 10:14:07 +0200 (CEST)",
            "from orsmga002.jf.intel.com ([10.7.209.21])\n by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 09 Jul 2020 01:14:07 -0700",
            "from intel.sh.intel.com ([10.239.255.18])\n by orsmga002.jf.intel.com with ESMTP; 09 Jul 2020 01:14:05 -0700"
        ],
        "References": "<20200702031329.4495-1-guinanx.sun@intel.com>\n <20200709080046.65879-1-guinanx.sun@intel.com>",
        "X-Amp-File-Uploaded": "False",
        "X-BeenThere": "dev@dpdk.org",
        "Message-Id": "<20200709080046.65879-9-guinanx.sun@intel.com>",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9676\"; a=\"212869363\"",
            "E=Sophos;i=\"5.75,331,1589266800\"; d=\"scan'208\";a=\"212869363\"",
            "E=Sophos;i=\"5.75,331,1589266800\"; d=\"scan'208\";a=\"297989147\""
        ],
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Precedence": "list",
        "From": "Guinan Sun <guinanx.sun@intel.com>",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "List-Post": "<mailto:dev@dpdk.org>",
        "Return-Path": "<dev-bounces@dpdk.org>",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "In-Reply-To": "<20200709080046.65879-1-guinanx.sun@intel.com>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "To": "dev@dpdk.org",
        "IronPort-SDR": [
            "\n rhDfG62FaY1HLQnMhIHOoRjWh1EjiMA31EVKEpOB/JvwO+Ro8qckTsw7MeKHj0VTmQO9mJqLj8\n O2zBuzobwTYg==",
            "\n H4TOrKVJNFeOKoEN8xmnJLPSUcHu8U3VGXM4N5NDbpwqiD3ap4kV9dyaImW0Hpl+iyJjXiyC7+\n 2Ou4mB8Pki1g=="
        ],
        "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>",
        "Date": "Thu,  9 Jul 2020 08:00:35 +0000",
        "Cc": "Jeff Guo <jia.guo@intel.com>, Zhao1 Wei <wei.zhao1@intel.com>,\n Guinan Sun <guinanx.sun@intel.com>, Jeb Cramer <jeb.j.cramer@intel.com>",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "Subject": "[dpdk-dev] [PATCH v3 08/19] net/ixgbe/base: move increments after\n\tevaluations"
    },
    "content": "The retry variable was being incremented before it was evaluated by the\nsubsequent conditional against the maximum retries to figure out which\nmessage to print.  So we'll move the increment op to the end.\n\nSigned-off-by: Jeb Cramer <jeb.j.cramer@intel.com>\nSigned-off-by: Guinan Sun <guinanx.sun@intel.com>\nReviewed-by: Wei Zhao <wei.zhao1@intel.com>\n---\n drivers/net/ixgbe/base/ixgbe_phy.c | 17 ++++++++---------\n 1 file changed, 8 insertions(+), 9 deletions(-)",
    "diff": "diff --git a/drivers/net/ixgbe/base/ixgbe_phy.c b/drivers/net/ixgbe/base/ixgbe_phy.c\nindex 13f00ac67..823cf161e 100644\n--- a/drivers/net/ixgbe/base/ixgbe_phy.c\n+++ b/drivers/net/ixgbe/base/ixgbe_phy.c\n@@ -138,12 +138,12 @@ s32 ixgbe_read_i2c_combined_generic_int(struct ixgbe_hw *hw, u8 addr, u16 reg,\n \t\tixgbe_i2c_bus_clear(hw);\n \t\tif (lock)\n \t\t\thw->mac.ops.release_swfw_sync(hw, swfw_mask);\n-\t\tretry++;\n \t\tif (retry < max_retry)\n \t\t\tDEBUGOUT(\"I2C byte read combined error - Retrying.\\n\");\n \t\telse\n \t\t\tDEBUGOUT(\"I2C byte read combined error.\\n\");\n-\t} while (retry < max_retry);\n+\t\tretry++;\n+\t} while (retry <= max_retry);\n \n \treturn IXGBE_ERR_I2C;\n }\n@@ -203,12 +203,12 @@ s32 ixgbe_write_i2c_combined_generic_int(struct ixgbe_hw *hw, u8 addr, u16 reg,\n \t\tixgbe_i2c_bus_clear(hw);\n \t\tif (lock)\n \t\t\thw->mac.ops.release_swfw_sync(hw, swfw_mask);\n-\t\tretry++;\n \t\tif (retry < max_retry)\n \t\t\tDEBUGOUT(\"I2C byte write combined error - Retrying.\\n\");\n \t\telse\n \t\t\tDEBUGOUT(\"I2C byte write combined error.\\n\");\n-\t} while (retry < max_retry);\n+\t\tretry++;\n+\t} while (retry <= max_retry);\n \n \treturn IXGBE_ERR_I2C;\n }\n@@ -2057,13 +2057,12 @@ STATIC s32 ixgbe_read_i2c_byte_generic_int(struct ixgbe_hw *hw, u8 byte_offset,\n \t\t\thw->mac.ops.release_swfw_sync(hw, swfw_mask);\n \t\t\tmsec_delay(100);\n \t\t}\n-\t\tretry++;\n \t\tif (retry < max_retry)\n \t\t\tDEBUGOUT(\"I2C byte read error - Retrying.\\n\");\n \t\telse\n \t\t\tDEBUGOUT(\"I2C byte read error.\\n\");\n-\n-\t} while (retry < max_retry);\n+\t\tretry++;\n+\t} while (retry <= max_retry);\n \n \treturn status;\n }\n@@ -2161,12 +2160,12 @@ STATIC s32 ixgbe_write_i2c_byte_generic_int(struct ixgbe_hw *hw, u8 byte_offset,\n \n fail:\n \t\tixgbe_i2c_bus_clear(hw);\n-\t\tretry++;\n \t\tif (retry < max_retry)\n \t\t\tDEBUGOUT(\"I2C byte write error - Retrying.\\n\");\n \t\telse\n \t\t\tDEBUGOUT(\"I2C byte write error.\\n\");\n-\t} while (retry < max_retry);\n+\t\tretry++;\n+\t} while (retry <= max_retry);\n \n \tif (lock)\n \t\thw->mac.ops.release_swfw_sync(hw, swfw_mask);\n",
    "prefixes": [
        "v3",
        "08/19"
    ]
}