* new OF: how can we use it?
@ 1999-05-27 15:38 Brad Midgley
1999-05-27 19:39 ` Tom Rini
0 siblings, 1 reply; 6+ messages in thread
From: Brad Midgley @ 1999-05-27 15:38 UTC (permalink / raw)
To: linuxppc-dev
hi guys...
don't you think it would be a great help to the success of linux on
powermac if we could make the kind of elf binary that the new open
firmware loads?
(it would also be nice to get it to include an initial ramdisk like paul
did with the coff binary)
we could make bootable cd's for powermac
macos wouldn't be required any more
we could net-boot
what remains to be done? is the problem well understood/documented?
Brad
brad@pht.com | http://www.pht.com/~brad/
[[ This message was sent via the linuxppc-dev mailing list. Replies are ]]
[[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]]
[[ reply is of general interest. Please check http://lists.linuxppc.org/ ]]
[[ and http://www.linuxppc.org/ for useful information before posting. ]]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new OF: how can we use it?
1999-05-27 15:38 new OF: how can we use it? Brad Midgley
@ 1999-05-27 19:39 ` Tom Rini
1999-05-27 23:28 ` Joel Klecker
1999-05-28 0:28 ` David Edelsohn
0 siblings, 2 replies; 6+ messages in thread
From: Tom Rini @ 1999-05-27 19:39 UTC (permalink / raw)
To: Brad Midgley; +Cc: linuxppc-dev
On Thu, 27 May 1999, Brad Midgley wrote:
> don't you think it would be a great help to the success of linux on
> powermac if we could make the kind of elf binary that the new open
> firmware loads?
[neat ideas nusked]
> what remains to be done? is the problem well understood/documented?
It might be the text segments at the start. Basically we need to see how
darwin and netbsd/macppc are linked and what they do that we don't (or
that we do and don't need to). This is of coruse only my understanding,
from a dozen emails w/ adrian sun (I have access to an iMac, he
wants/wanted to fix it).
---
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
[[ This message was sent via the linuxppc-dev mailing list. Replies are ]]
[[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]]
[[ reply is of general interest. Please check http://lists.linuxppc.org/ ]]
[[ and http://www.linuxppc.org/ for useful information before posting. ]]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new OF: how can we use it?
1999-05-27 19:39 ` Tom Rini
@ 1999-05-27 23:28 ` Joel Klecker
1999-05-27 23:33 ` Tom Rini
1999-05-28 0:28 ` David Edelsohn
1 sibling, 1 reply; 6+ messages in thread
From: Joel Klecker @ 1999-05-27 23:28 UTC (permalink / raw)
To: linuxppc-dev
At 15:39 -0400 1999-05-27, Tom Rini wrote:
>On Thu, 27 May 1999, Brad Midgley wrote:
>> don't you think it would be a great help to the success of linux on
>> powermac if we could make the kind of elf binary that the new open
>> firmware loads?
>[neat ideas nusked]
>> what remains to be done? is the problem well understood/documented?
>
>It might be the text segments at the start. Basically we need to see how
>darwin and netbsd/macppc are linked and what they do that we don't (or
>that we do and don't need to). This is of coruse only my understanding,
>from a dozen emails w/ adrian sun (I have access to an iMac, he
>wants/wanted to fix it).
NetBSD/macppc kernels have the .note section that OF wants,
Linux/powerpc kernels do not.
<ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-current/src/sys/arch
/powerpc/powerpc/ofwmagic.S>
See also vger: linux/arch/ppc/chrpboot/{mknote.c,Makefile}.
--
Joel Klecker (aka Espy) Debian GNU/Linux Developer
<URL:mailto:jk@espy.org> <URL:mailto:espy@debian.org>
<URL:http://web.espy.org/> <URL:http://www.debian.org/>
[[ This message was sent via the linuxppc-dev mailing list. Replies are ]]
[[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]]
[[ reply is of general interest. Please check http://lists.linuxppc.org/ ]]
[[ and http://www.linuxppc.org/ for useful information before posting. ]]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new OF: how can we use it?
1999-05-27 23:28 ` Joel Klecker
@ 1999-05-27 23:33 ` Tom Rini
1999-05-28 4:13 ` Troy Benjegerdes
0 siblings, 1 reply; 6+ messages in thread
From: Tom Rini @ 1999-05-27 23:33 UTC (permalink / raw)
To: Joel Klecker; +Cc: linuxppc-dev
On Thu, 27 May 1999, Joel Klecker wrote:
> At 15:39 -0400 1999-05-27, Tom Rini wrote:
> >On Thu, 27 May 1999, Brad Midgley wrote:
> >> don't you think it would be a great help to the success of linux on
> >> powermac if we could make the kind of elf binary that the new open
> >> firmware loads?
> >[neat ideas nusked]
> >> what remains to be done? is the problem well understood/documented?
> >
> >It might be the text segments at the start. Basically we need to see how
> >darwin and netbsd/macppc are linked and what they do that we don't (or
> >that we do and don't need to). This is of coruse only my understanding,
> >from a dozen emails w/ adrian sun (I have access to an iMac, he
> >wants/wanted to fix it).
>
> NetBSD/macppc kernels have the .note section that OF wants,
> Linux/powerpc kernels do not.
>
> <ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-current/src/sys/arch
> /powerpc/powerpc/ofwmagic.S>
>
> See also vger: linux/arch/ppc/chrpboot/{mknote.c,Makefile}.
Hmm. So has anybody tried booting a CHRP-specific 2.3.x kernel on a B&W
or iMac? :)
---
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
[[ This message was sent via the linuxppc-dev mailing list. Replies are ]]
[[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]]
[[ reply is of general interest. Please check http://lists.linuxppc.org/ ]]
[[ and http://www.linuxppc.org/ for useful information before posting. ]]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new OF: how can we use it?
1999-05-27 19:39 ` Tom Rini
1999-05-27 23:28 ` Joel Klecker
@ 1999-05-28 0:28 ` David Edelsohn
1 sibling, 0 replies; 6+ messages in thread
From: David Edelsohn @ 1999-05-28 0:28 UTC (permalink / raw)
To: Tom Rini; +Cc: Brad Midgley, linuxppc-dev
I presume that vger's mknote does all of the following, but the
special details that CHRP requires are:
A standard ELF-format PowerPC program
e_ident = \7FELF (first byte is hex 7F)
e_ident[EI_CLASS] = 1
e_type = 2
e_machine = 20 (PowerPC)
e_version = 1
e_flags = 0
A "note" section which looks like:
.section .note
.align 4
/* length of PowerPC string */
.long 8
/* length of note descriptor */
.long 24
/* code for PowerPC open firmware */
.long 0x1275
/* PowerPC string */
.asciz "PowerPC"
/* real-mode true=-1 false=0 */
.long -1
/* real base of OF (do not care / use defaults = -1) */
.long -1
/* real size of OF (do not care / use defaults = -1) */
.long -1
/* virtual base of OF (ignored in real-mode) */
.long -1
/* virtual size of OF (ignored in real-mode) */
.long -1
/* load base of program (example real mode 0x4000) */
.long 0x4000
One needs to ensure that the loaded program base does not specify a
location which overwrites Open Firmware itself.
The ELF header must contain a PT_NOTE segment table entry pointing
to the note section as well as PT_LOAD segment table entries pointing to
the actual program image. The GNU linker for PowerPC probably does not
create a PT_NOTE segment in the loader header although it does include the
.note section in the image.
If all is correct, OF transfers control to the image entry point
with the five OF parameters including the OF client services entry point
in r5 (third parameter).
David
[[ This message was sent via the linuxppc-dev mailing list. Replies are ]]
[[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]]
[[ reply is of general interest. Please check http://lists.linuxppc.org/ ]]
[[ and http://www.linuxppc.org/ for useful information before posting. ]]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new OF: how can we use it?
1999-05-27 23:33 ` Tom Rini
@ 1999-05-28 4:13 ` Troy Benjegerdes
0 siblings, 0 replies; 6+ messages in thread
From: Troy Benjegerdes @ 1999-05-28 4:13 UTC (permalink / raw)
To: Tom Rini; +Cc: Joel Klecker, linuxppc-dev
On Thu, 27 May 1999, Tom Rini wrote:
>
> On Thu, 27 May 1999, Joel Klecker wrote:
>
> > At 15:39 -0400 1999-05-27, Tom Rini wrote:
> > >On Thu, 27 May 1999, Brad Midgley wrote:
> > >> don't you think it would be a great help to the success of linux on
> > >> powermac if we could make the kind of elf binary that the new open
> > >> firmware loads?
> > >[neat ideas nusked]
> > >> what remains to be done? is the problem well understood/documented?
> > >
> > >It might be the text segments at the start. Basically we need to see how
> > >darwin and netbsd/macppc are linked and what they do that we don't (or
> > >that we do and don't need to). This is of coruse only my understanding,
> > >from a dozen emails w/ adrian sun (I have access to an iMac, he
> > >wants/wanted to fix it).
> >
> > NetBSD/macppc kernels have the .note section that OF wants,
> > Linux/powerpc kernels do not.
> >
> > <ftp://ftp.netbsd.org/pub/NetBSD/NetBSD-current/src/sys/arch
> > /powerpc/powerpc/ofwmagic.S>
> >
> > See also vger: linux/arch/ppc/chrpboot/{mknote.c,Makefile}.
>
> Hmm. So has anybody tried booting a CHRP-specific 2.3.x kernel on a B&W
> or iMac? :)
Just tried using the latest vger 'chrpboot', which makes a zImage, from a
Pmac kernel, and got 'gunzipping...'
'Default Catch 0900' (which is the decrementer exception)
FYI, netbooting uses standard bootp and tftp 8->
>
> ---
> Tom Rini (TR1265)
> http://gate.crashing.org/~trini/
>
>
--------------------------------------------------------------------------
| Troy Benjegerdes | troy@microux.com | hozer@drgw.net |
| Unix is user friendly... You just have to be friendly to it first. |
| This message composed with 100% free software. http://www.gnu.org |
--------------------------------------------------------------------------
[[ This message was sent via the linuxppc-dev mailing list. Replies are ]]
[[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]]
[[ reply is of general interest. Please check http://lists.linuxppc.org/ ]]
[[ and http://www.linuxppc.org/ for useful information before posting. ]]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~1999-05-28 4:13 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-05-27 15:38 new OF: how can we use it? Brad Midgley
1999-05-27 19:39 ` Tom Rini
1999-05-27 23:28 ` Joel Klecker
1999-05-27 23:33 ` Tom Rini
1999-05-28 4:13 ` Troy Benjegerdes
1999-05-28 0:28 ` David Edelsohn
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).