Skip to contentSkip to conversation

Gnu Linker query

DISCUSSION Amol Kumar Lad 2 participants 2 messages Nov 21, 2002

lore
Share & tools
lore
#0 lore raw

Hi,
Please don't flame for posting in wrong list. I am not receiving any
reply to my query from [email protected]. I know people here will surely help me out.

Signature · 24 lines
 I am using gcc linker on a mips architecture. 
My .text segment for vmlinux starts at 0x80040000 and ends at 0x8010ffff
64K of memory region from 0x80060000 is reserved memory, I do not want
linker to generate any address of .text in this address range. How
should I do it . I tried using MEMORY command like

MEMORY
{  
   rom (!w!x) : ORIGIN = 0x80060000, LENGTH = 64K
}

.text 0x80040000 :
{
  *(.text)
} = 0

but still ld is using address range 0x80060000 (+64K) for .text .

In a nutshell, How do I reserve a memory in one particular section

Please CC me.

Thanks 
Amol
#1 lore raw
Quoted 4 lines · Amol Kumar Lad

Hi,
Please don't flame for posting in wrong list. I am not receiving any
reply to my query from [email protected]. I know people here will surely help me out.

That's because you waited less than a day for an answer, IIRC. And if you search the archives of the binutils list you'll find your answer.

You can't do this. You need to explicitly place things before or after the hole in two different sections.

Signature · 2 lines
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer