From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D73F63ACA5C for ; Thu, 2 Jul 2026 07:43:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.50.34 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782978196; cv=none; b=PQljTGGhAJsymLE28OrEf6NTuDoqK0gLzZqe7QJtJko+nTVlpbqc2Id/w3dXFon0judj6bYLsZwdFlACvdRmGkIJBM59z4sw+L/5j+e2zNoQ0rpaKWM+Uq0xacd4/CIMncFrZF4Dop80W9lpOsGRHnJ9sEZT1EuykHbLiP5zMHg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782978196; c=relaxed/simple; bh=nECmER+asQcfGSgwfJRP04Xye2cbrvzd9qZVkWY3ZIA=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=FnGmwCKFRy43tVtbe4TAOmbqH7yj4rKBcFR2cSe99dEgEe0xiGSsw1wDSQlgNjA218hJOKpw3ipKR8/Qx1WCMyC6TlbxzNwQchLC1ooBe38WPURkac26OBA8WX2kPhM9ZKi83EfZz6Om2PxwuTQisvRQnTOIP3UMQzDlVmz6rkM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org; spf=pass smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=IsC22Z/H; arc=none smtp.client-ip=90.155.50.34 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="IsC22Z/H" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=VMP6sSursqkqTGoYetkrjCTpwbWpq9H7rJKTasDS68I=; b=IsC22Z/HbsQMBzi0e9ZyvVBSf1 Yj5AgQY+bZYaE6jD1LK5NqyxjFDpEiW3lkOgatb1kHJjMI6x/oDJY7oWzORO4brU4TS5k9vLUjHzZ +vHgqUX7kAlmWNVoOjtdxLnTCQ5a1uJosPWN4ychDzus8uQPTTfyICP50EdnIfcCVK9qu8esHe01a cwicX4scLafW5vn+ytSj8xXZ+5Dhh2ipJ5FYp6Cjr6b9iD21fUsJ8stOeHsgavb4DzDoI2iMIkozT 3fL1PV07qzxJfF1lWhMSBwLVWVdJJVel6r5mPyZ8ZwnR8di2U01OGPK0ZcCD6v3om4wqFe/QUmYak w/wnA6Ag==; Received: from 77-249-17-252.cable.dynamic.v4.ziggo.nl ([77.249.17.252] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.99.1 #2 (Red Hat Linux)) id 1wfC4e-000000088CI-2rkq; Thu, 02 Jul 2026 07:43:04 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id 41E88300402; Thu, 02 Jul 2026 09:43:04 +0200 (CEST) Date: Thu, 2 Jul 2026 09:43:04 +0200 From: Peter Zijlstra To: Vincent Guittot Cc: mingo@redhat.com, juri.lelli@redhat.com, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de, vschneid@redhat.com, kprateek.nayak@amd.com, linux-kernel@vger.kernel.org, qyousef@layalina.io Subject: Re: [PATCH] sched/eevdf: Delayed dequeue task can't preempt Message-ID: <20260702074304.GC49951@noisy.programming.kicks-ass.net> References: <20260701164920.1571352-1-vincent.guittot@linaro.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260701164920.1571352-1-vincent.guittot@linaro.org> On Wed, Jul 01, 2026 at 06:49:20PM +0200, Vincent Guittot wrote: > Load balancing can migrate delayed dequeue tasks to even the load between > CPUs. > > sched_balance_rq() > -> detach_task() > -> deactivate_task(DEQUEUE_NOCLOCK) > -> set_task_cpu(dst_cpu) > > -> attach_task() > -> activate_task(ENQUEUE_NOCLOCK) > -> wakeup_preempt() > > A delayed task with shorter slice can be dequeued during pick_next_entity() > but then jump to preempt because eligible. Cute. Perhaps we can look at enqueue()'s place entity and determine eligibility there and complete the delayed dequeue there. But that's definitely something for after the holidays I suppose. I'll go stick it in tip/sched/core.