change log for rtems (2011-07-28)

rtems-vc at rtems.org rtems-vc at rtems.org
Thu Jul 28 20:10:27 UTC 2011


 *strauman*:
2011-27-28	Till Straumann <strauman at slac.stanford.edu>

	* start/start.S: fixed indentation. Tag TOS with a NULL
	pointer (help terminate when walking the stack).

M  1.157  c/src/lib/libbsp/powerpc/gen5200/ChangeLog
M   1.17  c/src/lib/libbsp/powerpc/gen5200/start/start.S

diff -u rtems/c/src/lib/libbsp/powerpc/gen5200/ChangeLog:1.156 rtems/c/src/lib/libbsp/powerpc/gen5200/ChangeLog:1.157
--- rtems/c/src/lib/libbsp/powerpc/gen5200/ChangeLog:1.156	Fri Jun 17 06:58:41 2011
+++ rtems/c/src/lib/libbsp/powerpc/gen5200/ChangeLog	Thu Jul 28 14:20:09 2011
@@ -1,3 +1,8 @@
+2011-27-28	Till Straumann <strauman at slac.stanford.edu>
+
+	* start/start.S: fixed indentation. Tag TOS with a NULL
+	pointer (help terminate when walking the stack).
+
 2011-06-17	Sebastian Huber <sebastian.huber at embedded-brains.de>
 
 	* Makefile.am: Added custom memcpy().  Update for network sources.

diff -u rtems/c/src/lib/libbsp/powerpc/gen5200/start/start.S:1.16 rtems/c/src/lib/libbsp/powerpc/gen5200/start/start.S:1.17
--- rtems/c/src/lib/libbsp/powerpc/gen5200/start/start.S:1.16	Fri Jun 17 06:58:41 2011
+++ rtems/c/src/lib/libbsp/powerpc/gen5200/start/start.S	Thu Jul 28 14:20:09 2011
@@ -222,7 +222,7 @@
 PUBLIC_VAR (start)
 start:
 /* 1st: initialization work (common for RAM/ROM startup) */
-        mfmsr	r30
+	mfmsr	r30
 	SETBITS r30, r29, MSR_ME|MSR_RI
 	CLRBITS r30, r29, MSR_EE
 	mtmsr	r30 				/* Set RI/ME, Clr EE in MSR */
@@ -442,19 +442,19 @@
 /* clear entire on chip SRAM (unique for ROM startup) */
 	lis	r30, (MBAR+ONCHIP_SRAM_OFFSET)@h	/* get start address of onchip SRAM */
 	ori	r30, r30,(MBAR+ONCHIP_SRAM_OFFSET)@l
-        LWI	r29, ONCHIP_SRAM_SIZE		/* get size of onchip SRAM */
+	LWI	r29, ONCHIP_SRAM_SIZE		/* get size of onchip SRAM */
 
-        bl      clr_mem				/* Clear onchip SRAM */
+	bl      clr_mem				/* Clear onchip SRAM */
 
 #else /* defined(NEED_LOW_LEVEL_INIT) */
 	bl	XLB_init
 #endif /* defined(NEED_LOW_LEVEL_INIT) */
 /* clear .bss section (unique for ROM startup) */
 	LWI	r30, bsp_section_bss_start	/* get start address of bss section */
-        LWI	r29, bsp_section_bss_size  	/* get size of bss section */
+	LWI	r29, bsp_section_bss_size  	/* get size of bss section */
 
 
-        bl      clr_mem				/* Clear the bss section */
+	bl      clr_mem				/* Clear the bss section */
 
 #ifdef HAS_UBOOT
 	mr	r3, r14
@@ -463,7 +463,10 @@
 
 /* set stack pointer (common for RAM/ROM startup) */
 	LA	r1, bsp_section_text_start
-        addi    r1, r1, -0x10			/* Set up stack pointer = beginning of text section - 0x10 */
+	addi    r1, r1, -0x10			/* Set up stack pointer = beginning of text section - 0x10 */
+	/* tag TOS with a NULL pointer (termination mark for stack dump) */
+	li  r0, 0
+	stw r0, 0(r1)
 
 	bl	__eabi				/* Set up EABI and SYSV environment */
 
@@ -475,10 +478,10 @@
 
 /* clear arguments and do further init. in C (common for RAM/ROM startup) */
 
-        /* Clear cmdline */
-        xor r3, r3, r3
+	/* Clear cmdline */
+	xor r3, r3, r3
 
-        bl      SYM (boot_card)			/* Call the first C routine */
+	bl      SYM (boot_card)			/* Call the first C routine */
 
 twiddle:
 	b	twiddle				/* We don't expect to return from boot_card but if we do */
