[En-Nut-Discussion] Nut/OS Initialization

Harald Kipp harald.kipp at egnite.de
Wed Sep 17 20:23:43 CEST 2008


Nathan Moore wrote:

> Linker magic lets the OS know if you can force the linker to put all of the
> structures
> in one section (similar to .data, .bss, .text, ...), all of the device
> structures are the
> same size (or know how big they are), and the OS can see where the beginning
> and
> end of this section is.
> I'm not a linker wiz, but I'm pretty sure that you can do this with gnu ld
> scripts and
> a gcc __attribute__((section("  "))) for NUTDEVICEs.
> Finding the location and size of this section should be as simple as finding
> the location
> and size of the heap in NutOs.

I'm definitely no linker wiz either, but that's easy.

What makes this even more attractive is the fact, that it should work 
with almost all compilers/linkers I know of.

Indeed, this is a clever solution. :-)

Harald





More information about the En-Nut-Discussion mailing list