public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] RR v2 PATCH: SMDK6400 Fix some build bug
@ 2011-01-11 14:52 seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 1/4] SMDK6400: Fix CONFIG_SYS_INIT_SP_ADDR undefined seedshope
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: seedshope @ 2011-01-11 14:52 UTC (permalink / raw)
  To: u-boot

Subject: RR v2 PATCH: SMDK6400 Fix some build bug
Change from V1:
patch 1: 
patch 2: Delete some compile information from commit.
patch 3: Add LED modify information and Delete some compile information from commit.
patch 4: Add new patch for SDRAM init.

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

* [U-Boot] [V2 patch 1/4] SMDK6400: Fix CONFIG_SYS_INIT_SP_ADDR undefined
  2011-01-11 14:52 [U-Boot] RR v2 PATCH: SMDK6400 Fix some build bug seedshope
@ 2011-01-11 14:52 ` seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 2/4] SMDK6400: Fix some label undefined in build error seedshope
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 11+ messages in thread
From: seedshope @ 2011-01-11 14:52 UTC (permalink / raw)
  To: u-boot

Fix CONFIG_SYS_INIT_SP_ADDR undefined issue.

Signed-off-by: seedshope <bocui107@gmail.com>

diff --git a/include/configs/smdk6400.h b/include/configs/smdk6400.h
index 671f2c7..c9acf58 100644
--- a/include/configs/smdk6400.h
+++ b/include/configs/smdk6400.h
@@ -44,6 +44,11 @@
 #define CONFIG_PERIPORT_BASE	0x70000000
 #define CONFIG_PERIPORT_SIZE	0x13
 
+#define CONFIG_SYS_IRAM_BASE    0x0c000000  /* Internal SRAM base address */
+#define CONFIG_SYS_IRAM_SIZE    0x2000      /* 8 KB of internal SRAM memory */
+#define CONFIG_SYS_IRAM_END     (CONFIG_SYS_IRAM_BASE + CONFIG_SYS_IRAM_SIZE)
+#define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_IRAM_END - GENERATED_GBL_DATA_SIZE)
+
 #define CONFIG_SYS_SDRAM_BASE	0x50000000
 
 /* input clock of PLL: SMDK6400 has 12MHz input clock */
-- 
1.7.1

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

* [U-Boot] [V2 patch 2/4] SMDK6400: Fix some label undefined in build error
  2011-01-11 14:52 [U-Boot] RR v2 PATCH: SMDK6400 Fix some build bug seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 1/4] SMDK6400: Fix CONFIG_SYS_INIT_SP_ADDR undefined seedshope
@ 2011-01-11 14:52 ` seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init seedshope
  3 siblings, 0 replies; 11+ messages in thread
From: seedshope @ 2011-01-11 14:52 UTC (permalink / raw)
  To: u-boot

Start.s use some label,this defined u-boot.lds of arch/arm/cpu/arm1176.
But SMDK6400 use the link script board/samsung/smdk6400/u-boot-nand.lds.
So add some label form u-boot.lds to u-boot-nand.lds

Signed-off-by: seedshope <bocui107@gmail.com>

diff --git a/board/samsung/smdk6400/u-boot-nand.lds b/board/samsung/smdk6400/u-boot-nand.lds
index 29a4f61..2b87fc6 100644
--- a/board/samsung/smdk6400/u-boot-nand.lds
+++ b/board/samsung/smdk6400/u-boot-nand.lds
@@ -55,8 +55,29 @@ SECTIONS
 	. = ALIGN(4);
 	.mmudata : { *(.mmudata) }
 
-	. = ALIGN(4);
-	__bss_start = .;
-	.bss : { *(.bss) . = ALIGN(4); }
-	_end = .;
+        . = ALIGN(4);
+
+	.rel.dyn : {
+		__rel_dyn_start = .;
+		*(.rel*)
+		__rel_dyn_end = .;
+	}
+
+	.dynsym : {
+		__dynsym_start = .;
+		*(.dynsym)
+	}
+
+	.bss __rel_dyn_start (OVERLAY) : {
+		__bss_start = .;
+		*(.bss)
+		. = ALIGN(4);
+		_end = .;
+	}
+
+	/DISCARD/ : { *(.dynstr*) }
+	/DISCARD/ : { *(.dynamic*) }
+	/DISCARD/ : { *(.plt*) }
+	/DISCARD/ : { *(.interp*) }
+	/DISCARD/ : { *(.gnu*) }
 }
