get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 814563,
    "url": "http://patchwork.ozlabs.org/api/patches/814563/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20170916212331.170463-6-sjg@chromium.org/",
    "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": "<20170916212331.170463-6-sjg@chromium.org>",
    "list_archive_url": null,
    "date": "2017-09-16T21:23:18",
    "name": "[U-Boot,05/13] Drop the log buffer",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "458f58b54d5b0e504983e517c74de8c2cfc39807",
    "submitter": {
        "id": 6170,
        "url": "http://patchwork.ozlabs.org/api/people/6170/?format=api",
        "name": "Simon Glass",
        "email": "sjg@chromium.org"
    },
    "delegate": {
        "id": 3184,
        "url": "http://patchwork.ozlabs.org/api/users/3184/?format=api",
        "username": "sjg",
        "first_name": "Simon",
        "last_name": "Glass",
        "email": "sjg@chromium.org"
    },
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20170916212331.170463-6-sjg@chromium.org/mbox/",
    "series": [
        {
            "id": 3473,
            "url": "http://patchwork.ozlabs.org/api/series/3473/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=3473",
            "date": "2017-09-16T21:23:14",
            "name": "log: Add a new logging feature",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/3473/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/814563/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/814563/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\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=google.com header.i=@google.com\n\theader.b=\"UFOU9uJ9\"; dkim-atps=neutral"
        ],
        "Received": [
            "from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xvlwf5mBZz9ryT\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSun, 17 Sep 2017 07:37:22 +1000 (AEST)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 75A54C21D96; Sat, 16 Sep 2017 21:36:53 +0000 (UTC)",
            "from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 46F8EC21DDF;\n\tSat, 16 Sep 2017 21:31:45 +0000 (UTC)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 3E056C21D80; Sat, 16 Sep 2017 21:24:03 +0000 (UTC)",
            "from mail-oi0-f49.google.com (mail-oi0-f49.google.com\n\t[209.85.218.49])\n\tby lists.denx.de (Postfix) with ESMTPS id 7D6EDC21DD0\n\tfor <u-boot@lists.denx.de>; Sat, 16 Sep 2017 21:23:59 +0000 (UTC)",
            "by mail-oi0-f49.google.com with SMTP id l74so2372564oih.1\n\tfor <u-boot@lists.denx.de>; Sat, 16 Sep 2017 14:23:59 -0700 (PDT)",
            "from kiwi.bld.corp.google.com ([2620:0:10f2:0:b470:b7b0:9c28:669e])\n\tby smtp.gmail.com with ESMTPSA id\n\tb186sm3929749oia.31.2017.09.16.14.23.56\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tSat, 16 Sep 2017 14:23:56 -0700 (PDT)",
            "by kiwi.bld.corp.google.com (Postfix, from userid 121222)\n\tid 5BF65140A54; Sat, 16 Sep 2017 15:23:56 -0600 (MDT)"
        ],
        "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=RCVD_IN_DNSWL_NONE,\n\tRCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL,\n\tT_DKIM_INVALID autolearn=unavailable\n\tautolearn_force=no version=3.4.0",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com;\n\ts=20161025; \n\th=sender:from:to:cc:subject:date:message-id:in-reply-to:references;\n\tbh=fLxKsshhcOYjnuSdRQVfolVYkplwMfxY0+MSUQiaVyk=;\n\tb=UFOU9uJ9ySeTx/2DKeFEmOsFAfzngmR9uQnRpwvUA+D1LaQMi7Hs/k+9+446jYKRde\n\t0ncsZflIp9FQL/kbLEVp7cb/KdwWJp+4FMnk/idpHkAnj0/5CX5nJItMYzMmWa/FbA/G\n\t7Dam64EGl2KocSw6Xzu9MhVRLgm0VDJsyEUMgPItM0a1tk02FlmUPVtxDhjh+scS2eNI\n\tY27eEhRkBfZKgUSJm6WVzo7vy4ctlxv5p6tGBR/Bz8oHjD25Al5u3/hW315JXh6bsn7e\n\taz4Grbw8KMUZIz0sSK1cXSGijwAV3Ixtp0Y6trRHdY17LIOaFQZw/cJ0yhcsGI9rP3Dm\n\tl18A==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:sender:from:to:cc:subject:date:message-id\n\t:in-reply-to:references;\n\tbh=fLxKsshhcOYjnuSdRQVfolVYkplwMfxY0+MSUQiaVyk=;\n\tb=j9t+uXmVZNTpIihlxPn0QZGGX9vzsXmNZiTxMve3uIaQJdjJmg7+6U/DJJTUf0RlMs\n\tQx2xhtkoPoD/gN06bjxhI2wDsSpGvKOh4I3MvDsOzW9Nahvi6z4dBsQwZqZFxvJBrgZZ\n\tQySfCaCDIvOCd5aeyleL5cqmGlHmAl6wpZKSHckG98+OPpGukbykWSDTSSuxB2ZhcApY\n\tRFRh8R4XLyb0pI/6L+qul9TTwCzJsZKOdZsraUUI3uYUY6yTIyScolszrclnc8wqzNq1\n\td5FPcyy7WUy5DXnPK2srxmfqUfkkCWTYy6t5p9FC8nXPSItUtKeeaNp6gQQ8pvfwSqv+\n\tkIHA==",
        "X-Gm-Message-State": "AHPjjUjJ9WNMeWVc6X/c7KS/2JgZ6YqCN7nVHJdCYnt9oKib3PnjTNKx\n\tNME5jmL+LkaYXFZI",
        "X-Google-Smtp-Source": "AOwi7QB6VctgkHLWMz/mmg4kWwuvkoXLlalROmEyfWs4fdj9ThS8Om6/pAkEk0vURvCVdzZqMA6uZA==",
        "X-Received": "by 10.202.83.23 with SMTP id h23mr28195121oib.226.1505597037738; \n\tSat, 16 Sep 2017 14:23:57 -0700 (PDT)",
        "From": "Simon Glass <sjg@chromium.org>",
        "To": "U-Boot Mailing List <u-boot@lists.denx.de>",
        "Date": "Sat, 16 Sep 2017 15:23:18 -0600",
        "Message-Id": "<20170916212331.170463-6-sjg@chromium.org>",
        "X-Mailer": "git-send-email 2.14.1.690.gbb1197296e-goog",
        "In-Reply-To": "<20170916212331.170463-1-sjg@chromium.org>",
        "References": "<20170916212331.170463-1-sjg@chromium.org>",
        "X-Mailman-Approved-At": "Sat, 16 Sep 2017 21:31:43 +0000",
        "Cc": "Jagan Teki <jteki@openedev.com>, Stefan Roese <sr@denx.de>,\n\tMarek Vasut <marex@denx.de>, Tom Rini <trini@konsulko.com>,\n\t\"xypron.glpk@gmx.de\" <xypron.glpk@gmx.de>,\n\tMichal Simek <michal.simek@xilinx.com>,\n\tAndy Shevchenko <andriy.shevchenko@linux.intel.com>,\n\tRick Altherr <raltherr@google.com>,\n\tThomas Petazzoni <thomas.petazzoni@free-electrons.com>,\n\tAndy Yan <andy.yan@rock-chips.com>",
        "Subject": "[U-Boot] [PATCH 05/13] Drop the log buffer",
        "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 does not appear to be used by any boards. Before introducing a new\nlog system, remove this old one.\n\nSigned-off-by: Simon Glass <sjg@chromium.org>\n---\n\n cmd/Makefile                      |   1 -\n cmd/log.c                         | 313 --------------------------------------\n common/board_f.c                  |  18 ---\n common/board_r.c                  |  25 +--\n common/image.c                    |   9 --\n common/stdio.c                    |   6 -\n include/asm-generic/global_data.h |   2 +-\n include/logbuff.h                 |  49 ------\n include/post.h                    |   4 +-\n post/post.c                       |   9 --\n post/tests.c                      |   4 -\n scripts/config_whitelist.txt      |   1 -\n 12 files changed, 5 insertions(+), 436 deletions(-)\n delete mode 100644 cmd/log.c\n delete mode 100644 include/logbuff.h",
    "diff": "diff --git a/cmd/Makefile b/cmd/Makefile\nindex 2a5b8ce825..1b13d07901 100644\n--- a/cmd/Makefile\n+++ b/cmd/Makefile\n@@ -75,7 +75,6 @@ obj-$(CONFIG_LED_STATUS_CMD) += legacy_led.o\n obj-$(CONFIG_CMD_LED) += led.o\n obj-$(CONFIG_CMD_LICENSE) += license.o\n obj-y += load.o\n-obj-$(CONFIG_LOGBUFFER) += log.o\n obj-$(CONFIG_ID_EEPROM) += mac.o\n obj-$(CONFIG_CMD_MD5SUM) += md5sum.o\n obj-$(CONFIG_CMD_MEMORY) += mem.o\ndiff --git a/cmd/log.c b/cmd/log.c\ndeleted file mode 100644\nindex 7a3bd5cd69..0000000000\n--- a/cmd/log.c\n+++ /dev/null\n@@ -1,313 +0,0 @@\n-/*\n- * (C) Copyright 2002-2007\n- * Detlev Zundel, DENX Software Engineering, dzu@denx.de.\n- *\n- * Code used from linux/kernel/printk.c\n- * Copyright (C) 1991, 1992  Linus Torvalds\n- *\n- * SPDX-License-Identifier:\tGPL-2.0+\n- *\n- * Comments:\n- *\n- * After relocating the code, the environment variable \"loglevel\" is\n- * copied to console_loglevel.  The functionality is similar to the\n- * handling in the Linux kernel, i.e. messages logged with a priority\n- * less than console_loglevel are also output to stdout.\n- *\n- * If you want messages with the default level (e.g. POST messages) to\n- * appear on stdout also, make sure the environment variable\n- * \"loglevel\" is set at boot time to a number higher than\n- * default_message_loglevel below.\n- */\n-\n-/*\n- * Logbuffer handling routines\n- */\n-\n-#include <common.h>\n-#include <command.h>\n-#include <stdio_dev.h>\n-#include <post.h>\n-#include <logbuff.h>\n-\n-DECLARE_GLOBAL_DATA_PTR;\n-\n-/* Local prototypes */\n-static void logbuff_putc(struct stdio_dev *dev, const char c);\n-static void logbuff_puts(struct stdio_dev *dev, const char *s);\n-static int logbuff_printk(const char *line);\n-\n-static char buf[1024];\n-\n-/* This combination will not print messages with the default loglevel */\n-static unsigned console_loglevel = 3;\n-static unsigned default_message_loglevel = 4;\n-static unsigned log_version = 1;\n-#ifdef CONFIG_ALT_LB_ADDR\n-static volatile logbuff_t *log;\n-#else\n-static logbuff_t *log;\n-#endif\n-static char *lbuf;\n-\n-unsigned long __logbuffer_base(void)\n-{\n-\treturn CONFIG_SYS_SDRAM_BASE + get_effective_memsize() - LOGBUFF_LEN;\n-}\n-unsigned long logbuffer_base(void)\n-__attribute__((weak, alias(\"__logbuffer_base\")));\n-\n-void logbuff_init_ptrs(void)\n-{\n-\tunsigned long tag, post_word;\n-\tchar *s;\n-\n-#ifdef CONFIG_ALT_LB_ADDR\n-\tlog = (logbuff_t *)CONFIG_ALT_LH_ADDR;\n-\tlbuf = (char *)CONFIG_ALT_LB_ADDR;\n-#else\n-\tlog = (logbuff_t *)(logbuffer_base()) - 1;\n-\tlbuf = (char *)log->buf;\n-#endif\n-\n-\t/* Set up log version */\n-\ts = env_get(\"logversion\");\n-\tif (s)\n-\t\tlog_version = (int)simple_strtoul(s, NULL, 10);\n-\n-\tif (log_version == 2)\n-\t\ttag = log->v2.tag;\n-\telse\n-\t\ttag = log->v1.tag;\n-\tpost_word = post_word_load();\n-#ifdef CONFIG_POST\n-\t/* The post routines have setup the word so we can simply test it */\n-\tif (tag != LOGBUFF_MAGIC || (post_word & POST_COLDBOOT))\n-\t\tlogbuff_reset();\n-#else\n-\t/* No post routines, so we do our own checking                    */\n-\tif (tag != LOGBUFF_MAGIC || post_word != LOGBUFF_MAGIC) {\n-\t\tlogbuff_reset ();\n-\t\tpost_word_store (LOGBUFF_MAGIC);\n-\t}\n-#endif\n-\tif (log_version == 2 && (long)log->v2.start > (long)log->v2.con)\n-\t\tlog->v2.start = log->v2.con;\n-\n-\t/* Initialize default loglevel if present */\n-\ts = env_get(\"loglevel\");\n-\tif (s)\n-\t\tconsole_loglevel = (int)simple_strtoul(s, NULL, 10);\n-\n-\tgd->flags |= GD_FLG_LOGINIT;\n-}\n-\n-void logbuff_reset(void)\n-{\n-#ifndef CONFIG_ALT_LB_ADDR\n-\tmemset(log, 0, sizeof(logbuff_t));\n-#endif\n-\tif (log_version == 2) {\n-\t\tlog->v2.tag = LOGBUFF_MAGIC;\n-#ifdef CONFIG_ALT_LB_ADDR\n-\t\tlog->v2.start = 0;\n-\t\tlog->v2.con = 0;\n-\t\tlog->v2.end = 0;\n-\t\tlog->v2.chars = 0;\n-#endif\n-\t} else {\n-\t\tlog->v1.tag = LOGBUFF_MAGIC;\n-#ifdef CONFIG_ALT_LB_ADDR\n-\t\tlog->v1.dummy = 0;\n-\t\tlog->v1.start = 0;\n-\t\tlog->v1.size = 0;\n-\t\tlog->v1.chars = 0;\n-#endif\n-\t}\n-}\n-\n-int drv_logbuff_init(void)\n-{\n-\tstruct stdio_dev logdev;\n-\tint rc;\n-\n-\t/* Device initialization */\n-\tmemset (&logdev, 0, sizeof (logdev));\n-\n-\tstrcpy (logdev.name, \"logbuff\");\n-\tlogdev.ext   = 0;\t\t\t/* No extensions */\n-\tlogdev.flags = DEV_FLAGS_OUTPUT;\t/* Output only */\n-\tlogdev.putc  = logbuff_putc;\t\t/* 'putc' function */\n-\tlogdev.puts  = logbuff_puts;\t\t/* 'puts' function */\n-\n-\trc = stdio_register(&logdev);\n-\n-\treturn (rc == 0) ? 1 : rc;\n-}\n-\n-static void logbuff_putc(struct stdio_dev *dev, const char c)\n-{\n-\tchar buf[2];\n-\tbuf[0] = c;\n-\tbuf[1] = '\\0';\n-\tlogbuff_printk(buf);\n-}\n-\n-static void logbuff_puts(struct stdio_dev *dev, const char *s)\n-{\n-\tlogbuff_printk (s);\n-}\n-\n-void logbuff_log(char *msg)\n-{\n-\tif ((gd->flags & GD_FLG_LOGINIT)) {\n-\t\tlogbuff_printk(msg);\n-\t} else {\n-\t\t/*\n-\t\t * Can happen only for pre-relocated errors as logging\n-\t\t * at that stage should be disabled\n-\t\t */\n-\t\tputs (msg);\n-\t}\n-}\n-\n-/*\n- * Subroutine:  do_log\n- *\n- * Description: Handler for 'log' command..\n- *\n- * Inputs:\targv[1] contains the subcommand\n- *\n- * Return:      None\n- *\n- */\n-int do_log(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])\n-{\n-\tstruct stdio_dev *sdev = NULL;\n-\tchar *s;\n-\tunsigned long i, start, size;\n-\n-\tif (strcmp(argv[1], \"append\") == 0) {\n-\t\t/* Log concatenation of all arguments separated by spaces */\n-\t\tfor (i = 2; i < argc; i++) {\n-\t\t\tlogbuff_printk(argv[i]);\n-\t\t\tlogbuff_putc(sdev, (i < argc - 1) ? ' ' : '\\n');\n-\t\t}\n-\t\treturn 0;\n-\t}\n-\n-\tswitch (argc) {\n-\n-\tcase 2:\n-\t\tif (strcmp(argv[1], \"show\") == 0) {\n-\t\t\tif (log_version == 2) {\n-\t\t\t\tstart = log->v2.start;\n-\t\t\t\tsize = log->v2.end - log->v2.start;\n-\t\t\t} else {\n-\t\t\t\tstart = log->v1.start;\n-\t\t\t\tsize = log->v1.size;\n-\t\t\t}\n-\t\t\tif (size > LOGBUFF_LEN)\n-\t\t\t\tsize = LOGBUFF_LEN;\n-\t\t\tfor (i = 0; i < size; i++) {\n-\t\t\t\ts = lbuf + ((start + i) & LOGBUFF_MASK);\n-\t\t\t\tputc(*s);\n-\t\t\t}\n-\t\t\treturn 0;\n-\t\t} else if (strcmp(argv[1], \"reset\") == 0) {\n-\t\t\tlogbuff_reset();\n-\t\t\treturn 0;\n-\t\t} else if (strcmp(argv[1], \"info\") == 0) {\n-\t\t\tprintf(\"Logbuffer   at  %08lx\\n\", (unsigned long)lbuf);\n-\t\t\tif (log_version == 2) {\n-\t\t\t\tprintf(\"log_start    =  %08lx\\n\",\n-\t\t\t\t\tlog->v2.start);\n-\t\t\t\tprintf(\"log_end      =  %08lx\\n\", log->v2.end);\n-\t\t\t\tprintf(\"log_con      =  %08lx\\n\", log->v2.con);\n-\t\t\t\tprintf(\"logged_chars =  %08lx\\n\",\n-\t\t\t\t\tlog->v2.chars);\n-\t\t\t}\n-\t\t\telse {\n-\t\t\t\tprintf(\"log_start    =  %08lx\\n\",\n-\t\t\t\t\tlog->v1.start);\n-\t\t\t\tprintf(\"log_size     =  %08lx\\n\",\n-\t\t\t\t\tlog->v1.size);\n-\t\t\t\tprintf(\"logged_chars =  %08lx\\n\",\n-\t\t\t\t\tlog->v1.chars);\n-\t\t\t}\n-\t\t\treturn 0;\n-\t\t}\n-\t\treturn CMD_RET_USAGE;\n-\n-\tdefault:\n-\t\treturn CMD_RET_USAGE;\n-\t}\n-}\n-\n-U_BOOT_CMD(\n-\tlog,     255,\t1,\tdo_log,\n-\t\"manipulate logbuffer\",\n-\t\"info   - show pointer details\\n\"\n-\t\"log reset  - clear contents\\n\"\n-\t\"log show   - show contents\\n\"\n-\t\"log append <msg> - append <msg> to the logbuffer\"\n-);\n-\n-static int logbuff_printk(const char *line)\n-{\n-\tint i;\n-\tchar *msg, *p, *buf_end;\n-\tint line_feed;\n-\tstatic signed char msg_level = -1;\n-\n-\tstrcpy(buf + 3, line);\n-\ti = strlen(line);\n-\tbuf_end = buf + 3 + i;\n-\tfor (p = buf + 3; p < buf_end; p++) {\n-\t\tmsg = p;\n-\t\tif (msg_level < 0) {\n-\t\t\tif (\n-\t\t\t\tp[0] != '<' ||\n-\t\t\t\tp[1] < '0' ||\n-\t\t\t\tp[1] > '7' ||\n-\t\t\t\tp[2] != '>'\n-\t\t\t) {\n-\t\t\t\tp -= 3;\n-\t\t\t\tp[0] = '<';\n-\t\t\t\tp[1] = default_message_loglevel + '0';\n-\t\t\t\tp[2] = '>';\n-\t\t\t} else {\n-\t\t\t\tmsg += 3;\n-\t\t\t}\n-\t\t\tmsg_level = p[1] - '0';\n-\t\t}\n-\t\tline_feed = 0;\n-\t\tfor (; p < buf_end; p++) {\n-\t\t\tif (log_version == 2) {\n-\t\t\t\tlbuf[log->v2.end & LOGBUFF_MASK] = *p;\n-\t\t\t\tlog->v2.end++;\n-\t\t\t\tif (log->v2.end - log->v2.start > LOGBUFF_LEN)\n-\t\t\t\t\tlog->v2.start++;\n-\t\t\t\tlog->v2.chars++;\n-\t\t\t} else {\n-\t\t\t\tlbuf[(log->v1.start + log->v1.size) &\n-\t\t\t\t\t LOGBUFF_MASK] = *p;\n-\t\t\t\tif (log->v1.size < LOGBUFF_LEN)\n-\t\t\t\t\tlog->v1.size++;\n-\t\t\t\telse\n-\t\t\t\t\tlog->v1.start++;\n-\t\t\t\tlog->v1.chars++;\n-\t\t\t}\n-\t\t\tif (*p == '\\n') {\n-\t\t\t\tline_feed = 1;\n-\t\t\t\tbreak;\n-\t\t\t}\n-\t\t}\n-\t\tif (msg_level < console_loglevel) {\n-\t\t\tprintf(\"%s\", msg);\n-\t\t}\n-\t\tif (line_feed)\n-\t\t\tmsg_level = -1;\n-\t}\n-\treturn i;\n-}\ndiff --git a/common/board_f.c b/common/board_f.c\nindex 104d144f41..d0b1a00175 100644\n--- a/common/board_f.c\n+++ b/common/board_f.c\n@@ -19,7 +19,6 @@\n #include <i2c.h>\n #include <initcall.h>\n #include <init_helpers.h>\n-#include <logbuff.h>\n #include <malloc.h>\n #include <mapmem.h>\n #include <os.h>\n@@ -296,20 +295,6 @@ static int setup_dest_addr(void)\n \treturn 0;\n }\n \n-#if defined(CONFIG_LOGBUFFER)\n-static int reserve_logbuffer(void)\n-{\n-#ifndef CONFIG_ALT_LB_ADDR\n-\t/* reserve kernel log buffer */\n-\tgd->relocaddr -= LOGBUFF_RESERVE;\n-\tdebug(\"Reserving %dk for kernel logbuffer at %08lx\\n\", LOGBUFF_LEN,\n-\t\tgd->relocaddr);\n-#endif\n-\n-\treturn 0;\n-}\n-#endif\n-\n #ifdef CONFIG_PRAM\n /* reserve protected RAM */\n static int reserve_pram(void)\n@@ -846,9 +831,6 @@ static const init_fnc_t init_sequence_f[] = {\n \t *  - board info struct\n \t */\n \tsetup_dest_addr,\n-#if defined(CONFIG_LOGBUFFER)\n-\treserve_logbuffer,\n-#endif\n #ifdef CONFIG_PRAM\n \treserve_pram,\n #endif\ndiff --git a/common/board_r.c b/common/board_r.c\nindex 94697e7bc1..02ac43d39c 100644\n--- a/common/board_r.c\n+++ b/common/board_r.c\n@@ -33,7 +33,6 @@\n #if defined(CONFIG_CMD_KGDB)\n #include <kgdb.h>\n #endif\n-#include <logbuff.h>\n #include <malloc.h>\n #include <mapmem.h>\n #ifdef CONFIG_BITBANGMII\n@@ -203,19 +202,6 @@ static int initr_addr_map(void)\n }\n #endif\n \n-#ifdef CONFIG_LOGBUFFER\n-unsigned long logbuffer_base(void)\n-{\n-\treturn gd->ram_top - LOGBUFF_LEN;\n-}\n-\n-static int initr_logbuffer(void)\n-{\n-\tlogbuff_init_ptrs();\n-\treturn 0;\n-}\n-#endif\n-\n #ifdef CONFIG_POST\n static int initr_post_backlog(void)\n {\n@@ -640,7 +626,7 @@ static int initr_ide(void)\n }\n #endif\n \n-#if defined(CONFIG_PRAM) || defined(CONFIG_LOGBUFFER)\n+#if defined(CONFIG_PRAM)\n /*\n  * Export available size of memory for Linux, taking into account the\n  * protected RAM at top of memory\n@@ -652,10 +638,6 @@ int initr_mem(void)\n \n # ifdef CONFIG_PRAM\n \tpram = env_get_ulong(\"pram\", 10, CONFIG_PRAM);\n-# endif\n-# if defined(CONFIG_LOGBUFFER) && !defined(CONFIG_ALT_LB_ADDR)\n-\t/* Also take the logbuffer into account (pram is in kB) */\n-\tpram += (LOGBUFF_LEN + LOGBUFF_OVERHEAD) / 1024;\n # endif\n \tsprintf(memsz, \"%ldk\", (long int) ((gd->ram_size / 1024) - pram));\n \tenv_set(\"mem\", memsz);\n@@ -765,9 +747,6 @@ static init_fnc_t init_sequence_r[] = {\n \tboard_early_init_r,\n #endif\n \tINIT_FUNC_WATCHDOG_RESET\n-#ifdef CONFIG_LOGBUFFER\n-\tinitr_logbuffer,\n-#endif\n #ifdef CONFIG_POST\n \tinitr_post_backlog,\n #endif\n@@ -892,7 +871,7 @@ static init_fnc_t init_sequence_r[] = {\n \tINIT_FUNC_WATCHDOG_RESET\n \tinitr_bedbug,\n #endif\n-#if defined(CONFIG_PRAM) || defined(CONFIG_LOGBUFFER)\n+#if defined(CONFIG_PRAM)\n \tinitr_mem,\n #endif\n #ifdef CONFIG_PS2KBD\ndiff --git a/common/image.c b/common/image.c\nindex 332b5f2843..123b0fb75d 100644\n--- a/common/image.c\n+++ b/common/image.c\n@@ -19,10 +19,6 @@\n #include <dataflash.h>\n #endif\n \n-#ifdef CONFIG_LOGBUFFER\n-#include <logbuff.h>\n-#endif\n-\n #include <rtc.h>\n \n #include <environment.h>\n@@ -1238,11 +1234,6 @@ int boot_ramdisk_high(struct lmb *lmb, ulong rd_data, ulong rd_len,\n \t}\n \n \n-#ifdef CONFIG_LOGBUFFER\n-\t/* Prevent initrd from overwriting logbuffer */\n-\tlmb_reserve(lmb, logbuffer_base() - LOGBUFF_OVERHEAD, LOGBUFF_RESERVE);\n-#endif\n-\n \tdebug(\"## initrd_high = 0x%08lx, copy_to_ram = %d\\n\",\n \t\t\tinitrd_high, initrd_copy_to_ram);\n \ndiff --git a/common/stdio.c b/common/stdio.c\nindex ee4f0bda9e..2e5143a025 100644\n--- a/common/stdio.c\n+++ b/common/stdio.c\n@@ -17,9 +17,6 @@\n #include <malloc.h>\n #include <stdio_dev.h>\n #include <serial.h>\n-#ifdef CONFIG_LOGBUFFER\n-#include <logbuff.h>\n-#endif\n \n #if defined(CONFIG_SYS_I2C)\n #include <i2c.h>\n@@ -380,9 +377,6 @@ int stdio_add_devices(void)\n #endif /* CONFIG_DM_VIDEO */\n #if defined(CONFIG_KEYBOARD) && !defined(CONFIG_DM_KEYBOARD)\n \tdrv_keyboard_init ();\n-#endif\n-#ifdef CONFIG_LOGBUFFER\n-\tdrv_logbuff_init ();\n #endif\n \tdrv_system_init ();\n \tserial_stdio_init ();\ndiff --git a/include/asm-generic/global_data.h b/include/asm-generic/global_data.h\nindex 944f58195c..79197acfa4 100644\n--- a/include/asm-generic/global_data.h\n+++ b/include/asm-generic/global_data.h\n@@ -36,7 +36,7 @@ typedef struct global_data {\n #if defined(CONFIG_LCD) || defined(CONFIG_VIDEO)\n \tunsigned long fb_base;\t\t/* Base address of framebuffer mem */\n #endif\n-#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER)\n+#if defined(CONFIG_POST)\n \tunsigned long post_log_word;\t/* Record POST activities */\n \tunsigned long post_log_res;\t/* success of POST test */\n \tunsigned long post_init_f_time;\t/* When post_init_f started */\ndiff --git a/include/logbuff.h b/include/logbuff.h\ndeleted file mode 100644\nindex 625feb9f95..0000000000\n--- a/include/logbuff.h\n+++ /dev/null\n@@ -1,49 +0,0 @@\n-/*\n- * (C) Copyright 2002-2007\n- * Detlev Zundel, dzu@denx.de.\n- *\n- * SPDX-License-Identifier:\tGPL-2.0+\n- */\n-#ifndef _LOGBUFF_H\n-#define _LOGBUFF_H\n-\n-#ifdef CONFIG_LOGBUFFER\n-\n-#define LOGBUFF_MAGIC\t0xc0de4ced\t/* Forced by code, eh!\t*/\n-#define LOGBUFF_LEN\t(16384)\t/* Must be 16k right now */\n-#define LOGBUFF_MASK\t(LOGBUFF_LEN-1)\n-#define LOGBUFF_OVERHEAD (4096) /* Logbuffer overhead for extra info */\n-#define LOGBUFF_RESERVE (LOGBUFF_LEN+LOGBUFF_OVERHEAD)\n-\n-/* The mapping used here has to be the same as in setup_ext_logbuff ()\n-   in linux/kernel/printk */\n-\n-typedef struct {\n-\tunion {\n-\t\tstruct {\n-\t\t\tunsigned long\ttag;\n-\t\t\tunsigned long\tstart;\n-\t\t\tunsigned long\tcon;\n-\t\t\tunsigned long\tend;\n-\t\t\tunsigned long\tchars;\n-\t\t} v2;\n-\t\tstruct {\n-\t\t\tunsigned long\tdummy;\n-\t\t\tunsigned long\ttag;\n-\t\t\tunsigned long\tstart;\n-\t\t\tunsigned long\tsize;\n-\t\t\tunsigned long\tchars;\n-\t\t} v1;\n-\t};\n-\tunsigned char\tbuf[0];\n-} logbuff_t;\n-\n-int drv_logbuff_init (void);\n-void logbuff_init_ptrs (void);\n-void logbuff_log(char *msg);\n-void logbuff_reset (void);\n-unsigned long logbuffer_base (void);\n-\n-#endif /* CONFIG_LOGBUFFER */\n-\n-#endif /* _LOGBUFF_H */\ndiff --git a/include/post.h b/include/post.h\nindex d5278111e8..b41a6c8127 100644\n--- a/include/post.h\n+++ b/include/post.h\n@@ -15,7 +15,7 @@\n #include <common.h>\n #include <asm/io.h>\n \n-#if defined(CONFIG_POST) || defined(CONFIG_LOGBUFFER)\n+#if defined(CONFIG_POST)\n \n #ifndef CONFIG_POST_EXTERNAL_WORD_FUNCS\n #ifdef CONFIG_SYS_POST_WORD_ADDR\n@@ -58,7 +58,7 @@ extern ulong post_word_load(void);\n extern void post_word_store(ulong value);\n \n #endif /* CONFIG_POST_EXTERNAL_WORD_FUNCS */\n-#endif /* defined (CONFIG_POST) || defined(CONFIG_LOGBUFFER) */\n+#endif /* defined (CONFIG_POST) */\n #endif /* __ASSEMBLY__ */\n \n #ifdef CONFIG_POST\ndiff --git a/post/post.c b/post/post.c\nindex 8fef0c3412..6c7902ad0c 100644\n--- a/post/post.c\n+++ b/post/post.c\n@@ -15,10 +15,6 @@\n #include <asm/gpio.h>\n #endif\n \n-#ifdef CONFIG_LOGBUFFER\n-#include <logbuff.h>\n-#endif\n-\n DECLARE_GLOBAL_DATA_PTR;\n \n #define POST_MAX_NUMBER\t\t32\n@@ -407,13 +403,8 @@ int post_log(char *format, ...)\n \tvsprintf(printbuffer, format, args);\n \tva_end(args);\n \n-#ifdef CONFIG_LOGBUFFER\n-\t/* Send to the logbuffer */\n-\tlogbuff_log(printbuffer);\n-#else\n \t/* Send to the stdout file */\n \tputs(printbuffer);\n-#endif\n \n \treturn 0;\n }\ndiff --git a/post/tests.c b/post/tests.c\nindex bc8e398051..473c0ea1e1 100644\n--- a/post/tests.c\n+++ b/post/tests.c\n@@ -3,10 +3,6 @@\n  * Wolfgang Denk, DENX Software Engineering, wd@denx.de.\n  *\n  * SPDX-License-Identifier:\tGPL-2.0+\n- *\n- * Be sure to mark tests to be run before relocation as such with the\n- * CONFIG_SYS_POST_PREREL flag so that logging is done correctly if the\n- * logbuffer support is enabled.\n  */\n \n #include <common.h>\ndiff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt\nindex 56bb639091..7689410243 100644\n--- a/scripts/config_whitelist.txt\n+++ b/scripts/config_whitelist.txt\n@@ -1292,7 +1292,6 @@ CONFIG_LMS283GF05\n CONFIG_LOADADDR\n CONFIG_LOADCMD\n CONFIG_LOADS_ECHO\n-CONFIG_LOGBUFFER\n CONFIG_LOWPOWER_ADDR\n CONFIG_LOWPOWER_FLAG\n CONFIG_LOW_MCFCLK\n",
    "prefixes": [
        "U-Boot",
        "05/13"
    ]
}