mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Janzen <pcj@linux.sez.to>
To: linux-kernel@vger.kernel.org
Subject: [PATCH] ppc/boot: Put flush_{instruction,data}_cache back in .relocate_code section
Date: Thu, 05 Jan 2006 22:27:49 -0800	[thread overview]
Message-ID: <oqzmm9oopm.fsf@merlin.sez.to> (raw)

As part of the Great PowerPC Include Merge, the _GLOBAL() assembler
macro was changed to force code declared using _GLOBAL() to be in the
.text section.  As a result, two symbols defined in
arch/ppc/boot/common/util.S which are intended to be in the
.relocate_code section are being placed in .text instead, which causes
booting to fail.

There's another suspicious-looking usage at
arch/ppc/kernel/swsusp.S:37 (swsusp_save_area) that should be looked
into.  I did not exhaustively search the source tree, though.

This is the minimal patch that fixes the immediate problem.  I could
easily be convinced that the _GLOBAL macro should be modified to
remove the ".text;" line either instead of, or in addition to, this
fix.

Signed-off-by: Paul Janzen <pcj@linux.sez.to>
Acked-by: Tom Rini <trini@kernel.crashing.org>

--- a/arch/ppc/boot/common/util.S	2005-12-24 15:47:48.000000000 -0800
+++ b/arch/ppc/boot/common/util.S 	2006-01-04 14:07:12.000000000 -0800
@@ -234,7 +234,8 @@ udelay:
  * First, flush the data cache in case it was enabled and may be
  * holding instructions for copy back.
  */
-_GLOBAL(flush_instruction_cache)
+        .globl flush_instruction_cache
+flush_instruction_cache:
 	mflr	r6
 	bl	flush_data_cache
 
@@ -279,7 +280,8 @@ _GLOBAL(flush_instruction_cache)
  * Flush data cache
  * Do this by just reading lots of stuff into the cache.
  */
-_GLOBAL(flush_data_cache)
+        .globl flush_data_cache
+flush_data_cache:
 	lis	r3,cache_flush_buffer@h
 	ori	r3,r3,cache_flush_buffer@l
 	li	r4,NUM_CACHE_LINES



                 reply	other threads:[~2006-01-06  6:28 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=oqzmm9oopm.fsf@merlin.sez.to \
    --to=pcj@linux.sez.to \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®