@@ -507,7 +510,7 @@
 	or	r29,r29,r30			/* set bit 0 in r29/GPIOWDD */
 	stw	r29,GPIOWDD(r31)
 
-      /* activate MEM_CS1 output */
+	/* activate MEM_CS1 output */
 	lwz	r29, GPIOPCR(r31)
 	or	r29,r29,r30			/* set bit 0 in r29/GPIOPCR */
 	stw	r29,GPIOPCR(r31)
@@ -625,20 +628,20 @@
 FID_DCache:
 	mflr	r26
 
-        bl      PPC_HID0_rd
-        TSTBITS	r30, r29, HID0_DCE
-        bne     FID_DCache_exit			/* If data cache is switched of, skip further actions */
+	bl      PPC_HID0_rd
+	TSTBITS	r30, r29, HID0_DCE
+	bne     FID_DCache_exit			/* If data cache is switched of, skip further actions */
 
 	li   	r29, PPC_D_CACHE		/* 16 Kb data cache on 603e */
 	LWI	r28, bsp_section_text_start	/* Load base address (begin of RAM) */
 
 FID_DCache_loop_1:
-        lwz     r27, 0(r28)			/* Load data at address */
+	lwz     r27, 0(r28)			/* Load data at address */
 
-        addi    r28, r28, PPC_CACHE_ALIGNMENT 	/* increment cache line address */
-        subi    r29, r29, PPC_CACHE_ALIGNMENT 	/* increment loop counter */
-        cmpwi	r29, 0x0
-        bne     FID_DCache_loop_1		/* Loop until cache size is reached */
+	addi    r28, r28, PPC_CACHE_ALIGNMENT 	/* increment cache line address */
+	subi    r29, r29, PPC_CACHE_ALIGNMENT 	/* increment loop counter */
+	cmpwi	r29, 0x0
+	bne     FID_DCache_loop_1		/* Loop until cache size is reached */
 
 	li   	r29, PPC_D_CACHE		/* 16 Kb data cache on 603e */
 	LWI	r28, bsp_section_text_start	/* Reload base address (begin of RAM) */
@@ -647,14 +650,14 @@
 
 	dcbf    r27, r28                	/* Flush and invalidate cache */
 
-        addi    r28, r28, PPC_CACHE_ALIGNMENT 	/* increment cache line address */
+	addi    r28, r28, PPC_CACHE_ALIGNMENT 	/* increment cache line address */
 	subi    r29, r29, PPC_CACHE_ALIGNMENT 	/* increment loop counter */
 	cmpwi	r29, 0x0
-        bne     FID_DCache_loop_2		/* Loop around until cache size is reached */
+	bne     FID_DCache_loop_2		/* Loop around until cache size is reached */
 
-        bl      PPC_HID0_rd			/* Read HID0 */
-       	CLRBITS	r30, r29, HID0_DCE
-        bl      PPC_HID0_wr			/* Clear DCE */
+	bl      PPC_HID0_rd			/* Read HID0 */
+	CLRBITS	r30, r29, HID0_DCE
+	bl      PPC_HID0_wr			/* Clear DCE */
 
 FID_DCache_exit:
 	mtlr	r26
@@ -663,21 +666,21 @@
 IDUL_ICache:
 	mflr 	r26
 
-        bl      PPC_HID0_rd
-        TSTBITS	r30, r29, HID0_ICE
-        bne     IDUL_ICache_exit		/* If instruction cache is switched of, skip further actions */
+	bl      PPC_HID0_rd
+	TSTBITS	r30, r29, HID0_ICE
+	bne     IDUL_ICache_exit		/* If instruction cache is switched of, skip further actions */
 
 	CLRBITS r30, r29, HID0_ICE
-        bl      PPC_HID0_wr 			/* Disable ICE bit */
+	bl      PPC_HID0_wr 			/* Disable ICE bit */
 
 	SETBITS r30, r29, HID0_ICFI
-        bl	PPC_HID0_wr			/* Invalidate instruction cache */
+	bl	PPC_HID0_wr			/* Invalidate instruction cache */
 
-        CLRBITS r30, r29, HID0_ICFI
-        bl	PPC_HID0_wr			/* Disable cache invalidate */
+	CLRBITS r30, r29, HID0_ICFI
+	bl	PPC_HID0_wr			/* Disable cache invalidate */
 
