get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 1137376,
    "url": "http://patchwork.ozlabs.org/api/patches/1137376/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20190726112403.32842-1-chuanhua.han@nxp.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": "<20190726112403.32842-1-chuanhua.han@nxp.com>",
    "list_archive_url": null,
    "date": "2019-07-26T11:24:00",
    "name": "[U-Boot,v4,1/4] rtc: ds3232/ds3231: Add support to generate 32KHz output for driver module",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "224377caf153d42c592bbe6cb8d28bf54c9f7247",
    "submitter": {
        "id": 74737,
        "url": "http://patchwork.ozlabs.org/api/people/74737/?format=api",
        "name": "Chuanhua Han",
        "email": "chuanhua.han@nxp.com"
    },
    "delegate": {
        "id": 2467,
        "url": "http://patchwork.ozlabs.org/api/users/2467/?format=api",
        "username": "prabhu_kush",
        "first_name": "Prabhakar",
        "last_name": "Kushwaha",
        "email": "prabhakar@freescale.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20190726112403.32842-1-chuanhua.han@nxp.com/mbox/",
    "series": [
        {
            "id": 121633,
            "url": "http://patchwork.ozlabs.org/api/series/121633/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=121633",
            "date": "2019-07-26T11:24:00",
            "name": "[U-Boot,v4,1/4] rtc: ds3232/ds3231: Add support to generate 32KHz output for driver module",
            "version": 4,
            "mbox": "http://patchwork.ozlabs.org/series/121633/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/1137376/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/1137376/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",
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org;\n\tdmarc=fail (p=none dis=none) header.from=nxp.com"
        ],
        "Received": [
            "from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 45w6RP16RXz9s4Y\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 26 Jul 2019 21:33:51 +1000 (AEST)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 91D05C21E02; Fri, 26 Jul 2019 11:33:41 +0000 (UTC)",
            "from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id F0EFFC21C4A;\n\tFri, 26 Jul 2019 11:33:39 +0000 (UTC)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid E875FC21C93; Fri, 26 Jul 2019 11:33:37 +0000 (UTC)",
            "from inva020.nxp.com (inva020.nxp.com [92.121.34.13])\n\tby lists.denx.de (Postfix) with ESMTPS id 70EBAC21BE5\n\tfor <u-boot@lists.denx.de>; Fri, 26 Jul 2019 11:33:33 +0000 (UTC)",
            "from inva020.nxp.com (localhost [127.0.0.1])\n\tby inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id D8D6E1A09CB;\n\tFri, 26 Jul 2019 13:33:32 +0200 (CEST)",
            "from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com\n\t[165.114.16.14])\n\tby inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 079F21A09C1;\n\tFri, 26 Jul 2019 13:33:28 +0200 (CEST)",
            "from titan.ap.freescale.net (TITAN.ap.freescale.net\n\t[10.192.208.233])\n\tby invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id CCC80402D3;\n\tFri, 26 Jul 2019 19:33:21 +0800 (SGT)"
        ],
        "X-Spam-Checker-Version": "SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de",
        "X-Spam-Level": "",
        "X-Spam-Status": "No, score=0.0 required=5.0 tests=none autolearn=unavailable\n\tautolearn_force=no version=3.4.0",
        "From": "Chuanhua Han <chuanhua.han@nxp.com>",
        "To": "albert.u.boot@aribaud.net, prabhakar.kushwaha@nxp.com,\n\tpriyanka.jain@nxp.com, rajesh.bhagat@nxp.com",
        "Date": "Fri, 26 Jul 2019 19:24:00 +0800",
        "Message-Id": "<20190726112403.32842-1-chuanhua.han@nxp.com>",
        "X-Mailer": "git-send-email 2.9.5",
        "X-Virus-Scanned": "ClamAV using ClamSMTP",
        "Cc": "u-boot@lists.denx.de, Chuanhua Han <chuanhua.han@nxp.com>,\n\ttrini@konsulko.com",
        "Subject": "[U-Boot] [PATCH v4 1/4] rtc: ds3232/ds3231: Add support to generate\n\t32KHz output for driver module",
        "X-BeenThere": "u-boot@lists.denx.de",
        "X-Mailman-Version": "2.1.18",
        "Precedence": "list",
        "List-Id": "U-Boot discussion <u-boot.lists.denx.de>",
        "List-Unsubscribe": "<https://lists.denx.de/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": "<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"utf-8\"",
        "Content-Transfer-Encoding": "base64",
        "Errors-To": "u-boot-bounces@lists.denx.de",
        "Sender": "\"U-Boot\" <u-boot-bounces@lists.denx.de>"
    },
    "content": "This patch add an implementation of the rtc_enable_32khz_output() that\nuses the driver model i2c APIs.\n\nSigned-off-by: Chuanhua Han <chuanhua.han@nxp.com>\n---\ndepends on:\n  - http://patchwork.ozlabs.org/project/uboot/list/?series=118772\n  - http://patchwork.ozlabs.org/project/uboot/list/?series=117226\n\nChanges in v4:\n\t- No change.\nChanges in v3:\n\t- Delete something about DS3231_BUS_NUM\n\t- Modify the interface and definition of rtc_enable_32khz_output function\nChanges in v2:\n\t- No change.\n\n drivers/rtc/Kconfig  |  6 ++++++\n drivers/rtc/ds3231.c | 17 +++++++++++++++++\n include/rtc.h        |  6 ++++++\n 3 files changed, 29 insertions(+)",
    "diff": "diff --git a/drivers/rtc/Kconfig b/drivers/rtc/Kconfig\nindex fd0009b..cf15914 100644\n--- a/drivers/rtc/Kconfig\n+++ b/drivers/rtc/Kconfig\n@@ -31,6 +31,12 @@ config TPL_DM_RTC\n \t  drivers to perform the actual functions. See rtc.h for a\n \t  description of the API.\n \n+config RTC_ENABLE_32KHZ_OUTPUT\n+\tbool \"Enable RTC 32Khz output\"\n+\thelp\n+\t   Some real-time clocks support the output of 32kHz square waves (such as ds3231),\n+\t   the config symbol choose Real Time Clock device 32Khz output feature.\n+\n config RTC_PCF2127\n \tbool \"Enable PCF2127 driver\"\n \tdepends on DM_RTC\ndiff --git a/drivers/rtc/ds3231.c b/drivers/rtc/ds3231.c\nindex 79b026a..fde4d86 100644\n--- a/drivers/rtc/ds3231.c\n+++ b/drivers/rtc/ds3231.c\n@@ -148,11 +148,13 @@ void rtc_reset (void)\n /*\n  * Enable 32KHz output\n  */\n+#ifdef CONFIG_RTC_ENABLE_32KHZ_OUTPUT\n void rtc_enable_32khz_output(void)\n {\n \trtc_write(RTC_STAT_REG_ADDR,\n \t\t  RTC_STAT_BIT_BB32KHZ | RTC_STAT_BIT_EN32KHZ);\n }\n+#endif\n \n /*\n  * Helper functions\n@@ -251,6 +253,21 @@ static int ds3231_probe(struct udevice *dev)\n \treturn 0;\n }\n \n+#ifdef CONFIG_RTC_ENABLE_32KHZ_OUTPUT\n+int rtc_enable_32khz_output(int busnum, int chip_addr)\n+{\n+\tint ret;\n+\tstruct udevice *dev;\n+\n+\tret = i2c_get_chip_for_busnum(busnum, chip_addr, 1, &dev);\n+\tif (!ret)\n+\t\tret = dm_i2c_reg_write(dev, RTC_STAT_REG_ADDR,\n+\t\t\t\t       RTC_STAT_BIT_BB32KHZ |\n+\t\t\t\t       RTC_STAT_BIT_EN32KHZ);\n+\treturn ret;\n+}\n+#endif\n+\n static const struct rtc_ops ds3231_rtc_ops = {\n \t.get = ds3231_rtc_get,\n \t.set = ds3231_rtc_set,\ndiff --git a/include/rtc.h b/include/rtc.h\nindex b255bdc..7386d52 100644\n--- a/include/rtc.h\n+++ b/include/rtc.h\n@@ -166,11 +166,17 @@ int rtc_read32(struct udevice *dev, unsigned int reg, u32 *valuep);\n  */\n int rtc_write32(struct udevice *dev, unsigned int reg, u32 value);\n \n+#ifdef CONFIG_RTC_ENABLE_32KHZ_OUTPUT\n+int rtc_enable_32khz_output(int busnum, int chip_addr);\n+#endif\n+\n #else\n int rtc_get (struct rtc_time *);\n int rtc_set (struct rtc_time *);\n void rtc_reset (void);\n+#ifdef CONFIG_RTC_ENABLE_32KHZ_OUTPUT\n void rtc_enable_32khz_output(void);\n+#endif\n \n /**\n  * rtc_read8() - Read an 8-bit register\n",
    "prefixes": [
        "U-Boot",
        "v4",
        "1/4"
    ]
}