From: Tom Rini <trini@kernel.crashing.org>
To: Joakim Tjernlund <joakim.tjernlund@lumentis.se>
Cc: "Linuxppc-Embedded@Ozlabs. Org" <linuxppc-embedded@ozlabs.org>
Subject: Re: [PATCH] Handle I-TLB Error and Miss separately on 8xx
Date: Tue, 18 Jan 2005 13:09:44 -0700 [thread overview]
Message-ID: <20050118200944.GN28724@smtp.west.cox.net> (raw)
In-Reply-To: <JPEALJAFNGDDLOPNDIEEEECGDAAA.joakim.tjernlund@lumentis.se>
On Fri, Jan 14, 2005 at 08:51:44PM +0100, Joakim Tjernlund wrote:
> BTW, there is a simpler fix to the TLB Miss problem.
> In the TLB Miss handlers, just move the 2: label a few instr. upwards to
> the same line as the "li r21, 0x00f0". That way you will force a
> TLB error. You can do this for both Data and Instr. Miss handlers.
> The code after where the 2: label used to be can be deleted.
Like this? Only lightly tested on my rpxlite on 2.6:
---
linux-2.6-current-trini/arch/ppc/kernel/head_8xx.S | 22 +--------------------
1 files changed, 2 insertions(+), 20 deletions(-)
diff -puN arch/ppc/kernel/head_8xx.S~ppc32-mpc8xx-itlbmiss-fix arch/ppc/kernel/head_8xx.S
--- linux-2.6-current/arch/ppc/kernel/head_8xx.S~ppc32-mpc8xx-itlbmiss-fix 2005-01-18 11:55:34.000000000 -0700
+++ linux-2.6-current-trini/arch/ppc/kernel/head_8xx.S 2005-01-18 11:57:11.000000000 -0700
@@ -343,7 +343,7 @@ InstructionTLBMiss:
* set. All other Linux PTE bits control the behavior
* of the MMU.
*/
- li r11, 0x00f0
+2: li r11, 0x00f0
rlwimi r10, r11, 0, 24, 28 /* Set 24-27, clear 28 */
DO_8xx_CPU6(0x2d80, r3)
mtspr MI_RPN, r10 /* Update TLB entry */
@@ -357,15 +357,6 @@ InstructionTLBMiss:
#endif
rfi
-2: mfspr r10, M_TW /* Restore registers */
- lwz r11, 0(r0)
- mtcr r11
- lwz r11, 4(r0)
-#ifdef CONFIG_8xx_CPU6
- lwz r3, 8(r0)
-#endif
- b InstructionAccess
-
. = 0x1200
DataStoreTLBMiss:
#ifdef CONFIG_8xx_CPU6
@@ -419,7 +410,7 @@ DataStoreTLBMiss:
* set. All other Linux PTE bits control the behavior
* of the MMU.
*/
- li r11, 0x00f0
+2: li r11, 0x00f0
rlwimi r10, r11, 0, 24, 28 /* Set 24-27, clear 28 */
DO_8xx_CPU6(0x3d80, r3)
mtspr MD_RPN, r10 /* Update TLB entry */
@@ -433,15 +424,6 @@ DataStoreTLBMiss:
#endif
rfi
-2: mfspr r10, M_TW /* Restore registers */
- lwz r11, 0(r0)
- mtcr r11
- lwz r11, 4(r0)
-#ifdef CONFIG_8xx_CPU6
- lwz r3, 8(r0)
-#endif
- b DataAccess
-
/* This is an instruction TLB error on the MPC8xx. This could be due
* to many reasons, such as executing guarded memory or illegal instruction
* addresses. There is nothing to do but handle a big time error fault.
_
--
Tom Rini
http://gate.crashing.org/~trini/
next prev parent reply other threads:[~2005-01-18 20:09 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-12 7:53 [PATCH] Handle I-TLB Error and Miss separately on 8xx Joakim Tjernlund
2005-01-12 14:06 ` Tom Rini
2005-01-12 14:17 ` Joakim Tjernlund
2005-01-12 15:15 ` Tom Rini
2005-01-13 15:16 ` Tom Rini
2005-01-14 14:03 ` Joakim Tjernlund
2005-01-14 17:38 ` Joakim Tjernlund
2005-01-14 17:47 ` Tom Rini
2005-01-14 17:56 ` Joakim Tjernlund
2005-01-14 18:05 ` Tom Rini
2005-01-14 19:51 ` Joakim Tjernlund
2005-01-18 20:09 ` Tom Rini [this message]
2005-01-18 22:02 ` Joakim Tjernlund
2005-01-19 17:25 ` Dan Malek
2005-01-19 18:06 ` Joakim Tjernlund
2005-01-19 18:37 ` Dan Malek
2005-01-19 19:58 ` Joakim Tjernlund
2005-01-19 0:30 ` Joakim Tjernlund
2005-01-19 17:28 ` Dan Malek
2005-01-19 18:12 ` Joakim Tjernlund
-- strict thread matches above, loose matches on Subject: below --
2005-01-07 16:22 Tom Rini
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=20050118200944.GN28724@smtp.west.cox.net \
--to=trini@kernel.crashing.org \
--cc=joakim.tjernlund@lumentis.se \
--cc=linuxppc-embedded@ozlabs.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;
as well as URLs for NNTP newsgroup(s).