public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
@ 2015-05-27  2:22 Fabio Estevam
  2015-05-27  6:27 ` Stefano Babic
  2015-05-28  9:52 ` Stefano Babic
  0 siblings, 2 replies; 7+ messages in thread
From: Fabio Estevam @ 2015-05-27  2:22 UTC (permalink / raw)
  To: u-boot

From: Fabio Estevam <fabio.estevam@freescale.com>

Commit 8183058188cd2d942 ("imx6: centralise common boot options in
mx6_common.h") broke boot on mx6sl and mx6sx by assuming that all mx6
SoCs use the same LOADADDR/SYS_TEXT_BASE range, which is not correct.

DDR on mx6sx/mx6sl starts at 0x80000000.

Adjust LOADADDR/SYS_TEXT_BASE to the proper values for mx6sx/mx6sl,
so that these SoCs can boot again.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
---
 include/configs/mx6_common.h | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/include/configs/mx6_common.h b/include/configs/mx6_common.h
index 233c6d2..bd16ec2 100644
--- a/include/configs/mx6_common.h
+++ b/include/configs/mx6_common.h
@@ -53,10 +53,15 @@
 #define CONFIG_REVISION_TAG
 
 /* Boot options */
+#if (defined(CONFIG_MX6SX) || defined(CONFIG_MX6SL))
+#define CONFIG_LOADADDR		0x82000000
+#define CONFIG_SYS_TEXT_BASE	0x87800000
+#else
 #define CONFIG_LOADADDR		0x12000000
+#define CONFIG_SYS_TEXT_BASE	0x17800000
+#endif
 #define CONFIG_SYS_LOAD_ADDR	CONFIG_LOADADDR
 #ifndef CONFIG_SYS_TEXT_BASE
-#define CONFIG_SYS_TEXT_BASE	0x17800000
 #endif
 #ifndef CONFIG_BOOTDELAY
 #define CONFIG_BOOTDELAY	3
-- 
1.9.1

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

* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
  2015-05-27  2:22 [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX Fabio Estevam
@ 2015-05-27  6:27 ` Stefano Babic
  2015-05-28  9:52 ` Stefano Babic
  1 sibling, 0 replies; 7+ messages in thread
From: Stefano Babic @ 2015-05-27  6:27 UTC (permalink / raw)
  To: u-boot

Hi Fabio,

On 27/05/2015 04:22, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Commit 8183058188cd2d942 ("imx6: centralise common boot options in
> mx6_common.h") broke boot on mx6sl and mx6sx by assuming that all mx6
> SoCs use the same LOADADDR/SYS_TEXT_BASE range, which is not correct.
> 
> DDR on mx6sx/mx6sl starts at 0x80000000.
> 
> Adjust LOADADDR/SYS_TEXT_BASE to the proper values for mx6sx/mx6sl,
> so that these SoCs can boot again.
> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---
>  include/configs/mx6_common.h | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/include/configs/mx6_common.h b/include/configs/mx6_common.h
> index 233c6d2..bd16ec2 100644
> --- a/include/configs/mx6_common.h
> +++ b/include/configs/mx6_common.h
> @@ -53,10 +53,15 @@
>  #define CONFIG_REVISION_TAG
>  
>  /* Boot options */
> +#if (defined(CONFIG_MX6SX) || defined(CONFIG_MX6SL))
> +#define CONFIG_LOADADDR		0x82000000
> +#define CONFIG_SYS_TEXT_BASE	0x87800000
> +#else
>  #define CONFIG_LOADADDR		0x12000000
> +#define CONFIG_SYS_TEXT_BASE	0x17800000
> +#endif
>  #define CONFIG_SYS_LOAD_ADDR	CONFIG_LOADADDR
>  #ifndef CONFIG_SYS_TEXT_BASE
> -#define CONFIG_SYS_TEXT_BASE	0x17800000
>  #endif
>  #ifndef CONFIG_BOOTDELAY
>  #define CONFIG_BOOTDELAY	3
> 

Acked-by: Stefano Babic <sbabic@denx.de>

Best regards,
Stefano Babic

-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
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] 7+ messages in thread

* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
  2015-05-27  2:22 [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX Fabio Estevam
  2015-05-27  6:27 ` Stefano Babic
@ 2015-05-28  9:52 ` Stefano Babic
  2015-05-28 10:21   ` Stefano Babic
  1 sibling, 1 reply; 7+ messages in thread
From: Stefano Babic @ 2015-05-28  9:52 UTC (permalink / raw)
  To: u-boot

On 27/05/2015 04:22, Fabio Estevam wrote:
> From: Fabio Estevam <fabio.estevam@freescale.com>
> 
> Commit 8183058188cd2d942 ("imx6: centralise common boot options in
> mx6_common.h") broke boot on mx6sl and mx6sx by assuming that all mx6
> SoCs use the same LOADADDR/SYS_TEXT_BASE range, which is not correct.
> 
> DDR on mx6sx/mx6sl starts at 0x80000000.
> 
> Adjust LOADADDR/SYS_TEXT_BASE to the proper values for mx6sx/mx6sl,
> so that these SoCs can boot again.
> 
> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
> ---
>  include/configs/mx6_common.h | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/include/configs/mx6_common.h b/include/configs/mx6_common.h
> index 233c6d2..bd16ec2 100644
> --- a/include/configs/mx6_common.h
> +++ b/include/configs/mx6_common.h
> @@ -53,10 +53,15 @@
>  #define CONFIG_REVISION_TAG
>  
>  /* Boot options */
> +#if (defined(CONFIG_MX6SX) || defined(CONFIG_MX6SL))
> +#define CONFIG_LOADADDR		0x82000000
> +#define CONFIG_SYS_TEXT_BASE	0x87800000
> +#else
>  #define CONFIG_LOADADDR		0x12000000
> +#define CONFIG_SYS_TEXT_BASE	0x17800000
> +#endif
>  #define CONFIG_SYS_LOAD_ADDR	CONFIG_LOADADDR
>  #ifndef CONFIG_SYS_TEXT_BASE
> -#define CONFIG_SYS_TEXT_BASE	0x17800000
>  #endif
>  #ifndef CONFIG_BOOTDELAY
>  #define CONFIG_BOOTDELAY	3
> 

Applied to u-boot-imx, thanks !

Best regards,
Stefano Babic

-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
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] 7+ messages in thread

* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
  2015-05-28  9:52 ` Stefano Babic
@ 2015-05-28 10:21   ` Stefano Babic
  2015-05-28 11:25     ` Markus Niebel
                       ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Stefano Babic @ 2015-05-28 10:21 UTC (permalink / raw)
  To: u-boot

Hi Fabio,

On 28/05/2015 11:52, Stefano Babic wrote:
> On 27/05/2015 04:22, Fabio Estevam wrote:
>> From: Fabio Estevam <fabio.estevam@freescale.com>
>>
>> Commit 8183058188cd2d942 ("imx6: centralise common boot options in
>> mx6_common.h") broke boot on mx6sl and mx6sx by assuming that all mx6
>> SoCs use the same LOADADDR/SYS_TEXT_BASE range, which is not correct.
>>
>> DDR on mx6sx/mx6sl starts at 0x80000000.
>>
>> Adjust LOADADDR/SYS_TEXT_BASE to the proper values for mx6sx/mx6sl,
>> so that these SoCs can boot again.
>>
>> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
>> ---
>>  include/configs/mx6_common.h | 7 ++++++-
>>  1 file changed, 6 insertions(+), 1 deletion(-)
>>
>> diff --git a/include/configs/mx6_common.h b/include/configs/mx6_common.h
>> index 233c6d2..bd16ec2 100644
>> --- a/include/configs/mx6_common.h
>> +++ b/include/configs/mx6_common.h
>> @@ -53,10 +53,15 @@
>>  #define CONFIG_REVISION_TAG
>>  
>>  /* Boot options */
>> +#if (defined(CONFIG_MX6SX) || defined(CONFIG_MX6SL))
>> +#define CONFIG_LOADADDR		0x82000000
>> +#define CONFIG_SYS_TEXT_BASE	0x87800000
>> +#else
>>  #define CONFIG_LOADADDR		0x12000000
>> +#define CONFIG_SYS_TEXT_BASE	0x17800000
>> +#endif
>>  #define CONFIG_SYS_LOAD_ADDR	CONFIG_LOADADDR
>>  #ifndef CONFIG_SYS_TEXT_BASE
>> -#define CONFIG_SYS_TEXT_BASE	0x17800000
>>  #endif
>>  #ifndef CONFIG_BOOTDELAY
>>  #define CONFIG_BOOTDELAY	3
>>
> 
> Applied to u-boot-imx, thanks !
> 

Sorry, it is not. This breaks (warnings) the tqma6 board. At least we
have to undefine CONFIG_SYS_TEXT_BASE in tqma6.h because this board
redefines it. I added Markus (b oard maintainer in CC), as he can better
explain while this single board requires different CONFIG_SYS_TEXT_BASE.
From the addresses I guess he will avoid relocation.

Best regards,
Stefano Babic



-- 
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
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] 7+ messages in thread

* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
  2015-05-28 10:21   ` Stefano Babic
@ 2015-05-28 11:25     ` Markus Niebel
  2015-05-28 11:26     ` Andy Pont
       [not found]     ` <5566fb91.8a532b0a.66d7.ffffbd12SMTPIN_ADDED_BROKEN@mx.google.com>
  2 siblings, 0 replies; 7+ messages in thread
From: Markus Niebel @ 2015-05-28 11:25 UTC (permalink / raw)
  To: u-boot

Am 28.05.2015 um 12:21 schrieb Stefano Babic:
> Hi Fabio,
> 
> On 28/05/2015 11:52, Stefano Babic wrote:
>> On 27/05/2015 04:22, Fabio Estevam wrote:
>>> From: Fabio Estevam <fabio.estevam@freescale.com>
>>>
>>> Commit 8183058188cd2d942 ("imx6: centralise common boot options in
>>> mx6_common.h") broke boot on mx6sl and mx6sx by assuming that all mx6
>>> SoCs use the same LOADADDR/SYS_TEXT_BASE range, which is not correct.
>>>
>>> DDR on mx6sx/mx6sl starts at 0x80000000.
>>>
>>> Adjust LOADADDR/SYS_TEXT_BASE to the proper values for mx6sx/mx6sl,
>>> so that these SoCs can boot again.
>>>
>>> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
>>> ---
>>>  include/configs/mx6_common.h | 7 ++++++-
>>>  1 file changed, 6 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/include/configs/mx6_common.h b/include/configs/mx6_common.h
>>> index 233c6d2..bd16ec2 100644
>>> --- a/include/configs/mx6_common.h
>>> +++ b/include/configs/mx6_common.h
>>> @@ -53,10 +53,15 @@
>>>  #define CONFIG_REVISION_TAG
>>>  
>>>  /* Boot options */
>>> +#if (defined(CONFIG_MX6SX) || defined(CONFIG_MX6SL))
>>> +#define CONFIG_LOADADDR		0x82000000
>>> +#define CONFIG_SYS_TEXT_BASE	0x87800000
>>> +#else
>>>  #define CONFIG_LOADADDR		0x12000000
>>> +#define CONFIG_SYS_TEXT_BASE	0x17800000
>>> +#endif
>>>  #define CONFIG_SYS_LOAD_ADDR	CONFIG_LOADADDR
>>>  #ifndef CONFIG_SYS_TEXT_BASE
>>> -#define CONFIG_SYS_TEXT_BASE	0x17800000
>>>  #endif
>>>  #ifndef CONFIG_BOOTDELAY
>>>  #define CONFIG_BOOTDELAY	3
>>>
>>
>> Applied to u-boot-imx, thanks !
>>
> 
> Sorry, it is not. This breaks (warnings) the tqma6 board. At least we
> have to undefine CONFIG_SYS_TEXT_BASE in tqma6.h because this board
> redefines it. I added Markus (b oard maintainer in CC), as he can better
> explain while this single board requires different CONFIG_SYS_TEXT_BASE.
> From the addresses I guess he will avoid relocation.
> 

We do it to have the U-Boot at the end of RAM - some projects using the TQMa6
requires that we have most of RAM available - for instance during system updates.

Markus

> Best regards,
> Stefano Babic
> 
> 
> 

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

* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
  2015-05-28 10:21   ` Stefano Babic
  2015-05-28 11:25     ` Markus Niebel
@ 2015-05-28 11:26     ` Andy Pont
       [not found]     ` <5566fb91.8a532b0a.66d7.ffffbd12SMTPIN_ADDED_BROKEN@mx.google.com>
  2 siblings, 0 replies; 7+ messages in thread
From: Andy Pont @ 2015-05-28 11:26 UTC (permalink / raw)
  To: u-boot

Hello,

[snip]

> >>  #ifndef CONFIG_SYS_TEXT_BASE
> >> -#define CONFIG_SYS_TEXT_BASE	0x17800000
> >>  #endif

Doesn't this also leave an empty, and therefore meaningless #ifndef...#endif
that could be removed completely?

Regards,

Andy.

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

* [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX
       [not found]     ` <5566fb91.8a532b0a.66d7.ffffbd12SMTPIN_ADDED_BROKEN@mx.google.com>
@ 2015-05-28 14:15       ` Fabio Estevam
  0 siblings, 0 replies; 7+ messages in thread
From: Fabio Estevam @ 2015-05-28 14:15 UTC (permalink / raw)
  To: u-boot

Hi Andy,

On Thu, May 28, 2015 at 8:26 AM, Andy Pont <andy.pont@sdcsystems.com> wrote:

> Doesn't this also leave an empty, and therefore meaningless #ifndef...#endif
> that could be removed completely?

Good catch, thanks.

I sent a v2 that addresses this problem and also the build warning on tqma6.

I am not able to boot test it on real hardware at the moment though.

Regards,

Fabio Estevam

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

end of thread, other threads:[~2015-05-28 14:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-27  2:22 [U-Boot] [PATCH] mx6_common: Fix LOADADDR and SYS_TEXT_BASE for MX6SL and MX6SX Fabio Estevam
2015-05-27  6:27 ` Stefano Babic
2015-05-28  9:52 ` Stefano Babic
2015-05-28 10:21   ` Stefano Babic
2015-05-28 11:25     ` Markus Niebel
2015-05-28 11:26     ` Andy Pont
     [not found]     ` <5566fb91.8a532b0a.66d7.ffffbd12SMTPIN_ADDED_BROKEN@mx.google.com>
2015-05-28 14:15       ` Fabio Estevam

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