Port-powerpc archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: The Kernel for powermacs



I have been examining the linuxppc code a bit, and a few discrepencies have
turned up - nothing that seems to be the cause of our problem, though.

For instance - they do not use OF_claim in their bootloader the way we do
in ofwboot/boot.c, as far as I can tell.  They simply load the kernel in
low core (0x0000).  Also, they are more rigid about setting the return
value slot in each open firmware call to -1, which we skip - probably,
safely.

I also noticed one oddity in our locore.S.  This is right above
ENTRY(ofw_stack):

/*
 * Switch to/from OpenFirmware real mode stack
 *
 * Note: has to be called as the very first thing in OpenFirmware interface
 * routines.
 * E.g.:
 * int
 * OF_xxx(arg1, arg2)
 * type arg1, arg2;
 * {
 *      static struct {
 *              char *name;
 *              int nargs;
 *              int nreturns;
 *              char *method;
 *              int arg1;
 *              int arg2;
 *              int ret;
 *      } args = {
 *              "xxx",
 *              2,
 *              1,
 *      };
 *
 *      ofw_stack();
 *      args.arg1 = arg1;
 *      args.arg2 = arg2;
 *      if (openfirmware(&args) < 0)
 *              return -1;
 *      return args.ret;
 * }
 */

Is this not yet an issue in ofwboot? Does it have to do with the kernel's
own stack? It is called religiously in openfirm.c but not in
ofwboot/Locore.c.



In case no one else mentioned this...
After the first boot fails with a default catch, if I try again, instead of:
loading .text...
loading .data...
clearing .bss...

I get:
loading .textCLAIM FAILED

Hm.
I confess yet again all the intricacies of this are bypassing me :)

---------------------------------------------------------------------
| Dan Jacobowitz                 | drow%drow.net@localhost                    |
|  Administrator Extraordinaire  | Web site coming someday          |
| My opinions are my own -       | Day Job: http://www.wwwcomm.com  |
| My mistakes are someone else's |                                  |
---------------------------------------------------------------------





Home | Main Index | Thread Index | Old Index