linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Matthew S. McClintock" <mattsm@arlut.utexas.edu>
To: Milliorn Gary-rxcr80 <Gary.Milliorn@motorola.com>
Cc: linuxppc-embedded@lists.linuxppc.org
Subject: RE: TLB and CSSBAR problems with MPC8540 and BDI2000
Date: Wed, 28 Jan 2004 09:57:21 -0600	[thread overview]
Message-ID: <1075305441.1204.22.camel@chuck.arlut.utexas.edu> (raw)
In-Reply-To: <5725AF6EE9FAD51195DC009027E377020B6562DD@az33exm35.corp.mot.com>


On Wed, 2004-01-14 at 11:19, Milliorn Gary-rxcr80 wrote:

> >
> > Yep.  I have one now.  Make sure your u-boot image also has a TLB1
> > entry for your "default" CCSRBAR.  Further, make sure your BDI init
> > section doesn't move the CCSRBAR from the default value assumed by
> > your u-boot image.  I had the latter correct, just didn't realize
> > that a "TLB1 flash invalidate" command to the MMUCSR0 doesn't seem
> > to honor the 'invalidate protect' in the TLB entry.  Everything
> > works fine when you get all of the ducks in a row :-)
>
>   The TLB1 issue is due to the MPC85x0 errata "CPU4"; there's a s/w
> workaround.  It's nice if BDI fixes it for you, but seems like it would
> not be necessary.
>

	So I have noticed some things, maybe someone here can explain this.
When If configure everything with my bdi2000 and attempt to boot u-boot
my CPU will crash (COP freeze) when I get to the code that implements
the software workaround that was mentioned above.

	However if I do not configure anything with the bdi2000, and boot
u-boot, it will load just fine. I have even removed the code that causes
the crash in u-boot, recompiled u-boot and with those changes u-boot
will not crash the CPU. But, that same u-boot image will not boot if I
do not have the bdi2000 attached.

	So I guess the question is, what could be configured that would cause
this CPU to crash when the code for the errata was executed?

Here is the code for the workaround:

/* invalidate MMU L1/L2 */
/* Note: before invalidate MMU L1/L2, we read TLB1 Entry 0 and then
 * write it back immediately to fixup a bug(Errata CPU4)  for this
initial
 * TLB1 entry 0,otherwise the TLB1 entry 0 will be invalidated.
 */
#if defined(CONFIG_MPC85xx_REV1)
	lis	r2,0x1000
	mtspr	MAS0,r2
	tlbre
	tlbwe
	isync
	li      r2, 0x001e
	mtspr   MMUCSR0, r2
	isync
#endif

--
Matthew S. McClintock <mattsm@arlut.utexas.edu>


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

  parent reply	other threads:[~2004-01-28 15:57 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-14 17:19 TLB and CSSBAR problems with MPC8540 and BDI2000 Milliorn Gary-rxcr80
2004-01-14 18:39 ` Dan Malek
2004-01-28 15:57 ` Matthew S. McClintock [this message]
2004-01-28 16:10   ` Kumar Gala
2004-01-28 16:47     ` Matthew S. McClintock
  -- strict thread matches above, loose matches on Subject: below --
2004-01-09 16:42 [Q] question about using x86 gdb to debug the remote ppc target (kgdb) Christopher R. Johnson
2004-01-09 17:40 ` TLB and CSSBAR problems with MPC8540 and BDI2000 Fahd Abidi
2004-01-09 17:54   ` Dan Malek
2004-01-09 19:45     ` Matthew S. McClintock
2004-01-09 22:13       ` Dan Malek
2004-01-09 22:18         ` Matthew S. McClintock
2004-01-09 22:28           ` Dan Malek
2004-01-12 15:56             ` Dan Malek
2004-01-12 20:19               ` Matthew S. McClintock
2004-01-14  1:43                 ` Dan Malek

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=1075305441.1204.22.camel@chuck.arlut.utexas.edu \
    --to=mattsm@arlut.utexas.edu \
    --cc=Gary.Milliorn@motorola.com \
    --cc=linuxppc-embedded@lists.linuxppc.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).