linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: michael@ellerman.id.au
Cc: linuxppc64-dev@ozlabs.org,
	Stephen Rothwell <sfr@canb.auug.org.au>,
	linuxppc-dev@ozlabs.org
Subject: Re: [PATCH] powerpc: merged asm/cputable.h
Date: Tue, 27 Sep 2005 09:31:31 +1000	[thread overview]
Message-ID: <1127777491.15882.106.camel@gaston> (raw)
In-Reply-To: <200509270905.29545.michael@ellerman.id.au>


> > There is a small issue here: You turn identify_cpu into C code. However,
> > on ppc32, this is called with the kernel not yet relocated (before
> > prom_init even !). Same with the feature fixup. On ppc32, in order to
> > run C code that early, it needs to be in -mrelocatable bits of code
> > (like prom_init) or use RELOC macros (ugh !).
> 
> We could keep the bulk of the patch (turn cur_cpu_spec into a struct) but 
> still do identify_cpu() in asm, although it would seem like a step backward.

We can do it in C in ppc32 if we use proper RELOC() macros, or do it in
an -mrelocatable piece of code like prom_init (but I'd like to avoid
that).

> Do people think it's "better" to have one unified asm implementation, or one 
> in asm for ppc32 and one in C for ppc64?

We should only need one implementation for both I suppose.

Ben

  reply	other threads:[~2005-09-26 23:31 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-23 19:08 [PATCH] powerpc: merged asm/cputable.h Kumar Gala
2005-09-24  0:04 ` Paul Mackerras
2005-09-24  0:48   ` Stephen Rothwell
2005-09-24 15:35     ` Kumar Gala
2005-09-26  1:57       ` Michael Ellerman
2005-09-26 22:45         ` Benjamin Herrenschmidt
2005-09-26 23:05           ` Michael Ellerman
2005-09-26 23:31             ` Benjamin Herrenschmidt [this message]
2005-09-26 23:22           ` Kumar Gala
2005-09-26 23:38             ` Benjamin Herrenschmidt

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=1127777491.15882.106.camel@gaston \
    --to=benh@kernel.crashing.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=linuxppc64-dev@ozlabs.org \
    --cc=michael@ellerman.id.au \
    --cc=sfr@canb.auug.org.au \
    /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).