Message ID | 20171120223335.45852-4-sjg@chromium.org |
---|---|
State | Changes Requested |
Delegated to: | Tom Rini |
Headers | show
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; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=google.com header.i=@google.com header.b="dldYY0WI"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 3ygk8r2v24z9sRW for <incoming@patchwork.ozlabs.org>; Tue, 21 Nov 2017 09:36:28 +1100 (AEDT) Received: by lists.denx.de (Postfix, from userid 105) id EEB9FC220B4; Mon, 20 Nov 2017 22:34:46 +0000 (UTC) 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, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 11198C220F8; Mon, 20 Nov 2017 22:34:04 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 063D3C220DF; Mon, 20 Nov 2017 22:33:53 +0000 (UTC) Received: from mail-it0-f68.google.com (mail-it0-f68.google.com [209.85.214.68]) by lists.denx.de (Postfix) with ESMTPS id B5711C220C1 for <u-boot@lists.denx.de>; Mon, 20 Nov 2017 22:33:46 +0000 (UTC) Received: by mail-it0-f68.google.com with SMTP id x28so13914981ita.0 for <u-boot@lists.denx.de>; Mon, 20 Nov 2017 14:33:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=UTA8CKpkbVLS1NFS07XjzX8b5+4ZARcPkMc/R1Nazic=; b=dldYY0WIWDBqN5Tl4iae1BA69TJK1ScPudl7DVGRcmjgSYe/AFTXiAL2LsVbNrhRvP mAr+cwnGxhnlPp5DKJ1KMyZapWr0vwMqRWZrH2YtxphCGEIgz0mjeNzlj+vvEQAz1CeA 9JCI2SAHNYmfQfCyyG7sUtRxC0CkFdHnmoLA/hFVjzphlR3X5efXfqUOP013NYeS1gvs pBUqkyF9Lts9ClEiHctuhXGzfkasNet5qiCZU2cwloOsBMQAgVE1kBOuUO6DTeVXqDoZ gV/fb0fNM+YtVLiHyl0mookSx+/Lt9gsuvpZu6lPZ+BU+b/D0IyxZxzSl2Psap4X+Etn j7Tg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=UTA8CKpkbVLS1NFS07XjzX8b5+4ZARcPkMc/R1Nazic=; b=dpivP8c1Odr5tSkPZbfyPPz36osPdBX39/IB+pAG5QvMFltS46yj0RmRcaRacDfCEz BchvdPQYx9v6u/d4iLqSRnE0Fci2J2z55k5TLdO6Csd3i2/5NX4uWcbMJN4RmRzIki75 urLhMjlZP6tSKCCtCD0ZrMCeLEYfHmw2xRzjPnpQMv0hMzLnelF/6P8910MSi/1mhl4r U3ajQbky0eWGlZa6cGOTrn/1d/G0cGixNy9bULLZMmXPQ665TNLYy5mF4RsS/dyVLJYk /gq4t+Q2In7o6ybrlDockRGLLiArkdPArj90Ku1QqEWtU+PcUp7UZOVQmT9paLXkJxF4 X1cA== X-Gm-Message-State: AJaThX6ADnuNd/+EYStTslvI0/QpuCj2rZUN6QZSLqYSBVKGP3AcWZpR 0OIIuzNoEEGjlshn/89EV/P8Fw== X-Google-Smtp-Source: AGs4zMYHQXqNkS0ddO1cer1roz+JgY9hRpV2YbYcTj/aWwSRBtNm4aJE/RgWC6Oppwh06xXXeahvxA== X-Received: by 10.36.66.18 with SMTP id i18mr21446669itb.148.1511217225253; Mon, 20 Nov 2017 14:33:45 -0800 (PST) Received: from kiwi.bld.corp.google.com ([100.101.164.89]) by smtp.gmail.com with ESMTPSA id h140sm4860162iof.81.2017.11.20.14.33.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 20 Nov 2017 14:33:43 -0800 (PST) Received: by kiwi.bld.corp.google.com (Postfix, from userid 121222) id 9174F14001C; Mon, 20 Nov 2017 15:33:42 -0700 (MST) From: Simon Glass <sjg@chromium.org> To: U-Boot Mailing List <u-boot@lists.denx.de> Date: Mon, 20 Nov 2017 15:33:24 -0700 Message-Id: <20171120223335.45852-4-sjg@chromium.org> X-Mailer: git-send-email 2.15.0.448.gf294e3d99a-goog In-Reply-To: <20171120223335.45852-1-sjg@chromium.org> References: <20171120223335.45852-1-sjg@chromium.org> Cc: Tom Rini <trini@konsulko.com> Subject: [U-Boot] [PATCH v3 03/14] Revert "sandbox: Drop special case console code for sandbox" 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>, <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>, <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> |
Series |
log: Add a new logging feature
|
expand
|
diff --git a/common/console.c b/common/console.c index d763f2c6846..0e0295514b2 100644 --- a/common/console.c +++ b/common/console.c @@ -489,6 +489,13 @@ static inline void print_pre_console_buffer(int flushpoint) {} void putc(const char c) { +#ifdef CONFIG_SANDBOX + /* sandbox can send characters to stdout before it has a console */ + if (!gd || !(gd->flags & GD_FLG_SERIAL_READY)) { + os_putc(c); + return; + } +#endif #ifdef CONFIG_DEBUG_UART /* if we don't have a console yet, use the debug UART */ if (!gd || !(gd->flags & GD_FLG_SERIAL_READY)) {
While sandbox works OK without the special-case code, it does result in console output being stored in the pre-console buffer while sandbox starts up. If there is a crash or a problem then there is no indication of what is going on. For ease of debugging it seems better to revert this change also. This reverts commit d8c6fb8cedbc35eee27730a7fa544e499b3c81cc. Signed-off-by: Simon Glass <sjg@chromium.org> --- Changes in v3: None Changes in v2: None common/console.c | 7 +++++++ 1 file changed, 7 insertions(+)