From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Chris Metcalf <cmetcalf@tilera.com>
Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: linux-next: manual merge of the tile tree with Linus' tree
Date: Tue, 10 Apr 2012 10:34:52 +1000 [thread overview]
Message-ID: <20120410103452.0783213f251d0c8302b4eec2@canb.auug.org.au> (raw)
[-- Attachment #1: Type: text/plain, Size: 1703 bytes --]
Hi Chris,
Today's linux-next merge of the tile tree got a conflict in
arch/tile/kernel/single_step.c between commit cdd8e16feba8 ("arch/tile:
return SIGBUS for addresses that are unaligned AND invalid") from Linus'
tree and commit 25c5acbdcc06 ("arch/tile: support building big-endian
kernel") from the tile tree.
Just context changes. I fixed it up (see below) and can carry the fix as
necessary.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
diff --cc arch/tile/kernel/single_step.c
index 9efbc13,8935deb..0000000
--- a/arch/tile/kernel/single_step.c
+++ b/arch/tile/kernel/single_step.c
@@@ -153,28 -153,6 +153,25 @@@ static tile_bundle_bits rewrite_load_st
if (((unsigned long)addr % size) == 0)
return bundle;
+ /*
+ * Return SIGBUS with the unaligned address, if requested.
+ * Note that we return SIGBUS even for completely invalid addresses
+ * as long as they are in fact unaligned; this matches what the
+ * tilepro hardware would be doing, if it could provide us with the
+ * actual bad address in an SPR, which it doesn't.
+ */
+ if (unaligned_fixup == 0) {
+ siginfo_t info = {
+ .si_signo = SIGBUS,
+ .si_code = BUS_ADRALN,
+ .si_addr = addr
+ };
+ trace_unhandled_signal("unaligned trap", regs,
+ (unsigned long)addr, SIGBUS);
+ force_sig_info(info.si_signo, &info, current);
+ return (tilepro_bundle_bits) 0;
+ }
+
- #ifndef __LITTLE_ENDIAN
- # error We assume little-endian representation with copy_xx_user size 2 here
- #endif
/* Handle unaligned load/store */
if (mem_op == MEMOP_LOAD || mem_op == MEMOP_LOAD_POSTINCR) {
unsigned short val_16;
[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]
next reply other threads:[~2012-04-10 0:35 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-10 0:34 Stephen Rothwell [this message]
-- strict thread matches above, loose matches on Subject: below --
2012-04-10 0:38 Stephen Rothwell
2012-04-02 0:46 Stephen Rothwell
2012-04-02 0:37 Stephen Rothwell
2012-03-14 0:10 Stephen Rothwell
2012-03-14 0:56 ` Chris Metcalf
2011-03-17 23:34 Stephen Rothwell
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=20120410103452.0783213f251d0c8302b4eec2@canb.auug.org.au \
--to=sfr@canb.auug.org.au \
--cc=cmetcalf@tilera.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@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®