U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Patrick Delaunay <patrick.delaunay@foss.st.com>
To: u-boot@lists.denx.de
Subject: [PATCH v3 0/4] console: remove #ifdef CONFIG when it is possible
Date: Fri, 18 Dec 2020 12:46:42 +0100	[thread overview]
Message-ID: <20201218114646.9902-1-patrick.delaunay@foss.st.com> (raw)


Hi,

It is the V3 of serie [1] after Simon Glass comments.

Use 'if (IS_ENABLED(CONFIG...))' instead of '#if or #ifdef' where possible

This patchset can applied on master branch after the serie [2]
(for the new order of test in function putc() and puts()
 done in "console: allow to record console output before ready"
)

For information:

I try to remove the sandox code in [3] (with the associated tests
#ifdef CONFIG_SANDBOX) but it wasn't a correct idea.

I will pushed a separate serie to remove the remaining
#ifdef CONFIG_VIDCONSOLE_AS_LCD [4]

[1] http://patchwork.ozlabs.org/project/uboot/list/?series=218309

[2] http://patchwork.ozlabs.org/project/uboot/list/?series=217079
    "log: don't build the trace buffer when log is not ready"

[3] http://patchwork.ozlabs.org/project/uboot/patch/20201127114927.2.Ida70f4fb1524187703e9240d63e436f8ae5adaab at changeid/
    "[2/2] console: sandbox: remove unnecessary sandbox code"

[4] http://patchwork.ozlabs.org/project/uboot/list/?series=218307
    "video: remove VIDCONSOLE_AS_LCD and VIDCONSOLE_AS_NAME"


Changes in v3:
- update commit message with new function name console_has_tstc

Changes in v2:
- update also #ifdef CONFIG_SANDBOX after Simon Glass remark
  (code can't be removed to avoid to rely sandbox on debug uart)
- move the tests on gd->flags & GD_FLG_RECORD in helper functions
- remove test on IS_ENABLED(CONFIG_CONSOLE_RECORD)
  before to call helper functions
- add comment for tstcdev variable
- rename console_tstc_check to console_has_tstc

Patrick Delaunay (4):
  console: remove #ifdef CONFIG when it is possible
  console: add function console_devices_set
  console: remove #ifdef CONFIG_CONSOLE_RECORD
  console: add console_has_tstc helper function for CONSOLE_MUX

 common/console.c | 310 ++++++++++++++++++++++++++---------------------
 1 file changed, 175 insertions(+), 135 deletions(-)

-- 
2.17.1

             reply	other threads:[~2020-12-18 11:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-18 11:46 Patrick Delaunay [this message]
2020-12-18 11:46 ` [PATCH v3 1/4] console: remove #ifdef CONFIG when it is possible Patrick Delaunay
2020-12-19  3:34   ` Simon Glass
2021-01-16 16:24   ` Tom Rini
2020-12-18 11:46 ` [PATCH v3 2/4] console: add function console_devices_set Patrick Delaunay
2021-01-16 16:24   ` Tom Rini
2020-12-18 11:46 ` [PATCH v3 3/4] console: remove #ifdef CONFIG_CONSOLE_RECORD Patrick Delaunay
2020-12-19  3:34   ` Simon Glass
2021-01-04 13:18     ` Patrick DELAUNAY
2021-01-16 16:24   ` Tom Rini
2020-12-18 11:46 ` [PATCH v3 4/4] console: add console_has_tstc helper function for CONSOLE_MUX Patrick Delaunay
2020-12-19  3:34   ` Simon Glass
2021-01-16 16:24   ` 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=20201218114646.9902-1-patrick.delaunay@foss.st.com \
    --to=patrick.delaunay@foss.st.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox