Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
12603 Discussions

Linker script and several SRAM components

Altera_Forum
Honored Contributor II
947 Views

Hi everyone, 

 

I've got a PCB with four SRAM modules which are connected to the NiosII cpu via a tri-state bridge. This gives me four components in the SOPC builder and in turn four sections in the BSP linker settings (I use uCosII). The problem is that the .bss section is to large for one of the sram sections which causes the linker to fail. I've changed several of the static allocations to dynamic, but it's still not enough. So my question is: Is it possible to merge all of the sram sections to one? I cannot think of any hw releated issues that should prevent this from working.
0 Kudos
1 Reply
Altera_Forum
Honored Contributor II
241 Views

If the physical addresses of the SRAM modules are adjacent, it ought to be possible to get is seen as a single memory area - and describe it in the linker script as a single area. 

Alternatively you could mark some data with __attribute__((".bss.a")) 

(or similar - and I might have the syntax wrong!) so that the linker can split the .bss between the memory regions. 

 

I'm not sure whether the linker can split one section (eg .bss) between multiple memory regions.
0 Kudos
Reply