get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 207452,
    "url": "http://patchwork.ozlabs.org/api/patches/207452/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/1355934463-24319-1-git-send-email-jagannadh.teki@gmail.com/",
    "project": {
        "id": 18,
        "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api",
        "name": "U-Boot",
        "link_name": "uboot",
        "list_id": "u-boot.lists.denx.de",
        "list_email": "u-boot@lists.denx.de",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<1355934463-24319-1-git-send-email-jagannadh.teki@gmail.com>",
    "list_archive_url": null,
    "date": "2012-12-19T16:27:38",
    "name": "[U-Boot,U-Boot,v2,1/6] cmd_sf: Add print messages on flash erase command",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "d66825b85c7d16d0c21d1483158658990846e45f",
    "submitter": {
        "id": 20045,
        "url": "http://patchwork.ozlabs.org/api/people/20045/?format=api",
        "name": "Jagan Teki",
        "email": "jagannadh.teki@gmail.com"
    },
    "delegate": {
        "id": 17739,
        "url": "http://patchwork.ozlabs.org/api/users/17739/?format=api",
        "username": "jagan",
        "first_name": "Jagannadha Sutradharudu",
        "last_name": "Teki",
        "email": "jagannadh.teki@gmail.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/1355934463-24319-1-git-send-email-jagannadh.teki@gmail.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/207452/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/207452/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<u-boot-bounces@lists.denx.de>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@bilbo.ozlabs.org",
        "Received": [
            "from theia.denx.de (theia.denx.de [85.214.87.163])\n\tby ozlabs.org (Postfix) with ESMTP id 9DB6D2C0097\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu, 20 Dec 2012 03:28:47 +1100 (EST)",
            "from localhost (localhost [127.0.0.1])\n\tby theia.denx.de (Postfix) with ESMTP id 70B6A4A051;\n\tWed, 19 Dec 2012 17:28:36 +0100 (CET)",
            "from theia.denx.de ([127.0.0.1])\n\tby localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id 3PS5gbVrLXgA; Wed, 19 Dec 2012 17:28:36 +0100 (CET)",
            "from theia.denx.de (localhost [127.0.0.1])\n\tby theia.denx.de (Postfix) with ESMTP id C2FDC4A03B;\n\tWed, 19 Dec 2012 17:28:26 +0100 (CET)",
            "from localhost (localhost [127.0.0.1])\n\tby theia.denx.de (Postfix) with ESMTP id BC8F64A026\n\tfor <u-boot@lists.denx.de>; Wed, 19 Dec 2012 17:28:23 +0100 (CET)",
            "from theia.denx.de ([127.0.0.1])\n\tby localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id 8lcUqYCk9oms for <u-boot@lists.denx.de>;\n\tWed, 19 Dec 2012 17:28:17 +0100 (CET)",
            "from mail-da0-f41.google.com (mail-da0-f41.google.com\n\t[209.85.210.41]) by theia.denx.de (Postfix) with ESMTPS id A2CCE4A01F\n\tfor <u-boot@lists.denx.de>; Wed, 19 Dec 2012 17:28:14 +0100 (CET)",
            "by mail-da0-f41.google.com with SMTP id e20so1006394dak.14\n\tfor <u-boot@lists.denx.de>; Wed, 19 Dec 2012 08:28:11 -0800 (PST)",
            "from localhost.localdomain ([123.237.83.48])\n\tby mx.google.com with ESMTPS id z5sm3683430pax.9.2012.12.19.08.28.05\n\t(version=TLSv1/SSLv3 cipher=OTHER);\n\tWed, 19 Dec 2012 08:28:08 -0800 (PST)"
        ],
        "X-Virus-Scanned": [
            "Debian amavisd-new at theia.denx.de",
            "Debian amavisd-new at theia.denx.de"
        ],
        "X-policyd-weight": "NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5\n\tNOT_IN_BL_NJABL=-1.5 (only DNSBL check requested)",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\n\th=x-received:from:to:cc:subject:date:message-id:x-mailer;\n\tbh=87FX0cUyZebpj2CBzA1Jqnwm7B9xJ38984ILJfc+jrs=;\n\tb=QaEwX78joJGOOfHOK+U3lPm6BumF/RxaZyofBTAbvXq60bcIn7l7/DtxIYdrHdEoRo\n\tHJTVEcXCFA66p1TOzRjerTWHMR0afemOmH+gC1kXfziaXx7qBerdIWgvKrXrwZVGrFTZ\n\tkkta3FvXExLo3r2W/rGt4uoddwHaCRBnQjWMR/S6bOFBmPmWFbkYYLidRPrh2UB0q5qB\n\tT8gxqlG8Fgs8hKMrV3xMhHFXLo6Y+xv28mDSuRm1bWDcUbYNnJCOFgbnnyjGIOEUGjrr\n\tUc8Z8gjaBHxmyJKgKkW9wHbdqAcsCFVvfYYJtMu5fyRGEL7nHOrTz48quIT724iHUaSQ\n\tvEsw==",
        "X-Received": "by 10.68.227.41 with SMTP id rx9mr19990679pbc.121.1355934490142; \n\tWed, 19 Dec 2012 08:28:10 -0800 (PST)",
        "From": "Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>",
        "To": "u-boot@lists.denx.de",
        "Date": "Wed, 19 Dec 2012 21:57:38 +0530",
        "Message-Id": "<1355934463-24319-1-git-send-email-jagannadh.teki@gmail.com>",
        "X-Mailer": "git-send-email 1.7.0.4",
        "Subject": "[U-Boot] [U-Boot,\n\tv2 1/6] cmd_sf: Add print messages on flash erase command",
        "X-BeenThere": "u-boot@lists.denx.de",
        "X-Mailman-Version": "2.1.11",
        "Precedence": "list",
        "List-Id": "U-Boot discussion <u-boot.lists.denx.de>",
        "List-Unsubscribe": "<http://lists.denx.de/mailman/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>",
        "List-Archive": "<http://lists.denx.de/pipermail/u-boot>",
        "List-Post": "<mailto:u-boot@lists.denx.de>",
        "List-Help": "<mailto:u-boot-request@lists.denx.de?subject=help>",
        "List-Subscribe": "<http://lists.denx.de/mailman/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Sender": "u-boot-bounces@lists.denx.de",
        "Errors-To": "u-boot-bounces@lists.denx.de"
    },
    "content": "This patch adds a print messages while using 'sf erase' command\nto make sure that how many bytes erased in flash device.\n\nSigned-off-by: Jagannadha Sutradharudu Teki <jagannadh.teki@gmail.com>\n---\nChanges in v2:\n\tMove print messages from spi_flash.c into cmd_sf.c\n\t\n common/cmd_sf.c             |   11 ++++++-----\n drivers/mtd/spi/spi_flash.c |    2 --\n 2 files changed, 6 insertions(+), 7 deletions(-)",
    "diff": "diff --git a/common/cmd_sf.c b/common/cmd_sf.c\nindex 5ac1d0c..ddb1a65 100644\n--- a/common/cmd_sf.c\n+++ b/common/cmd_sf.c\n@@ -266,13 +266,14 @@ static int do_spi_flash_erase(int argc, char * const argv[])\n \t\treturn 1;\n \t}\n \n+\tprintf(\"SF: Erasing flash... \");\n+\n \tret = spi_flash_erase(flash, offset, len);\n-\tif (ret) {\n-\t\tprintf(\"SPI flash %s failed\\n\", argv[0]);\n-\t\treturn 1;\n-\t}\n \n-\treturn 0;\n+\tprintf(\"%zu bytes @ %#x erased: %s\\n\", (size_t)len, (u32)offset,\n+\t\t\tret ? \"ERROR\" : \"OK\");\n+\n+\treturn ret == 0 ? 0 : 1;\n }\n \n static int do_spi_flash(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])\ndiff --git a/drivers/mtd/spi/spi_flash.c b/drivers/mtd/spi/spi_flash.c\nindex 00aece9..43e0334 100644\n--- a/drivers/mtd/spi/spi_flash.c\n+++ b/drivers/mtd/spi/spi_flash.c\n@@ -235,8 +235,6 @@ int spi_flash_cmd_erase(struct spi_flash *flash, u32 offset, size_t len)\n \t\t\tgoto out;\n \t}\n \n-\tdebug(\"SF: Successfully erased %zu bytes @ %#x\\n\", len, start);\n-\n  out:\n \tspi_release_bus(flash->spi);\n \treturn ret;\n",
    "prefixes": [
        "U-Boot",
        "U-Boot",
        "v2",
        "1/6"
    ]
}