get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 525698,
    "url": "http://patchwork.ozlabs.org/api/patches/525698/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1443777496-43299-1-git-send-email-andriy.shevchenko@linux.intel.com/",
    "project": {
        "id": 46,
        "url": "http://patchwork.ozlabs.org/api/projects/46/?format=api",
        "name": "Intel Wired Ethernet development",
        "link_name": "intel-wired-lan",
        "list_id": "intel-wired-lan.osuosl.org",
        "list_email": "intel-wired-lan@osuosl.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<1443777496-43299-1-git-send-email-andriy.shevchenko@linux.intel.com>",
    "list_archive_url": null,
    "date": "2015-10-02T09:18:16",
    "name": "[1/1] i40e: re-use %*ph specifier to hexdump a data",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "78846ed4de835ba17ab45384e8c5180e33748364",
    "submitter": {
        "id": 8583,
        "url": "http://patchwork.ozlabs.org/api/people/8583/?format=api",
        "name": "Andy Shevchenko",
        "email": "andriy.shevchenko@linux.intel.com"
    },
    "delegate": {
        "id": 68,
        "url": "http://patchwork.ozlabs.org/api/users/68/?format=api",
        "username": "jtkirshe",
        "first_name": "Jeff",
        "last_name": "Kirsher",
        "email": "jeffrey.t.kirsher@intel.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1443777496-43299-1-git-send-email-andriy.shevchenko@linux.intel.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/525698/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/525698/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<intel-wired-lan-bounces@lists.osuosl.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Received": [
            "from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138])\n\tby ozlabs.org (Postfix) with ESMTP id DEA141402F0\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat,  3 Oct 2015 04:13:10 +1000 (AEST)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id BCE478D7CC;\n\tFri,  2 Oct 2015 18:13:08 +0000 (UTC)",
            "from whitealder.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id KmLTkD8fECh1; Fri,  2 Oct 2015 18:13:07 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 0C2068D7C2;\n\tFri,  2 Oct 2015 18:13:07 +0000 (UTC)",
            "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id F39ED1C0A72\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri,  2 Oct 2015 09:18:50 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id ED0F295483\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri,  2 Oct 2015 09:18:50 +0000 (UTC)",
            "from hemlock.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id BP7yd6IAu0+d for <intel-wired-lan@lists.osuosl.org>;\n\tFri,  2 Oct 2015 09:18:50 +0000 (UTC)",
            "from mga01.intel.com (mga01.intel.com [192.55.52.88])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 393509546C\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri,  2 Oct 2015 09:18:50 +0000 (UTC)",
            "from fmsmga002.fm.intel.com ([10.253.24.26])\n\tby fmsmga101.fm.intel.com with ESMTP; 02 Oct 2015 02:18:50 -0700",
            "from black.fi.intel.com ([10.237.72.93])\n\tby fmsmga002.fm.intel.com with ESMTP; 02 Oct 2015 02:18:48 -0700",
            "by black.fi.intel.com (Postfix, from userid 1003)\n\tid A5549216; Fri,  2 Oct 2015 12:18:17 +0300 (EEST)"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.17,622,1437462000\"; d=\"scan'208\";a=\"817784681\"",
        "From": "Andy Shevchenko <andriy.shevchenko@linux.intel.com>",
        "To": "Jeff Kirsher <jeffrey.t.kirsher@intel.com>,\n\tintel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org",
        "Date": "Fri,  2 Oct 2015 12:18:16 +0300",
        "Message-Id": "<1443777496-43299-1-git-send-email-andriy.shevchenko@linux.intel.com>",
        "X-Mailer": "git-send-email 2.5.1",
        "X-Mailman-Approved-At": "Fri, 02 Oct 2015 18:13:06 +0000",
        "Cc": "Andy Shevchenko <andriy.shevchenko@linux.intel.com>",
        "Subject": "[Intel-wired-lan] [PATCH 1/1] i40e: re-use %*ph specifier to\n\thexdump a data",
        "X-BeenThere": "intel-wired-lan@lists.osuosl.org",
        "X-Mailman-Version": "2.1.18-1",
        "Precedence": "list",
        "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n\t<intel-wired-lan.lists.osuosl.org>",
        "List-Unsubscribe": "<http://lists.osuosl.org/mailman/options/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@lists.osuosl.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.osuosl.org/pipermail/intel-wired-lan/>",
        "List-Post": "<mailto:intel-wired-lan@lists.osuosl.org>",
        "List-Help": "<mailto:intel-wired-lan-request@lists.osuosl.org?subject=help>",
        "List-Subscribe": "<http://lists.osuosl.org/mailman/listinfo/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@lists.osuosl.org?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "intel-wired-lan-bounces@lists.osuosl.org",
        "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@lists.osuosl.org>"
    },
    "content": "Instead of using a custom approach change the code to use %*ph format\nspecifier.\n\nSigned-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>\n---\n drivers/net/ethernet/intel/i40e/i40e_common.c   | 22 ++++------------------\n drivers/net/ethernet/intel/i40evf/i40e_common.c | 22 ++++------------------\n 2 files changed, 8 insertions(+), 36 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/i40e/i40e_common.c b/drivers/net/ethernet/intel/i40e/i40e_common.c\nindex 114dc64..3bc772c 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_common.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_common.c\n@@ -329,25 +329,11 @@ void i40e_debug_aq(struct i40e_hw *hw, enum i40e_debug_mask mask, void *desc,\n \t\t\tlen = buf_len;\n \t\t/* write the full 16-byte chunks */\n \t\tfor (i = 0; i < (len - 16); i += 16)\n-\t\t\ti40e_debug(hw, mask,\n-\t\t\t\t   \"\\t0x%04X  %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X\\n\",\n-\t\t\t\t   i, buf[i], buf[i + 1], buf[i + 2],\n-\t\t\t\t   buf[i + 3], buf[i + 4], buf[i + 5],\n-\t\t\t\t   buf[i + 6], buf[i + 7], buf[i + 8],\n-\t\t\t\t   buf[i + 9], buf[i + 10], buf[i + 11],\n-\t\t\t\t   buf[i + 12], buf[i + 13], buf[i + 14],\n-\t\t\t\t   buf[i + 15]);\n+\t\t\ti40e_debug(hw, mask, \"\\t0x%04X  %16ph\\n\", i, buf + i);\n \t\t/* write whatever's left over without overrunning the buffer */\n-\t\tif (i < len) {\n-\t\t\tchar d_buf[80];\n-\t\t\tint j = 0;\n-\n-\t\t\tmemset(d_buf, 0, sizeof(d_buf));\n-\t\t\tj += sprintf(d_buf, \"\\t0x%04X \", i);\n-\t\t\twhile (i < len)\n-\t\t\t\tj += sprintf(&d_buf[j], \" %02X\", buf[i++]);\n-\t\t\ti40e_debug(hw, mask, \"%s\\n\", d_buf);\n-\t\t}\n+\t\tif (i < len)\n+\t\t\ti40e_debug(hw, mask, \"\\t0x%04X  %*ph\\n\",\n+\t\t\t\t\t     i, len - i, buf + i);\n \t}\n }\n \ndiff --git a/drivers/net/ethernet/intel/i40evf/i40e_common.c b/drivers/net/ethernet/intel/i40evf/i40e_common.c\nindex d45d0ae..200bbcb 100644\n--- a/drivers/net/ethernet/intel/i40evf/i40e_common.c\n+++ b/drivers/net/ethernet/intel/i40evf/i40e_common.c\n@@ -329,25 +329,11 @@ void i40evf_debug_aq(struct i40e_hw *hw, enum i40e_debug_mask mask, void *desc,\n \t\t\tlen = buf_len;\n \t\t/* write the full 16-byte chunks */\n \t\tfor (i = 0; i < (len - 16); i += 16)\n-\t\t\ti40e_debug(hw, mask,\n-\t\t\t\t   \"\\t0x%04X  %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X %02X\\n\",\n-\t\t\t\t   i, buf[i], buf[i + 1], buf[i + 2],\n-\t\t\t\t   buf[i + 3], buf[i + 4], buf[i + 5],\n-\t\t\t\t   buf[i + 6], buf[i + 7], buf[i + 8],\n-\t\t\t\t   buf[i + 9], buf[i + 10], buf[i + 11],\n-\t\t\t\t   buf[i + 12], buf[i + 13], buf[i + 14],\n-\t\t\t\t   buf[i + 15]);\n+\t\t\ti40e_debug(hw, mask, \"\\t0x%04X  %16ph\\n\", i, buf + i);\n \t\t/* write whatever's left over without overrunning the buffer */\n-\t\tif (i < len) {\n-\t\t\tchar d_buf[80];\n-\t\t\tint j = 0;\n-\n-\t\t\tmemset(d_buf, 0, sizeof(d_buf));\n-\t\t\tj += sprintf(d_buf, \"\\t0x%04X \", i);\n-\t\t\twhile (i < len)\n-\t\t\t\tj += sprintf(&d_buf[j], \" %02X\", buf[i++]);\n-\t\t\ti40e_debug(hw, mask, \"%s\\n\", d_buf);\n-\t\t}\n+\t\tif (i < len)\n+\t\t\ti40e_debug(hw, mask, \"\\t0x%04X  %*ph\\n\",\n+\t\t\t\t\t     i, len - i, buf + i);\n \t}\n }\n \n",
    "prefixes": [
        "1/1"
    ]
}