-- 
1.7.1

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

* [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support
  2011-01-11 14:52 [U-Boot] RR v2 PATCH: SMDK6400 Fix some build bug seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 1/4] SMDK6400: Fix CONFIG_SYS_INIT_SP_ADDR undefined seedshope
  2011-01-11 14:52 ` [U-Boot] [V2 patch 2/4] SMDK6400: Fix some label undefined in build error seedshope
@ 2011-01-11 14:52 ` seedshope
  2011-01-18 21:56   ` Wolfgang Denk
  2011-01-11 14:52 ` [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init seedshope
  3 siblings, 1 reply; 11+ messages in thread
From: seedshope @ 2011-01-11 14:52 UTC (permalink / raw)
  To: u-boot

Add some relocation symbols to u-boot.lds and disable LED functions
in start.s to support nand_spl.

Signed-off-by: seedshope <bocui107@gmail.com>

diff --git a/arch/arm/cpu/arm1176/start.S b/arch/arm/cpu/arm1176/start.S
index 237dcfe..ae3706a 100644
--- a/arch/arm/cpu/arm1176/start.S
+++ b/arch/arm/cpu/arm1176/start.S
@@ -354,9 +354,11 @@ clbss_l:str	r2, [r0]		/* clear loop...		    */
 	cmp	r0, r1
 	bne	clbss_l
 
+#ifndef CONFIG_NAND_SPL
 	bl coloured_LED_init
 	bl red_LED_on
 #endif
+#endif
 
 /*
  * We are done. Do not return, instead branch to second part of board
diff --git a/nand_spl/board/samsung/smdk6400/u-boot.lds b/nand_spl/board/samsung/smdk6400/u-boot.lds
index 3ac6aa1..30b1573 100644
--- a/nand_spl/board/samsung/smdk6400/u-boot.lds
+++ b/nand_spl/board/samsung/smdk6400/u-boot.lds
@@ -55,7 +55,22 @@ SECTIONS
 	__u_boot_cmd_end = .;
 
 	. = ALIGN(4);
+
+	.rel.dyn : {
+	__rel_dyn_start = .;
+	*(.rel*)
+	__rel_dyn_end = .;
+	}
+
+	.dynsym : {
+	__dynsym_start = .;
+	*(.dynsym)
+	}
+
+	.bss __rel_dyn_start (OVERLAY) : {
 	__bss_start = .;
-	.bss : { *(.bss) . = ALIGN(4); }
+	*(.bss)
+	. = ALIGN(4);
 	_end = .;
+	}
 }
-- 
1.7.1

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

* [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init
  2011-01-11 14:52 [U-Boot] RR v2 PATCH: SMDK6400 Fix some build bug seedshope
                   ` (2 preceding siblings ...)
  2011-01-11 14:52 ` [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support seedshope
@ 2011-01-11 14:52 ` seedshope
  2011-01-12 11:08   ` Sergei Shtylyov
  3 siblings, 1 reply; 11+ messages in thread
From: seedshope @ 2011-01-11 14:52 UTC (permalink / raw)
  To: u-boot

Since SDRAM init function have already change, So the SDRAM
initial function must be change.

Signed-off-by: seedshope <bocui107@gmail.com>

diff --git a/board/samsung/smdk6400/smdk6400.c b/board/samsung/smdk6400/smdk6400.c
index 35aa40b..52b44a8 100644
--- a/board/samsung/smdk6400/smdk6400.c
+++ b/board/samsung/smdk6400/smdk6400.c
@@ -78,10 +78,18 @@ int board_init(void)
 	return 0;
 }
 
-int dram_init(void)
+void dram_init_banksize(void)
 {
+	DECLARE_GLOBAL_DATA_PTR;
+
 	gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
 	gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE;
+}
+
+int dram_init(void)
+{
+	gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
+	CONFIG_MAX_RAM_BANK_SIZE);
 
 	return 0;
 }
-- 
1.7.1

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

* [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init
  2011-01-11 14:52 ` [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init seedshope
@ 2011-01-12 11:08   ` Sergei Shtylyov
  2011-01-12 14:52     ` seedshope
  0 siblings, 1 reply; 11+ messages in thread
From: Sergei Shtylyov @ 2011-01-12 11:08 UTC (permalink / raw)
  To: u-boot

Hello.

On 11-01-2011 17:52, seedshope wrote:

> Since SDRAM init function have already change, So the SDRAM
> initial function must be change.

> Signed-off-by: seedshope<bocui107@gmail.com>

> diff --git a/board/samsung/smdk6400/smdk6400.c b/board/samsung/smdk6400/smdk6400.c
> index 35aa40b..52b44a8 100644
> --- a/board/samsung/smdk6400/smdk6400.c
> +++ b/board/samsung/smdk6400/smdk6400.c
> @@ -78,10 +78,18 @@ int board_init(void)
>   	return 0;
>   }
>
> -int dram_init(void)
> +void dram_init_banksize(void)
>   {
> +	DECLARE_GLOBAL_DATA_PTR;
> +
>   	gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
>   	gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE;
> +}
> +
> +int dram_init(void)
> +{
> +	gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
> +	CONFIG_MAX_RAM_BANK_SIZE);

    Please indent that line more to the right, preferrebly start it under 
'(volatile long *)'.

WBR, Sergei

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

* [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init
  2011-01-12 11:08   ` Sergei Shtylyov
@ 2011-01-12 14:52     ` seedshope
  2011-01-12 16:35       ` Wolfgang Denk
  2011-01-13 11:04       ` Sergei Shtylyov
  0 siblings, 2 replies; 11+ messages in thread
From: seedshope @ 2011-01-12 14:52 UTC (permalink / raw)
  To: u-boot

On 01/12/2011 07:08 PM, Sergei Shtylyov wrote:
> Hello.
>
> On 11-01-2011 17:52, seedshope wrote:
>
>> Since SDRAM init function have already change, So the SDRAM
>> initial function must be change.
>
>> Signed-off-by: seedshope<bocui107@gmail.com>
>
>> diff --git a/board/samsung/smdk6400/smdk6400.c 
>> b/board/samsung/smdk6400/smdk6400.c
>> index 35aa40b..52b44a8 100644
>> --- a/board/samsung/smdk6400/smdk6400.c
>> +++ b/board/samsung/smdk6400/smdk6400.c
>> @@ -78,10 +78,18 @@ int board_init(void)
>> return 0;
>> }
>>
>> -int dram_init(void)
>> +void dram_init_banksize(void)
>> {
>> + DECLARE_GLOBAL_DATA_PTR;
>> +
>> gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
>> gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE;
>> +}
>> +
>> +int dram_init(void)
>> +{
>> + gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
>> + CONFIG_MAX_RAM_BANK_SIZE);
>
> Please indent that line more to the right, preferrebly start it under 
> '(volatile long *)'.
ok, But I don't know how number tab indent is appropriate. May be the 
effect as following?
gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
CONFIG_MAX_RAM_BANK_SIZE);

Thanks?
seedshope

>
> WBR, Sergei

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

* [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init
  2011-01-12 14:52     ` seedshope
@ 2011-01-12 16:35       ` Wolfgang Denk
  2011-01-13 11:04       ` Sergei Shtylyov
  1 sibling, 0 replies; 11+ messages in thread
From: Wolfgang Denk @ 2011-01-12 16:35 UTC (permalink / raw)
  To: u-boot

Dear seedshope,

In message <4D2DC040.7040303@gmail.com> you wrote:
> 
> ok, But I don't know how number tab indent is appropriate. May be the
> effect as following?

You should start reading http://www.denx.de/wiki/U-Boot/CodingStyle
(and follow the links shown there).

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"Oh dear, I think you'll find reality's on the blink again."
- Marvin The Paranoid Android

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

* [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init
  2011-01-12 14:52     ` seedshope
  2011-01-12 16:35       ` Wolfgang Denk
@ 2011-01-13 11:04       ` Sergei Shtylyov
  1 sibling, 0 replies; 11+ messages in thread
From: Sergei Shtylyov @ 2011-01-13 11:04 UTC (permalink / raw)
  To: u-boot

Hello.

On 12-01-2011 17:52, seedshope wrote:

>>> Since SDRAM init function have already change, So the SDRAM
>>> initial function must be change.

>>> Signed-off-by: seedshope<bocui107@gmail.com>

>>> diff --git a/board/samsung/smdk6400/smdk6400.c
>>> b/board/samsung/smdk6400/smdk6400.c
>>> index 35aa40b..52b44a8 100644
>>> --- a/board/samsung/smdk6400/smdk6400.c
>>> +++ b/board/samsung/smdk6400/smdk6400.c
>>> @@ -78,10 +78,18 @@ int board_init(void)
>>> return 0;
>>> }
>>>
>>> -int dram_init(void)
>>> +void dram_init_banksize(void)
>>> {
>>> + DECLARE_GLOBAL_DATA_PTR;
>>> +
>>> gd->bd->bi_dram[0].start = PHYS_SDRAM_1;
>>> gd->bd->bi_dram[0].size = PHYS_SDRAM_1_SIZE;
>>> +}
>>> +
>>> +int dram_init(void)
>>> +{
>>> + gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
>>> + CONFIG_MAX_RAM_BANK_SIZE);

>> Please indent that line more to the right, preferrebly start it under
>> '(volatile long *)'.

> ok, But I don't know how number tab indent is appropriate. May be the effect
> as following?
> gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
> CONFIG_MAX_RAM_BANK_SIZE);

    I've asked you specifically to do this:

	gd->ram_size = get_ram_size((volatile long *)CONFIG_SYS_SDRAM_BASE,
				    CONFIG_MAX_RAM_BANK_SIZE);

> Thanks?
> seedshope

WBR, Sergei

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

* [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support
  2011-01-11 14:52 ` [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support seedshope
@ 2011-01-18 21:56   ` Wolfgang Denk
  2011-01-19 14:08     ` seedshope
  0 siblings, 1 reply; 11+ messages in thread
From: Wolfgang Denk @ 2011-01-18 21:56 UTC (permalink / raw)
  To: u-boot

Dear seedshope,

In message <1294757545-4771-4-git-send-email-bocui107@gmail.com> you wrote:
> Add some relocation symbols to u-boot.lds and disable LED functions
> in start.s to support nand_spl.
> 
> Signed-off-by: seedshope <bocui107@gmail.com>

Please re-split yourpatches.  The changes to
board/samsung/smdk6400/u-boot.lds and
board/samsung/smdk6400/u-boot-nand.lds should probably go into a
single commit.

Also please chose a more descriptive Subject / commit message.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
The use of anthropomorphic terminology when  dealing  with  computing
systems is a symptom of professional immaturity.   -- Edsger Dijkstra

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

* [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support
  2011-01-18 21:56   ` Wolfgang Denk
@ 2011-01-19 14:08     ` seedshope
  0 siblings, 0 replies; 11+ messages in thread
From: seedshope @ 2011-01-19 14:08 UTC (permalink / raw)
  To: u-boot

On 01/19/2011 05:56 AM, Wolfgang Denk wrote:
> Dear seedshope,
>
> In message<1294757545-4771-4-git-send-email-bocui107@gmail.com>  you wrote:
>> Add some relocation symbols to u-boot.lds and disable LED functions
>> in start.s to support nand_spl.
>>
>> Signed-off-by: seedshope<bocui107@gmail.com>
> Please re-split yourpatches.  The changes to
> board/samsung/smdk6400/u-boot.lds and
> board/samsung/smdk6400/u-boot-nand.lds should probably go into a
> single commit.
>
> Also please chose a more descriptive Subject / commit message.
>
oK,

Now, I wait to resolve a issue for RR4.
In RR3 patch2, I fine the cmd_link_o_target command will link for 
cpu_init.o.
So Delay some time.

Thanks,
hongbo
> Best regards,
>
> Wolfgang Denk
>

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

end of thread, other threads:[~2011-01-19 14:08 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-11 14:52 [U-Boot] RR v2 PATCH: SMDK6400 Fix some build bug seedshope
2011-01-11 14:52 ` [U-Boot] [V2 patch 1/4] SMDK6400: Fix CONFIG_SYS_INIT_SP_ADDR undefined seedshope
2011-01-11 14:52 ` [U-Boot] [V2 patch 2/4] SMDK6400: Fix some label undefined in build error seedshope
2011-01-11 14:52 ` [U-Boot] [V2 patch 3/4] SMDK6400: Fix build error for nand_spl support seedshope
2011-01-18 21:56   ` Wolfgang Denk
2011-01-19 14:08     ` seedshope
2011-01-11 14:52 ` [U-Boot] [V2 patch 4/4] SMDK6400: Fix SMDK6400 SDRAM init seedshope
2011-01-12 11:08   ` Sergei Shtylyov
2011-01-12 14:52     ` seedshope
2011-01-12 16:35       ` Wolfgang Denk
2011-01-13 11:04       ` Sergei Shtylyov

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