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


Groups > linux.kernel > #1257658

Re: [RFC PATCH v2 2/3] restartable sequences: x86 ABI

From Peter Zijlstra <peterz@infradead.org>
Newsgroups linux.kernel
Subject Re: [RFC PATCH v2 2/3] restartable sequences: x86 ABI
Date 2015-10-28 06:10 +0100
Message-ID <qor9M-6GJ-7@gated-at.bofh.it> (permalink)
References <qomjM-3hW-9@gated-at.bofh.it> <qomjM-3hW-15@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Oct 27, 2015 at 04:57:05PM -0700, Paul Turner wrote:
> +static void rseq_sched_out(struct preempt_notifier *pn,
> +			   struct task_struct *next)
> +{
> +	set_thread_flag(TIF_NOTIFY_RESUME);
> +}
>  
>  static __read_mostly struct preempt_ops rseq_preempt_ops = {
>  	.sched_in = rseq_sched_in_nop,
> -	.sched_out = rseq_sched_out_nop,
> +	.sched_out = rseq_sched_out,
>  };

Since we're unconditionally setting this TIF flag for these tasks, can't
we introduce something similar to the (contested) TIF_NOHZ_FULL thing
which is kept on the task indefinitely.

That avoids having the preempt notifiers and this atomic op in the
schedule path.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC PATCH v2 2/3] restartable sequences: x86 ABI Paul Turner <commonly@gmail.com> - 2015-10-28 01:00 +0100
  Re: [RFC PATCH v2 2/3] restartable sequences: x86 ABI Peter Zijlstra <peterz@infradead.org> - 2015-10-28 06:10 +0100
    Re: [RFC PATCH v2 2/3] restartable sequences: x86 ABI Paul Turner <commonly@gmail.com> - 2015-10-28 06:30 +0100

csiph-web