lkml.org 
[lkml]   [2020]   [Jun]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH v2] sched_pair_cpu: Introduce scheduler task pairing system call
----- On Jun 25, 2020, at 10:56 AM, Mathieu Desnoyers mathieu.desnoyers@efficios.com wrote:

> ----- On Jun 24, 2020, at 3:50 PM, Peter Zijlstra peterz@infradead.org wrote:
>
>> On Wed, Jun 24, 2020 at 02:31:33PM -0400, Mathieu Desnoyers wrote:
>>
> [...]
>> The other alternative is using a preempt_notifier for the worker I
>> suppose.
>
[...]
>>
>> preempt_notifier could work here too I suppose, install it on yourself
>> when you do the pear syscall and take it away again when you're finished
>> with it.

The issue I currently have with preempt notifiers is that I need to
send an IPI from a sched_out notifier, which has interrupts off and
hold the rq lock. smp_call_function_single() warns due to irq off, and
indeed it triggers deadlocks.

Before using preempt notifiers, I was touching the "prev" task after
irqs were reenabled and rq lock was released, which allowed me to
send an IPI from that context.

Any thoughts on how to best solve this ?

Thanks,

Mathieu

--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

\
 
 \ /
  Last update: 2020-06-25 18:35    [W:0.091 / U:0.440 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site