From: Kumar Gala <kumar.gala@freescale.com>
To: Dan Malek <dan@embeddededge.com>
Cc: linuxppc-dev list <linuxppc-dev@ozlabs.org>
Subject: Re: [PATCH] ppc32: Fix alignment exception checking on load/store multiple instructions
Date: Tue, 12 Apr 2005 10:26:48 -0500 [thread overview]
Message-ID: <cb6c89fb776248d3a2ddbcd5d3d043ed@freescale.com> (raw)
In-Reply-To: <7f0a378a4f3b17a9db01773fcca5fafd@freescale.com>
> > > The handling of misaligned load/store multiplies did not check to=20=
> see
> > > if
> >=A0 > the address were ok to access before __{get,put}_user().
> >
> > I think we should also take the opportunity to fix up the lawrx
> > case and look for other reserved/conditional instructions
> >=A0 that may slip through.=A0 Since these are atomic operations, we
> > can't emulate them.=A0 According to the PEM, an alignment fault
> > on these is a fatal programming error.
>
> When you say "fix up" I assume you mean lwarx should return 0.=A0 It
> appears that stwcx. is already doing that.=A0 Can't think of any other
> cases that need fixing.
Upon further review, the PEM and PPC Arch spec, say that its ok to=20
emulate lwarz as an lwz. =46rom the spec:
The instructions lwz and lwarx give the same DSISR bits (all zero). But=20=
if lwarx causes an Alignment interrupt, it should not be emulated. It=20
is adequate for the Alignment interrupt handler simply to treat the=20
instruction as if it were lwz. The emulator
must use the address in the DAR, rather than compute it from RA/RB/D,=20
because lwz and lwarx have different instruction formats.
So we are handled lwarx according to the arch specs already.
- kumar=
next prev parent reply other threads:[~2005-04-12 15:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-12 6:03 [PATCH] ppc32: Fix alignment exception checking on load/store multiple instructions Kumar Gala
2005-04-12 14:46 ` Dan Malek
2005-04-12 15:06 ` Kumar Gala
2005-04-12 15:26 ` Kumar Gala [this message]
2005-04-12 16:20 ` Dan Malek
2005-04-12 15:31 ` Dan Malek
2005-04-19 14:50 ` Kumar Gala
2005-04-20 1:26 ` Paul Mackerras
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=cb6c89fb776248d3a2ddbcd5d3d043ed@freescale.com \
--to=kumar.gala@freescale.com \
--cc=dan@embeddededge.com \
--cc=linuxppc-dev@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.