-        CLRBITS r30, r29, HID0_ILOCK
-        bl      PPC_HID0_wr			/* Disable instruction cache lock */
+	CLRBITS r30, r29, HID0_ILOCK
+	bl      PPC_HID0_wr			/* Disable instruction cache lock */
 
 IDUL_ICache_exit:
 	mtlr	r26
@@ -854,47 +857,47 @@
 PPC_HID0_rd:					/* get HID0 content to r30 */
 
 
-        mfspr   r30, HID0
+	mfspr   r30, HID0
 
-        blr
+	blr
 
 
 PPC_HID0_wr:					/* put r30 content to HID0 */
 
 
-        mtspr   HID0, r30
+	mtspr   HID0, r30
 
-        blr
+	blr
 
 clr_mem:
 	mr 	r28, r29
 	srwi	r29, r29, 2
-        mtctr   r29				/* set ctr reg */
+	mtctr   r29				/* set ctr reg */
 
 
-        slwi	r29, r29, 2
-        sub     r28, r28, r29			/* maybe some residual bytes */
-        xor     r29, r29, r29
+	slwi	r29, r29, 2
+	sub     r28, r28, r29			/* maybe some residual bytes */
+	xor     r29, r29, r29
 
 
 clr_mem_word:
-        stswi   r29, r30, 0x04			/* store r29 (word) to r30 memory location */
-        addi    r30, r30, 0x04			/* increment r30 */
+	stswi   r29, r30, 0x04			/* store r29 (word) to r30 memory location */
+	addi    r30, r30, 0x04			/* increment r30 */
 
-        bdnz    clr_mem_word			/* dec counter and loop */
+	bdnz    clr_mem_word			/* dec counter and loop */
 
 
 	cmpwi	r28, 0x00			/* clear mem. finished ? */
 	beq	clr_mem_end;
-        mtctr   r28				/* reload counter for residual bytes */
+	mtctr   r28				/* reload counter for residual bytes */
 clr_mem_byte:
 	stswi   r29, r30, 0x01			/* store r29 (byte) to r30 memory location  */
 	addi    r30, r30, 0x01			/* update r30 */
 
-        bdnz    clr_mem_byte			/* dec counter and loop */
+	bdnz    clr_mem_byte			/* dec counter and loop */
 
 clr_mem_end:
-        blr					/* return */
+	blr					/* return */
 
 XLB_init:
 /* init arbiter and stuff... */


 *strauman*:
2011-27-28	Till Straumann <strauman at slac.stanford.edu>

	* start/start.S: Tag TOS with a NULL pointer
	(help terminate when walking the stack).

M   1.58  c/src/lib/libbsp/powerpc/mvme3100/ChangeLog
M    1.8  c/src/lib/libbsp/powerpc/mvme3100/start/start.S
M  1.133  c/src/lib/libbsp/powerpc/mvme5500/ChangeLog
M   1.11  c/src/lib/libbsp/powerpc/mvme5500/start/start.S

diff -u rtems/c/src/lib/libbsp/powerpc/mvme3100/ChangeLog:1.57 rtems/c/src/lib/libbsp/powerpc/mvme3100/ChangeLog:1.58
--- rtems/c/src/lib/libbsp/powerpc/mvme3100/ChangeLog:1.57	Sat Jun 11 12:27:05 2011
+++ rtems/c/src/lib/libbsp/powerpc/mvme3100/ChangeLog	Thu Jul 28 14:27:58 2011
@@ -1,3 +1,8 @@
+2011-27-28	Till Straumann <strauman at slac.stanford.edu>
+
+	* start/start.S: Tag TOS with a NULL pointer
+	(help terminate when walking the stack).
+
 2011-06-11	Joel Sherrill <joel.sherrill at oarcorp.com>
 
 	* Makefile.am: Remove reference to wrapup directory.

diff -u rtems/c/src/lib/libbsp/powerpc/mvme3100/start/start.S:1.7 rtems/c/src/lib/libbsp/powerpc/mvme3100/start/start.S:1.8
--- rtems/c/src/lib/libbsp/powerpc/mvme3100/start/start.S:1.7	Fri Jan 28 14:29:51 2011
+++ rtems/c/src/lib/libbsp/powerpc/mvme3100/start/start.S	Thu Jul 28 14:27:58 2011
@@ -78,6 +78,11 @@
 	/* align down to 16-bytes */
 	li  r5, (CPU_STACK_ALIGNMENT - 1)
 	andc r1, r9, r5
