This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: ld: define new section for forthcoming devices


Oops,
I am really sorry sending a bit wrong path.
The attached one is a real one.
Thanks,
Dmitry.


On Thursday 27 November 2003 13:41, you wrote:
> Hi Fellows,
> There is a patch which defines new section for forthcoming devices.
>
> Cheers,
> Dmitry.
>
>
> 2003-11-27 Dmitry Diky <diwil@mail.ru>
> 	* scripttempl/elf32msp430.sc (HEAP_SECTION_MSP430): New section for
> forthcoming devices.
> 	   (_etext): provide this defenition for all scripts.
Index: scripttempl/elf32msp430.sc
===================================================================
RCS file: /cvs/src/src/ld/scripttempl/elf32msp430.sc,v
retrieving revision 1.3
diff -c -3 -p -r1.3 elf32msp430.sc
*** scripttempl/elf32msp430.sc	9 Apr 2003 11:07:51 -0000	1.3
--- scripttempl/elf32msp430.sc	27 Nov 2003 10:50:37 -0000
***************
*** 1,3 ****
--- 1,25 ----
+ #!/bin/sh
+ 
+ HEAP_SECTION_MSP430=" "
+ HEAP_MEMORY_MSP430=" "
+ 
+ if test ${GOT_HEAP_MSP-0} -ne 0 
+ then 
+ HEAP_SECTION_MSP430=".heap ${RELOCATING-0} :
+   {
+     ${RELOCATING+ PROVIDE (__heap_data_start = .) ; }
+     *(.heap*)
+     ${RELOCATING+ PROVIDE (_heap_data_end = .) ; }
+     ${RELOCATING+. = ALIGN(2);}
+     ${RELOCATING+ PROVIDE (__heap_bottom = .) ; }
+     ${RELOCATING+ PROVIDE (__heap_top = ${HEAP_START} + ${HEAP_LENGTH}) ; }
+   } ${RELOCATING+ > heap}"
+ HEAP_MEMORY_MSP430="heap(rwx) 		: ORIGIN = $HEAP_START,	LENGTH = $HEAP_LENGTH"
+ fi
+ 
+ 
+ 
+ 
  cat <<EOF
  OUTPUT_FORMAT("${OUTPUT_FORMAT}","${OUTPUT_FORMAT}","${OUTPUT_FORMAT}")
  OUTPUT_ARCH(${ARCH})
*************** MEMORY
*** 10,15 ****
--- 32,38 ----
    bootloader(rx)	: ORIGIN = 0x0c00,	LENGTH = 1K
    infomem(rx)		: ORIGIN = 0x1000,	LENGTH = 256
    infomemnobits(rx)	: ORIGIN = 0x1000,      LENGTH = 256
+   ${HEAP_MEMORY_MSP430}
  }
  
  SECTIONS
*************** SECTIONS
*** 115,121 ****
      *(.fini0)  /* Infinite loop after program termination.  */
      *(.fini)
  
!     ${RELOCATING+ _etext = . ; }
    } ${RELOCATING+ > text}
  
    .data ${RELOCATING-0} : ${RELOCATING+AT (ADDR (.text) + SIZEOF (.text))}
--- 138,144 ----
      *(.fini0)  /* Infinite loop after program termination.  */
      *(.fini)
  
!     _etext = .;
    } ${RELOCATING+ > text}
  
    .data ${RELOCATING-0} : ${RELOCATING+AT (ADDR (.text) + SIZEOF (.text))}
*************** SECTIONS
*** 179,185 ****
      ${RELOCATING+ _vectors_end = . ; }
    } ${RELOCATING+ > vectors}
  
! 
    /* Stabs debugging sections.  */
    .stab 0 : { *(.stab) } 
    .stabstr 0 : { *(.stabstr) }
--- 202,209 ----
      ${RELOCATING+ _vectors_end = . ; }
    } ${RELOCATING+ > vectors}
  
!   ${HEAP_SECTION_MSP430}
!     
    /* Stabs debugging sections.  */
    .stab 0 : { *(.stab) } 
    .stabstr 0 : { *(.stabstr) }
*************** SECTIONS
*** 219,223 ****
--- 243,248 ----
    PROVIDE (__data_end_rom   = _etext + SIZEOF (.data)) ;
    PROVIDE (__noinit_start_rom = _etext + SIZEOF (.data)) ;
    PROVIDE (__noinit_end_rom = _etext + SIZEOF (.data) + SIZEOF (.noinit)) ;
+   PROVIDE (__subdevice_has_heap = ${GOT_HEAP_MSP-0}) ;
  }
  EOF

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]