Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Real time embedded FreeRTOS mailing list 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT Training


LPC2368 gcc eclipse demo lpc2368ld error?

Posted by Gea on December 12, 2007
A question regarding Freertos version 4.6.1 and ARM7 gcc eclipse:

In the lpc2368.ld the __bss_end__ is set to the beginning of ETH Ram. Is this correct?
The boot.S file states that the bss region shall be cleared and with __bss_end__ set to to beginning of ETH RAM it tries to clear a lot of RAM? The bss region ranges from ~0x40000000 to 0x7FE00000 according to the lpc2368.ld file.
I changed my lpc2368.ld so that __bss_end__ pointed to the end of the bss statement in the lpc2368.ld file.

flash: ORIGIN = 0x00000000, LENGTH = 500K
ram: ORIGIN = 0x40000000, LENGTH = 32K
usbram : ORIGIN = 0x7FD00000, LENGTH = 8K
ethram : ORIGIN = 0x7FE00000, LENGTH = 16K

__stack_end__ = 0x40000000 + 32K - 4;

. = 0;
startup : { KEEP(*(.startup))} >flash

prog :
} >flash

__end_of_text__ = .;

.data :
__data_beg__ = .;
__data_beg_src__ = __end_of_text__;
__data_end__ = .;
} >ram AT>flash

.bss :
__bss_beg__ = .;
} >ram

/* Align here to ensure that the .bss section occupies space up to
_end. Align after .bss to ensure correct alignment even if the
.bss section disappears because there are no input sections. */
. = ALIGN(32 / 8);

/*Better. */
_bss_end__ = . ; __bss_end__ = . ;

.usbram (NOLOAD):
__usbram_beg__ = .;
__usbram_end__ = .;
} >usbram

.ethram (NOLOAD):
__ethram_beg__ = .;
__ethram_end__ = .;
} >ethram

. = ALIGN(32 / 8);
_end = .;
/*No correct_bss_end__ = . ; __bss_end__ = . ; __end__ = . ;*/
__end__ = .;
PROVIDE (end = .);

Is this a bug?

RE: LPC2368 gcc eclipse demo lpc2368ld error?

Posted by Richard on December 18, 2007
To be honest I just copied this linker script from an existing example. I think your change is fine, although I don't think the original is a bug as such, just inefficient.


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]

Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.

Free TCP/IP and file system demos for the RTOS

Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑

FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists