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


Groups > linux.kernel > #1202899

Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq

From Peter Zijlstra <peterz@infradead.org>
Newsgroups linux.kernel
Subject Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq
Date 2015-08-07 18:50 +0200
Message-ID <pUT0e-5e5-21@gated-at.bofh.it> (permalink)
References (5 earlier) <oVdu9-5W5-1@gated-at.bofh.it> <oXRnt-2Nq-33@gated-at.bofh.it> <pUNxw-5E5-31@gated-at.bofh.it> <pUNQS-6fD-19@gated-at.bofh.it> <pUT0d-5e5-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, Aug 07, 2015 at 09:41:31AM -0700, Christoph Hellwig wrote:
> On Fri, Aug 07, 2015 at 01:14:15PM +0200, Peter Zijlstra wrote:
> > On that, we cannot convert completions to swait. Because swait wake_all
> > must not happen from IRQ context, and complete_all() typically is used
> > from just that.
> 
> If swait queues aren't useable from IRQ context they will be fairly
> useless.  What's the problem with making them irq safe?

Its just the swait_wake_all() that is not. The entire purpose of them
was to have something that allows bounded execution (RT and all).

Since you can have unbounded numbers of tasks waiting on a waitqueue
(well, reality has bounds of course, like total memory available etc..)
a wake_all() can end up being many many wake_process() calls.

We've had this be a problem in RT.

So the proposed swait_wake_all() requires being called from task
context, such that it can drop the lock (and IRQ disable) after every
wakeup, and thereby guarantee that higher priority things will not
experience undue latencies.
--
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

Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq Peter Zijlstra <peterz@infradead.org> - 2015-08-07 13:00 +0200
  Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq Peter Zijlstra <peterz@infradead.org> - 2015-08-07 13:20 +0200
    Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq Christoph Hellwig <hch@infradead.org> - 2015-08-07 18:50 +0200
      Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq Peter Zijlstra <peterz@infradead.org> - 2015-08-07 18:50 +0200
        Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq Christoph Hellwig <hch@infradead.org> - 2015-08-09 08:50 +0200
    Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu->wq Thomas Gleixner <tglx@linutronix.de> - 2015-08-17 22:40 +0200

csiph-web