+
+	/* NULL ptr to back chain */
+	li  r0, 0
+	stw r0, 0(r1)
+
 	/*
 	 * We are now in a environment that is totally independent from
 	 * bootloader setup.

diff -u rtems/c/src/lib/libbsp/powerpc/mvme5500/ChangeLog:1.132 rtems/c/src/lib/libbsp/powerpc/mvme5500/ChangeLog:1.133
--- rtems/c/src/lib/libbsp/powerpc/mvme5500/ChangeLog:1.132	Wed Jul 13 13:35:22 2011
+++ rtems/c/src/lib/libbsp/powerpc/mvme5500/ChangeLog	Thu Jul 28 14:25:52 2011
@@ -1,3 +1,8 @@
+2011-27-28	Till Straumann <strauman at slac.stanford.edu>
+
+	* start/start.S: Tag TOS with a NULL pointer
+	(help terminate when walking the stack).
+
 2011-07-13	Joel Sherrill <joel.sherrilL at OARcorp.com>
 
 	PR 1824/cpukit

diff -u rtems/c/src/lib/libbsp/powerpc/mvme5500/start/start.S:1.10 rtems/c/src/lib/libbsp/powerpc/mvme5500/start/start.S:1.11
--- rtems/c/src/lib/libbsp/powerpc/mvme5500/start/start.S:1.10	Fri Jun 17 08:24:47 2011
+++ rtems/c/src/lib/libbsp/powerpc/mvme5500/start/start.S	Thu Jul 28 14:25:52 2011
@@ -10,11 +10,7 @@
  *  found in the file LICENSE in this distribution or at
  *  http://www.rtems.com/license/LICENSE.
  *
-<<<<<<< start.S
  *  $Id$
-=======
- *  $Id$
->>>>>>> 1.25
  *
  */
 
@@ -152,6 +148,12 @@
 	li   r0, (CPU_STACK_ALIGNMENT-1)
 	andc r1, r9, r0
 	/*
+	 * NULL ptr to back chain
+	 */
+	li   r0, 0
+	stw  r0, 0(r1)
+
+	/*
 	 * We are now in a environment that is totally independent from
 	 * bootloader setup.
 	 */


 *strauman*:
2011-27-28	Till Straumann <strauman at slac.stanford.edu>

	* start/start.S: Align stack and tag TOS with a NULL
	pointer (help terminate when walking the stack).

M   1.21  c/src/lib/libbsp/powerpc/qemuppc/ChangeLog
M    1.4  c/src/lib/libbsp/powerpc/qemuppc/start/start.S

diff -u rtems/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog:1.20 rtems/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog:1.21
--- rtems/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog:1.20	Sat Jun 18 02:25:25 2011
+++ rtems/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog	Thu Jul 28 14:50:28 2011
@@ -1,3 +1,8 @@
+2011-27-28	Till Straumann <strauman at slac.stanford.edu>
+
+	* start/start.S: Align stack and tag TOS with a NULL
+	pointer (help terminate when walking the stack).
+
 2011-06-18	Ralf Corsépius <ralf.corsepius at rtems.org>
 
 	* Makefile.am: Remove references to non-existing files.

diff -u rtems/c/src/lib/libbsp/powerpc/qemuppc/start/start.S:1.3 rtems/c/src/lib/libbsp/powerpc/qemuppc/start/start.S:1.4
--- rtems/c/src/lib/libbsp/powerpc/qemuppc/start/start.S:1.3	Sun Nov 29 22:34:19 2009
+++ rtems/c/src/lib/libbsp/powerpc/qemuppc/start/start.S	Thu Jul 28 14:50:28 2011
@@ -1,12 +1,24 @@
+#include <rtems/score/cpu.h>
+#include <rtems/powerpc/powerpc.h>
+
+#include <bspopts.h>
+
         #.section ".text"
 	.section .entry_point_section,"awx", at progbits
         .global _start
 
 _start:
-        lis   %r1,_stack at h
-        ori   %r1,%r1,_stack at l
-        li     %r3,8192
-        mtmsr   %r3
+	lis   %r1,_stack at h
+	ori   %r1,%r1,_stack at l
+	/* Make sure stack is properly aligned */
+	li    %r3, CPU_STACK_ALIGNMENT - 1
+	andc  %r1, %r1, %r3
+	/* NULL ptr to back chain */
+	li    %r3, 0
+	stw   %r3, 0(%r1)
+
+	li    %r3,8192
+	mtmsr %r3
 
 	/* Read-only small data */
 	lis %r2, _SDA2_BASE_ at h



--

Generated by Deluxe Loginfo [http://www.codewiz.org/projects/index.html#loginfo] 2.122 by Bernardo Innocenti <bernie at develer.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/vc/attachments/20110728/8d8e73ee/attachment-0001.html>


More information about the vc mailing list