linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: u.kleine-koenig@pengutronix.de (Uwe Kleine-König)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: v7-M: Use ret_to_user_from_irq in PendSV handler
Date: Mon, 26 Oct 2015 08:50:59 +0100	[thread overview]
Message-ID: <20151026075059.GV4931@pengutronix.de> (raw)
In-Reply-To: <1445818252-13175-1-git-send-email-ezequiel@vanguardiasur.com.ar>

On Sun, Oct 25, 2015 at 09:10:52PM -0300, Ezequiel Garcia wrote:
> The PendSV handler calls v7m_exception_entry which
> disables IRQs. Therefore, since IRQs are already disabled,
> the PendSV handler can return using ret_to_user_from_irq.
> 
> Signed-off-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Looks right. How did you notice this?

Acked-by: Uwe Kleine-K?nig <u.kleine-koenig@pengutronix.de>

Best regards
Uwe

> ---
> Tested on a NXP LPC43xx platform.
> 
>  arch/arm/kernel/entry-v7m.S | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/arm/kernel/entry-v7m.S b/arch/arm/kernel/entry-v7m.S
> index b6c8bb9315e7..907534f97053 100644
> --- a/arch/arm/kernel/entry-v7m.S
> +++ b/arch/arm/kernel/entry-v7m.S
> @@ -88,7 +88,7 @@ __pendsv_entry:
>  	@ execute the pending work, including reschedule
>  	get_thread_info tsk
>  	mov	why, #0
> -	b	ret_to_user
> +	b	ret_to_user_from_irq
>  ENDPROC(__pendsv_entry)
>  
>  /*
> -- 
> 2.5.2
> 
> 

-- 
Pengutronix e.K.                           | Uwe Kleine-K?nig            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

  reply	other threads:[~2015-10-26  7:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-26  0:10 [PATCH] ARM: v7-M: Use ret_to_user_from_irq in PendSV handler Ezequiel Garcia
2015-10-26  7:50 ` Uwe Kleine-König [this message]
2015-10-26 13:01   ` Ezequiel Garcia

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=20151026075059.GV4931@pengutronix.de \
    --to=u.kleine-koenig@pengutronix.de \
    --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 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).