All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simon Glass <sjg@chromium.org>
To: u-boot@lists.denx.de
Subject: [PATCH v4 1/2] sandbox: log: Avoid build error with !CONFIG_LOG
Date: Sat,  8 May 2021 13:46:53 -0600	[thread overview]
Message-ID: <20210508194654.1760567-2-sjg@chromium.org> (raw)
In-Reply-To: <20210508194654.1760567-1-sjg@chromium.org>

The pr_cont_test.c test requires CONFIG_LOG since it directly accesses
fields in global_data that require it. Move the test into the CONFIG_LOG
condition to avoid build errors.

Enable CONFIG_LOG on sandbox (not sandbox_spl, etc.) so that we still run
this test. This requires resyncing of the configs.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

(no changes since v1)

 configs/sandbox_defconfig | 1 +
 test/log/Makefile         | 1 +
 2 files changed, 2 insertions(+)

diff --git a/configs/sandbox_defconfig b/configs/sandbox_defconfig
index bdbf714e2bd..60cdad10848 100644
--- a/configs/sandbox_defconfig
+++ b/configs/sandbox_defconfig
@@ -21,6 +21,7 @@ CONFIG_BOOTSTAGE_STASH_SIZE=0x4096
 CONFIG_CONSOLE_RECORD=y
 CONFIG_CONSOLE_RECORD_OUT_SIZE=0x1000
 CONFIG_PRE_CONSOLE_BUFFER=y
+CONFIG_LOG=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_MISC_INIT_F=y
 CONFIG_STACKPROTECTOR=y
diff --git a/test/log/Makefile b/test/log/Makefile
index a3dedace043..09f8689d070 100644
--- a/test/log/Makefile
+++ b/test/log/Makefile
@@ -17,6 +17,7 @@ endif
 ifdef CONFIG_LOG
 obj-y += pr_cont_test.o
 obj-$(CONFIG_CONSOLE_RECORD) += cont_test.o
+obj-y += pr_cont_test.o
 else
 obj-$(CONFIG_CONSOLE_RECORD) += nolog_test.o
 endif
-- 
2.31.1.607.g51e8a6a459-goog

  reply	other threads:[~2021-05-08 19:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-08 19:46 [PATCH v4 0/2] log: Allow multiple lines and conversion to printf() Simon Glass
2021-05-08 19:46 ` Simon Glass [this message]
2021-05-08 19:46 ` [PATCH v4 2/2] log: Convert log values to printf() if not enabled Simon Glass
2021-06-08 21:43 ` [PATCH v4 0/2] log: Allow multiple lines and conversion to printf() Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210508194654.1760567-2-sjg@chromium.org \
    --to=sjg@chromium.org \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.