From: David Miller <davem@davemloft.net>
To: sparclinux@vger.kernel.org
Subject: Re: [sparc32] userland unaligned access
Date: Thu, 20 Aug 2020 22:51:22 +0000 [thread overview]
Message-ID: <20200820.155122.2263405333608231817.davem@davemloft.net> (raw)
In-Reply-To: <20200820193612.GG1236603@ZenIV.linux.org.uk>
From: Al Viro <viro@zeniv.linux.org.uk>
Date: Thu, 20 Aug 2020 20:36:12 +0100
> We have
> asmlinkage void user_unaligned_trap(struct pt_regs *regs, unsigned int insn)
> {
> enum direction dir;
>
> if(!(current->thread.flags & SPARC_FLAG_UNALIGNED) ||
> (((insn >> 30) & 3) != 3))
> goto kill_user;
>
> there, followed by some work on emulating the insn. So while the default
> behaviour is to hit the process with SIGBUS, it can overridden by setting
> SPARC_FLAG_UNALIGNED in current->thread.flags. Fair enough, but... Just
> what could possibly set that flag?
>
> That stuff had been introduced back in 2.1.9 and even there (or through
> the 2.2, etc.) I don't see anything that would ever set it.
>
> Am I missing something, or had it really been dead code all along?
Relic from the SunOS and/or Solaris syscall emulation probably.
next prev parent reply other threads:[~2020-08-20 22:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-20 19:36 [sparc32] userland unaligned access Al Viro
2020-08-20 22:51 ` David Miller [this message]
2020-08-20 23:37 ` Al Viro
2020-08-20 23:47 ` David Miller
2020-08-21 0:00 ` Al Viro
2020-08-21 0:19 ` David Miller
2020-08-21 13:02 ` Steven Sistare
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=20200820.155122.2263405333608231817.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=sparclinux@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 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.