[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?
From: |
malc |
Subject: |
Re: [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting? |
Date: |
Mon, 20 Apr 2009 04:15:30 +0400 (MSD) |
On Sun, 19 Apr 2009, Steven Noonan wrote:
> On Sun, Apr 19, 2009 at 3:28 PM, Steven Noonan <address@hidden> wrote:
> > On Sun, Apr 19, 2009 at 2:32 PM, Steven Noonan <address@hidden> wrote:
> >> On Sun, Apr 19, 2009 at 2:02 PM, Steven Noonan <address@hidden> wrote:
> >>> On Sun, Apr 19, 2009 at 1:48 PM, Laurent Vivier <address@hidden> wrote:
> >>>> Le dimanche 19 avril 2009 ? 13:33 -0700, Steven Noonan a ?crit :
> >>>>> On Sun, Apr 19, 2009 at 1:24 PM, Laurent Vivier <address@hidden> wrote:
> >>>>> > Le dimanche 19 avril 2009 ? 13:14 -0700, Steven Noonan a ?crit :
> >>>>> > The problem is in OpenBios: I put some structures in memory without
> >>>>> > knowing this... but this is not part of openfirmware specification.
[..snip..]
> >>
> >> diff --git a/arch/ppc/qemu/ldscript b/arch/ppc/qemu/ldscript
> >> index 66fcbcd..8fdf654 100644
> >> --- a/arch/ppc/qemu/ldscript
> >> +++ b/arch/ppc/qemu/ldscript
> >> @@ -3,15 +3,15 @@ OUTPUT_ARCH(powerpc)
> >>
> >> /* Initial load address
> >> */
> >> -BASE_ADDR = 0xfff00000;
> >> +BASE_ADDR = 0x06800000;
> >>
> >> -/* As NVRAM is at 0xfff04000, the .text needs to be after that
> >> +/* As NVRAM is at 0x06804000, the .text needs to be after that
> >> */
> >> -TEXT_ADDR = 0xfff08000;
> >> +TEXT_ADDR = 0x06808000;
> >>
> >> /* Hard reset vector address
> >> */
> >> -HRESET_ADDR = 0xfffffffc;
> >> +HRESET_ADDR = 0x06ffffff;
> >>
> >> CSTACK_SIZE = 32768; /* client stack size */
> >
> > With the above numbers, I get linker problems:
> >
> > target/arch/ppc/qemu/start.o: In function `vector__0x300':
> > (.text.vectors+0x384): relocation truncated to fit: R_PPC_ADDR24
> > against `.text.vectors'+c
> > target/arch/ppc/qemu/start.o: In function `vector__0x400':
> > (.text.vectors+0x484): relocation truncated to fit: R_PPC_ADDR24
> > against `.text.vectors'+c
> >
> > I don't see why it'd do that.
> >
>
>
> What the hell? Why would this change resolve it?
>
> diff --git a/arch/ppc/qemu/start.S b/arch/ppc/qemu/start.S
> index 66df9a2..108fd9b 100644
> --- a/arch/ppc/qemu/start.S
> +++ b/arch/ppc/qemu/start.S
> @@ -206,7 +206,7 @@ VECTOR( 0x300, "DSI" ):
> addi r3,r3,LO(dsi_exception)
> mtctr r3
> bctrl
> - ba exception_return
> + b exception_return
>
Because exception_return's address (now near 0x06808000) doesn't fit
into 26 bit sign extended AA field.
> VECTOR( 0x400, "ISI" ):
> EXCEPTION_PREAMBLE
> @@ -214,7 +214,7 @@ VECTOR( 0x400, "ISI" ):
> addi r3,r3,LO(isi_exception)
> mtctr r3
> bctrl
> - ba exception_return
> + b exception_return
>
> ILLEGAL_VECTOR( 0x500 )
> ILLEGAL_VECTOR( 0x600 )
>
>
> >>
> >> The only issue with doing things this way is now to figure out what to
> >> change this to:
> >>
> >> #define FREE_BASE 0x00004000
> >>
> >> My first thought was to utilize all 8MB of the space that Apple says
> >> we can have, and use any space after the OpenBIOS image. My second
> >> thought was: how do we know where the OpenBIOS executable image ends?
> >>
> >> Any ideas?
> >>
> >
>
>
--
mailto:address@hidden
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, (continued)
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Laurent Vivier, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Laurent Vivier, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Laurent Vivier, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- Re: [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?,
malc <=
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Steven Noonan, 2009/04/19
- [Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Alexander Graf, 2009/04/26
[Qemu-devel] Re: [OpenBIOS] QEMU OpenBIOS booting?, Laurent Vivier, 2009/04/19