[U-Boot] [PATCH 1/3] ddr: fsl: Do not allow for interactive mode in SPL

York Sun york.sun at nxp.com
Fri Dec 22 05:29:31 UTC 2017


Why not? I used it before.

York

Sent from my iPhone

> On Dec 21, 2017, at 19:13, Tom Rini <trini at konsulko.com> wrote:
> 
> While the code in question here is used in SPL, it cannot be used in
> interactive mode in SPL.  We need a compile-time guard here in order to
> be able to not include further bits of code.
> 
> Cc: York Sun <york.sun at nxp.com>
> Signed-off-by: Tom Rini <trini at konsulko.com>
> ---
> drivers/ddr/fsl/main.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/ddr/fsl/main.c b/drivers/ddr/fsl/main.c
> index d0a7b3f10763..b9f177f71d10 100644
> --- a/drivers/ddr/fsl/main.c
> +++ b/drivers/ddr/fsl/main.c
> @@ -633,7 +633,7 @@ phys_size_t __fsl_ddr_sdram(fsl_ddr_info_t *pinfo)
>    last_ctrl = first_ctrl + pinfo->num_ctrls - 1;
> 
>    /* Compute it once normally. */
> -#ifdef CONFIG_FSL_DDR_INTERACTIVE
> +#if defined(CONFIG_FSL_DDR_INTERACTIVE) && !defined(CONFIG_SPL_BUILD)
>    if (tstc() && (getc() == 'd')) {    /* we got a key press of 'd' */
>        total_memory = fsl_ddr_interactive(pinfo, 0);
>    } else if (fsl_ddr_interactive_env_var_exists()) {
> -- 
> 2.7.4
> 


More information about the U-Boot mailing list