linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Grant Likely" <grant.likely@secretlab.ca>
To: "M Ptich" <ptich@hotmail.com>
Cc: linuxppc-dev list <linuxppc-dev@ozlabs.org>
Subject: Re: Clear OS / HAL separation
Date: Fri, 3 Nov 2006 10:47:26 -0700	[thread overview]
Message-ID: <528646bc0611030947l259bb266p32d7df9dd2223c8f@mail.gmail.com> (raw)
In-Reply-To: <BAY102-F362BE9713459EAE9EED9FAA9FE0@phx.gbl>

On 11/3/06, M Ptich <ptich@hotmail.com> wrote:
> Hi Grant,
>
> Thanks a lot for your kind reply. What I meant is inordinate amount of
> sometimes ifdefs, sometimes call redirection (like ppc_md), pretty messy.
> But it is mostly in already machine-dependent code, so does not count as bad
> separation, you're right.
>
> But I am wondering about your remark that "there is separation between
> bootloader and
> kernel responsibilities". I think that on PPC Kernel depends very little on
> the bootloader - bootloader just needs to set up 5 input parameters (one of
> them is a pointer to initialized bd_t), and have initial Kernel TLB with
> IPROT=1. That's it, all the devices (including internal CPU stuff) are
> initialized in the Kernel. Am I correct ?

If you're looking in arch/ppc, you are 100% correct.  If you are
looking in arch/powerpc, which is where new development is occuring, a
device tree is used to pass information about available devices to the
kernel.  Also, your boot loader *should* (but you don't need to do it
this way) setup your SOC configuration (gpio, etc).  By doing it this
way, the device tree can encapsulate most of the differences between
different boards using the same processor (or SOC).  Board specific
code is kept to a minimum; or in some cases is non-existent.
Everything you need can be covered by device drivers and processor
specific code.

However, unless you've got real openfirmware, it is still just a
handoff from the bootloader to the kernel.  Once the kernel is booted,
it won't make any calls back to the bootloader.

Cheers,
g.

BTW, please make sure you include the mailing list when replying

-- 
Grant Likely, B.Sc. P.Eng.
Secret Lab Technologies Ltd.
grant.likely@secretlab.ca
(403) 399-0195

      parent reply	other threads:[~2006-11-03 17:47 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-03  3:39 Clear OS / HAL separation M Ptich
2006-11-03  6:15 ` Grant Likely
     [not found]   ` <BAY102-F362BE9713459EAE9EED9FAA9FE0@phx.gbl>
2006-11-03 17:47     ` Grant Likely [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=528646bc0611030947l259bb266p32d7df9dd2223c8f@mail.gmail.com \
    --to=grant.likely@secretlab.ca \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=ptich@hotmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).