[Sound-open-firmware] Linker scripts

Liam Girdwood liam.r.girdwood at linux.intel.com
Fri Dec 21 23:19:19 CET 2018


On Fri, 2018-12-21 at 23:42 +0200, Daniel Baluta wrote:
> Hi Liam,
> 
> Do you have any guide on how to generate the linker scripts for sof/?
> For example sof/src/platform/suecreek/suecreek.x.in.
> 
> Did you use Xtensa Xplorer?
> 

No, I initially used an Xplorer script as a template and then edited as
required. 

> Any public docs or hints would be excellent.
> 

So the x.in script is pre-processed by gcc (like a C file) to generate the .x
file and  any macros are resolved to use the correct addresses for exceptions,
text, data etc. memory.h and core-isa.h are the headers it mainly needs (if you
are xtensa based).

I would recommend just copying an existing file like apollolake.x.in and then
using your core-isa.h and memory.h it should be straight forward to declare all
your sections etc.

Fwiw, there is some documentation on the GNU linker script syntax, keyword etc
on the GCC site.

Liam


> thanks,
> Daniel.
> _______________________________________________
> Sound-open-firmware mailing list
> Sound-open-firmware at alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/sound-open-firmware



More information about the Sound-open-firmware mailing list