All of lore.kernel.org
 help / color / mirror / Atom feed
From: Adam Ford <aford173@gmail.com>
To: u-boot@lists.denx.de
Subject: [PATCH 03/13] imx: ddr: imx8m: add print for DRAM rate
Date: Mon, 28 Dec 2020 07:53:38 -0600	[thread overview]
Message-ID: <CAHCN7xJ6GHfkRwZBjK+vrijnfCKAPYZXX34+7+YNrZiv79CXcg@mail.gmail.com> (raw)
In-Reply-To: <20201228121710.17235-3-peng.fan@oss.nxp.com>

On Mon, Dec 28, 2020 at 7:27 AM Peng Fan (OSS) <peng.fan@oss.nxp.com> wrote:
>
> From: Ye Li <ye.li@nxp.com>
>
> Enable print to show the DRAM rate of current setting and training
> result.
>
> Signed-off-by: Ye Li <ye.li@nxp.com>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---
>  drivers/ddr/imx/imx8m/ddr_init.c     | 7 ++++---
>  drivers/ddr/imx/imx8m/ddrphy_utils.c | 2 +-
>  2 files changed, 5 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/ddr/imx/imx8m/ddr_init.c b/drivers/ddr/imx/imx8m/ddr_init.c
> index 99a67edfb0..65739dbaa7 100644
> --- a/drivers/ddr/imx/imx8m/ddr_init.c
> +++ b/drivers/ddr/imx/imx8m/ddr_init.c
> @@ -96,7 +96,7 @@ int ddr_init(struct dram_timing_info *dram_timing)
>         unsigned int tmp, initial_drate, target_freq;
>         int ret;
>
> -       debug("DDRINFO: start DRAM init\n");
> +       printf("DDRINFO: start DRAM init\n");

Why not make this optional?  With debug enabled, it will print.  This
makes extra chatter for everyone.
It also undoes: 0d3bc813  ("imx8m: ddr_init: Move ddr_init() messages
to debug level")

>
>         /* Step1: Follow the power up procedure */
>         if (is_imx8mq()) {
> @@ -119,6 +119,7 @@ int ddr_init(struct dram_timing_info *dram_timing)
>
>         initial_drate = dram_timing->fsp_msg[0].drate;
>         /* default to the frequency point 0 clock */
> +       printf("DDRINFO: DRAM rate %dMTS\n", initial_drate);
>         ddrphy_init_set_dfi_clk(initial_drate);
>
>         /* D-aasert the presetn */
> @@ -185,7 +186,7 @@ int ddr_init(struct dram_timing_info *dram_timing)
>                 tmp = reg32_read(DDRPHY_CalBusy(0));
>         } while ((tmp & 0x1));
>
> -       debug("DDRINFO:ddrphy calibration done\n");
> +       printf("DDRINFO:ddrphy calibration done\n");
>
>         /* Step15: Set SWCTL.sw_done to 0 */
>         reg32_write(DDRC_SWCTL(0), 0x00000000);
> @@ -240,7 +241,7 @@ int ddr_init(struct dram_timing_info *dram_timing)
>
>         /* enable port 0 */
>         reg32_write(DDRC_PCTRL_0(0), 0x00000001);
> -       debug("DDRINFO: ddrmix config done\n");
> +       printf("DDRINFO: ddrmix config done\n");
>
>         board_dram_ecc_scrub();
>
> diff --git a/drivers/ddr/imx/imx8m/ddrphy_utils.c b/drivers/ddr/imx/imx8m/ddrphy_utils.c
> index 0f8baefb1f..326b92d784 100644
> --- a/drivers/ddr/imx/imx8m/ddrphy_utils.c
> +++ b/drivers/ddr/imx/imx8m/ddrphy_utils.c
> @@ -104,7 +104,7 @@ int wait_ddrphy_training_complete(void)
>                         debug("Training PASS\n");
>                         return 0;
>                 } else if (mail == 0xff) {
> -                       debug("Training FAILED\n");
> +                       printf("Training FAILED\n");
>                         return -1;
>                 }
>         }
> --
> 2.28.0
>

  reply	other threads:[~2020-12-28 13:53 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-28 12:16 [PATCH 01/13] imx: imx8mp_evk: enable eth support Peng Fan
2020-12-28 12:16 ` [PATCH 02/13] imx: imx8mn_ddr4_evk: Use CONFIG_TARGET_IMX8MN_DDR4_EVK for DDR4 EVK board Peng Fan
2020-12-28 12:17 ` [PATCH 03/13] imx: ddr: imx8m: add print for DRAM rate Peng Fan
2020-12-28 13:53   ` Adam Ford [this message]
2020-12-28 14:01     ` Fabio Estevam
2020-12-28 12:17 ` [PATCH 04/13] imx: ddr: imx8m: Move selfref_en after DDR scrub Peng Fan
2020-12-28 12:17 ` [PATCH 05/13] imx: imx8mn_evk: correct stack/malloc adress Peng Fan
2020-12-28 21:42   ` ZHIZHIKIN Andrey
2020-12-29  1:27     ` Peng Fan
2020-12-29 12:19   ` Adam Ford
2020-12-30  0:55     ` Peng Fan
2020-12-28 12:17 ` [PATCH 06/13] arm: dts: imx8mn: sync dts from Linux Kernel Peng Fan
2020-12-28 12:17 ` [PATCH 07/13] imx: imx8mn: add i.MX8MN LPDDR4 EVK support Peng Fan
2020-12-28 21:54   ` ZHIZHIKIN Andrey
2020-12-29  1:28     ` Peng Fan
2020-12-28 12:17 ` [PATCH 08/13] imx8m: clock: add type of set_clk_eqos Peng Fan
2020-12-28 12:17 ` [PATCH 09/13] arm: dts: imx8mp: sync dts from Linux Kernel Peng Fan
2020-12-28 12:17 ` [PATCH 10/13] arm: dts: imx8mm: " Peng Fan
2020-12-28 12:17 ` [PATCH 11/13] arm: dts: imx8mq: " Peng Fan
2020-12-28 12:17 ` [PATCH 12/13] imx8m: lowlevel_init: tune alignment Peng Fan
2020-12-28 12:17 ` [PATCH 13/13] imx: imx8m: move CONFIG_SPL_SYS_[I, D]CACHE_OFF to defconfig Peng Fan
2020-12-28 21:34 ` [PATCH 01/13] imx: imx8mp_evk: enable eth support ZHIZHIKIN Andrey
2020-12-28 22:00 ` Fabio Estevam
2020-12-29  1:26   ` Peng Fan

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=CAHCN7xJ6GHfkRwZBjK+vrijnfCKAPYZXX34+7+YNrZiv79CXcg@mail.gmail.com \
    --to=aford173@gmail.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 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.