Re: [edk2] __executable_start

2015-08-10 Thread Andrew Fish

> On Aug 10, 2015, at 7:50 AM, Narinder Dhillon  wrote:
> 
> Not sure if this a problem, yet. Some other architectures don't seem to have 
> this offset. Perhaps they have a linker script, will check.

Most things are liked at zero, well zero relative to a PE/COFF header. So if 
the tools produce an ELF image they need to adjust for the PE/COFF header. 
When an FV is constructed the SEC, and PEIMs (PE/COFF or TE (shortened PE/COFF 
header)) are relocated to the correct address in the Flash Device (FD). When 
modules are loaded into memory they are relocated to their executable address. 
So in general things are never linked to their executable address. 

Thanks,

Andrew Fish

> Thanx.
> 
> On Sun, Aug 9, 2015 at 9:16 PM, Ard Biesheuvel  > wrote:
> On 9 August 2015 at 23:20, Narinder Dhillon  > wrote:
> > Hi All,
> >
> > I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
> > looked at the objdump of my 'dll' files and notice that entry point offset
> > is around 0x8000.
> >
> > Looking at DxeCore.map file I noticed below statement.
> > Any idea where this 0x8000 offset might be coming from ?
> >
> > Thanx.
> >
> > 0x8000PROVIDE
> > (__executable_start, 0x8000)
> > 0x8094. = (0x8000 +
> > SIZEOF_HEADERS)
> >
> 
> This is from the builtin linker script that GNU ld uses if you don't
> specify one on the command line.
> 
> Is this a problem?
> 
> --
> Ard.
> 
> --
> ___
> edk2-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/edk2-devel

--
___
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel


Re: [edk2] __executable_start

2015-08-10 Thread Narinder Dhillon
Not sure if this a problem, yet. Some other architectures don't seem to
have this offset. Perhaps they have a linker script, will check.
Thanx.

On Sun, Aug 9, 2015 at 9:16 PM, Ard Biesheuvel 
wrote:

> On 9 August 2015 at 23:20, Narinder Dhillon  wrote:
> > Hi All,
> >
> > I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
> > looked at the objdump of my 'dll' files and notice that entry point
> offset
> > is around 0x8000.
> >
> > Looking at DxeCore.map file I noticed below statement.
> > Any idea where this 0x8000 offset might be coming from ?
> >
> > Thanx.
> >
> > 0x8000PROVIDE
> > (__executable_start, 0x8000)
> > 0x8094. = (0x8000 +
> > SIZEOF_HEADERS)
> >
>
> This is from the builtin linker script that GNU ld uses if you don't
> specify one on the command line.
>
> Is this a problem?
>
> --
> Ard.
>
--
___
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel


Re: [edk2] __executable_start

2015-08-09 Thread Ard Biesheuvel
On 9 August 2015 at 23:20, Narinder Dhillon  wrote:
> Hi All,
>
> I am building a UEFI image for ARMv7 Cortex A7 SoC. While debugging, I
> looked at the objdump of my 'dll' files and notice that entry point offset
> is around 0x8000.
>
> Looking at DxeCore.map file I noticed below statement.
> Any idea where this 0x8000 offset might be coming from ?
>
> Thanx.
>
> 0x8000PROVIDE
> (__executable_start, 0x8000)
> 0x8094. = (0x8000 +
> SIZEOF_HEADERS)
>

This is from the builtin linker script that GNU ld uses if you don't
specify one on the command line.

Is this a problem?

-- 
Ard.

--
___
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel