All of lore.kernel.org
 help / color / mirror / Atom feed
From: catalin.marinas@arm.com (Catalin Marinas)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/3] arm64: Provide read/write fault information in compat signal handlers
Date: Mon, 7 Apr 2014 12:41:44 +0100	[thread overview]
Message-ID: <20140407114143.GC3360@arm.com> (raw)
In-Reply-To: <53427248.4000406@monstr.eu>

On Mon, Apr 07, 2014 at 10:39:20AM +0100, Michal Simek wrote:
> On 04/07/2014 12:19 AM, Catalin Marinas wrote:
> > --- a/arch/arm64/kernel/signal32.c
> > +++ b/arch/arm64/kernel/signal32.c
> > @@ -500,7 +500,9 @@ static int compat_setup_sigframe(struct compat_sigframe __user *sf,
> >  	__put_user_error(regs->pstate, &sf->uc.uc_mcontext.arm_cpsr, err);
> >  
> >  	__put_user_error((compat_ulong_t)0, &sf->uc.uc_mcontext.trap_no, err);
> > -	__put_user_error((compat_ulong_t)0, &sf->uc.uc_mcontext.error_code, err);
> > +	/* compat tasks expect bit 11 as WnR status bit */
> > +	__put_user_error((current->thread.fault_code & (1 << 6)) << 5,
> 
> Isn't it better to use macros for these magic values?

I was too lazy ;). I'll add some macros.

-- 
Catalin

  reply	other threads:[~2014-04-07 11:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-06 22:19 [PATCH 0/3] arm64: Provide ESR_EL1 information to user signal handlers Catalin Marinas
2014-04-06 22:19 ` [PATCH 1/3] arm64: Provide read/write fault information in compat " Catalin Marinas
2014-04-07  9:39   ` Michal Simek
2014-04-07 11:41     ` Catalin Marinas [this message]
2014-04-06 22:19 ` [PATCH 2/3] arm64: Remove the aux_context structure Catalin Marinas
2014-04-06 22:19 ` [PATCH 3/3] arm64: Expose ESR_EL1 information to user when SIGSEGV/SIGBUS Catalin Marinas

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=20140407114143.GC3360@arm.com \
    --to=catalin.marinas@arm.com \
    --cc=linux-arm-kernel@lists.infradead.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.