public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register
@ 2012-06-19 17:24 Fabio Estevam
  2012-06-19 21:12 ` Marek Vasut
  2012-07-02 17:51 ` Stefano Babic
  0 siblings, 2 replies; 4+ messages in thread
From: Fabio Estevam @ 2012-06-19 17:24 UTC (permalink / raw)
  To: u-boot

commit acc4959fc1 (Revert "i.MX28: Enable additional DRAM address bits")
broke mx28evk boot.

Fix it by properly adjusting the HW_DRAM_CTL29 register value.

Suggested-by: Marek Vasut <marex@denx.de>
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
 board/freescale/mx28evk/iomux.c |   14 ++++++++++++++
 1 files changed, 14 insertions(+), 0 deletions(-)

diff --git a/board/freescale/mx28evk/iomux.c b/board/freescale/mx28evk/iomux.c
index 6587c45..1e60204 100644
--- a/board/freescale/mx28evk/iomux.c
+++ b/board/freescale/mx28evk/iomux.c
@@ -161,6 +161,20 @@ const iomux_cfg_t iomux_setup[] = {
 		(MXS_PAD_3V3 | MXS_PAD_8MA | MXS_PAD_PULLUP),
 };
 
+#define HW_DRAM_CTL29	(0x74 >> 2)
+#define CS_MAP		0xf
+#define COLUMN_SIZE	0x2
+#define ADDR_PINS	0x1
+#define APREBIT		0xa
+
+#define HW_DRAM_CTL29_CONFIG	(CS_MAP << 24 | COLUMN_SIZE << 16 | \
+					ADDR_PINS << 8 | APREBIT)
+
+void mx28_adjust_memory_params(uint32_t *dram_vals)
+{
+	dram_vals[HW_DRAM_CTL29] = HW_DRAM_CTL29_CONFIG;
+}
+
 void board_init_ll(void)
 {
 	mx28_common_spl_init(iomux_setup, ARRAY_SIZE(iomux_setup));
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register
  2012-06-19 17:24 [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register Fabio Estevam
@ 2012-06-19 21:12 ` Marek Vasut
  2012-06-27 13:17   ` Fabio Estevam
  2012-07-02 17:51 ` Stefano Babic
  1 sibling, 1 reply; 4+ messages in thread
From: Marek Vasut @ 2012-06-19 21:12 UTC (permalink / raw)
  To: u-boot

Dear Fabio Estevam,

> commit acc4959fc1 (Revert "i.MX28: Enable additional DRAM address bits")
> broke mx28evk boot.
> 
> Fix it by properly adjusting the HW_DRAM_CTL29 register value.
> 
> Suggested-by: Marek Vasut <marex@denx.de>
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---
>  board/freescale/mx28evk/iomux.c |   14 ++++++++++++++
>  1 files changed, 14 insertions(+), 0 deletions(-)
> 
> diff --git a/board/freescale/mx28evk/iomux.c

Uh, why isn't this file called splboot.c?

But
Acked-by: Marek Vasut <marex@denx.de>

> b/board/freescale/mx28evk/iomux.c index 6587c45..1e60204 100644
> --- a/board/freescale/mx28evk/iomux.c
> +++ b/board/freescale/mx28evk/iomux.c
> @@ -161,6 +161,20 @@ const iomux_cfg_t iomux_setup[] = {
>  		(MXS_PAD_3V3 | MXS_PAD_8MA | MXS_PAD_PULLUP),
>  };
> 
> +#define HW_DRAM_CTL29	(0x74 >> 2)
> +#define CS_MAP		0xf
> +#define COLUMN_SIZE	0x2
> +#define ADDR_PINS	0x1
> +#define APREBIT		0xa
> +
> +#define HW_DRAM_CTL29_CONFIG	(CS_MAP << 24 | COLUMN_SIZE << 16 | \
> +					ADDR_PINS << 8 | APREBIT)
> +
> +void mx28_adjust_memory_params(uint32_t *dram_vals)
> +{
> +	dram_vals[HW_DRAM_CTL29] = HW_DRAM_CTL29_CONFIG;
> +}
> +
>  void board_init_ll(void)
>  {
>  	mx28_common_spl_init(iomux_setup, ARRAY_SIZE(iomux_setup));

Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register
  2012-06-19 21:12 ` Marek Vasut
@ 2012-06-27 13:17   ` Fabio Estevam
  0 siblings, 0 replies; 4+ messages in thread
From: Fabio Estevam @ 2012-06-27 13:17 UTC (permalink / raw)
  To: u-boot

Hi Stefano,

On Tue, Jun 19, 2012 at 6:12 PM, Marek Vasut <marex@denx.de> wrote:
> Dear Fabio Estevam,
>
>> commit acc4959fc1 (Revert "i.MX28: Enable additional DRAM address bits")
>> broke mx28evk boot.
>>
>> Fix it by properly adjusting the HW_DRAM_CTL29 register value.
>>
>> Suggested-by: Marek Vasut <marex@denx.de>
>> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
>> ---
>> ?board/freescale/mx28evk/iomux.c | ? 14 ++++++++++++++
>> ?1 files changed, 14 insertions(+), 0 deletions(-)
>>
>> diff --git a/board/freescale/mx28evk/iomux.c
>
> Uh, why isn't this file called splboot.c?
>
> But
> Acked-by: Marek Vasut <marex@denx.de>

Could this one be applied?

mx28evk does not boot without this patch.

Thanks,

Fabio Estevam

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register
  2012-06-19 17:24 [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register Fabio Estevam
  2012-06-19 21:12 ` Marek Vasut
@ 2012-07-02 17:51 ` Stefano Babic
  1 sibling, 0 replies; 4+ messages in thread
From: Stefano Babic @ 2012-07-02 17:51 UTC (permalink / raw)
  To: u-boot

On 19/06/2012 19:24, Fabio Estevam wrote:
> commit acc4959fc1 (Revert "i.MX28: Enable additional DRAM address bits")
> broke mx28evk boot.
> 
> Fix it by properly adjusting the HW_DRAM_CTL29 register value.
> 
> Suggested-by: Marek Vasut <marex@denx.de>
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---


Applied to u-boot-imx, thanks.

Best regards,
Stefano Babic



-- 
=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-07-02 17:51 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-19 17:24 [U-Boot] [PATCH] mx28evk: Fix boot by adjusting HW_DRAM_CTL29 register Fabio Estevam
2012-06-19 21:12 ` Marek Vasut
2012-06-27 13:17   ` Fabio Estevam
2012-07-02 17:51 ` Stefano Babic

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox