AnsweredAssumed Answered

Linker does not transition from Non Paged to Paged allocations

Question asked by Ed Brady on Feb 17, 2010
Latest reply on Feb 18, 2010 by Ed Brady

I am compiling ~30K of code using the linker map snippet below.  Whenever I include the line

 

DEFAULT_ROM INTO OS_NONPAGED, OS_PAGED_E0

 

I will consistently see Linker Error L1102: Out of allocation space in segment OS_NONPAGED at address 0x7ee0.    However if I change the DEFAULT_ROM line to read

 

DEFAULT_ROM        INTO  OS_PAGED_E0, OS_NONPAGED;

 

It will link fine, but it will not run due to the Init function being placed in Paged Flash.

 

Can anyone give some input as to what is going on with this?  Thanks

 

-------------------------------------------------------------------------------------------

SEGMENTS
      EE_OS_VERSION = READ_ONLY     0x0FFC TO   0x0FFF;
      RAM           = READ_WRITE    0x2000 TO   0x3FFF;
      OS_NONPAGED   = READ_ONLY     0x4000 TO   0x7EFF;
      BOOT_PUB_FNS  = READ_ONLY     0xEFD0 TO   0xEFFF;
      RAM_F8        = READ_WRITE  0xF81000 TO 0xF81FFF;
      RAM_F9        = READ_WRITE  0xF91000 TO 0xF91FFF;
      RAM_FA        = READ_WRITE  0xFA1000 TO 0xFA1FFF;
      RAM_FB        = READ_WRITE  0xFB1000 TO 0xFB1FFF;
      RAM_FC        = READ_WRITE  0xFC1000 TO 0xFC1FFF;
      RAM_FD        = READ_WRITE  0xFD1000 TO 0xFD1FFB;
      OS_PAGED_E0   = READ_ONLY   0xE08000 TO 0xE0BFFF;
      OS_PAGED_E1   = READ_ONLY   0xE18000 TO 0xE1BFFF;
      BOOT_PARAM    = NO_INIT     0xFD1FFC TO 0xFD1FFF;

END

PLACEMENT
      _PRESTART,              
      STARTUP,                
      ROM_VAR,                
      STRINGS,                
      VIRTUAL_TABLE_SEGMENT,  
      NON_BANKED,             
      INTERRUPT,
      COPY              INTO  OS_NONPAGED;

      
     DEFAULT_ROM        INTO  OS_NONPAGED, OS_PAGED_E0;
      

      BOOT_PUBLIC_FNS   INTO  BOOT_PUB_FNS;

      EE_OS_VERSION     INTO  EE_OS_VERSION;      

      SSTACK,                 
      DEFAULT_RAM             
                        INTO  RAM;

      PAGED_RAM         INTO  RAM_F8, RAM_F9, RAM_FA, RAM_FB, RAM_FC, RAM_FD;

      BOOT_PARAM        INTO  BOOT_PARAM;           

END

Outcomes