Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1419361 > unrolled thread

Re: [PATCH v2] x86/traps: Don't force in_interrupt() to return true in IST handlers

Started byOleg Nesterov <oleg@redhat.com>
First post2016-06-10 15:00 +0200
Last post2016-06-10 15:00 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH v2] x86/traps: Don't force in_interrupt() to return true  in IST handlers Oleg Nesterov <oleg@redhat.com> - 2016-06-10 15:00 +0200

#1419361 — Re: [PATCH v2] x86/traps: Don't force in_interrupt() to return true in IST handlers

FromOleg Nesterov <oleg@redhat.com>
Date2016-06-10 15:00 +0200
SubjectRe: [PATCH v2] x86/traps: Don't force in_interrupt() to return true in IST handlers
Message-ID<rIucy-4Ga-23@gated-at.bofh.it>
On 05/24, Andy Lutomirski wrote:
>
>  void ist_enter(struct pt_regs *regs)
>  {
>  	if (user_mode(regs)) {
> @@ -109,13 +115,7 @@ void ist_enter(struct pt_regs *regs)
>  		rcu_nmi_enter();
>  	}
>  
> -	/*
> -	 * We are atomic because we're on the IST stack; or we're on
> -	 * x86_32, in which case we still shouldn't schedule; or we're
> -	 * on x86_64 and entered from user mode, in which case we're
> -	 * still atomic unless ist_begin_non_atomic is called.
> -	 */
> -	preempt_count_add(HARDIRQ_OFFSET);
> +	preempt_disable();

off-topic question,

perhaps it makes sense to remove another preempt_disable/preempt_enable_no_resched
in do_int3() and do_debug() ?

They were added by d99e1bd175f4291ddb6e62b22bb5bdbe3976389a ("x86/entry/traps: Refactor
preemption and interrupt flag handling") and afaics for no reason.

Oleg.

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web