From mboxrd@z Thu Jan 1 00:00:00 1970 From: Juri Lelli Subject: Re: [PATCH] cpufreq: schedutil: rate limits for SCHED_DEADLINE Date: Fri, 9 Feb 2018 11:53:05 +0100 Message-ID: <20180209105305.GD12979@localhost.localdomain> References: <1518109302-8239-1-git-send-email-claudio@evidence.eu.com> <20180209035143.GX28462@vireshk-i7> <197c26ba-c2a6-2de7-dffa-5b884079f746@evidence.eu.com> <11598161.veS9VGWB8G@aspire.rjw.lan> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <11598161.veS9VGWB8G@aspire.rjw.lan> Sender: linux-kernel-owner@vger.kernel.org To: "Rafael J. Wysocki" Cc: Claudio Scordino , Viresh Kumar , Peter Zijlstra , Ingo Molnar , "Rafael J . Wysocki" , Patrick Bellasi , Dietmar Eggemann , Morten Rasmussen , Vincent Guittot , Todd Kjos , Joel Fernandes , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org List-Id: linux-pm@vger.kernel.org Hi, On 09/02/18 11:36, Rafael J. Wysocki wrote: > On Friday, February 9, 2018 9:02:34 AM CET Claudio Scordino wrote: > > Hi Viresh, > > > > Il 09/02/2018 04:51, Viresh Kumar ha scritto: > > > On 08-02-18, 18:01, Claudio Scordino wrote: > > >> When the SCHED_DEADLINE scheduling class increases the CPU utilization, > > >> we should not wait for the rate limit, otherwise we may miss some deadline. > > >> > > >> Tests using rt-app on Exynos5422 have shown reductions of about 10% of deadline > > >> misses for tasks with low RT periods. > > >> > > >> The patch applies on top of the one recently proposed by Peter to drop the > > >> SCHED_CPUFREQ_* flags. > > >> > > [cut] > > > > > > > > > Is it possible to (somehow) check here if the DL tasks will miss > > > deadline if we continue to run at current frequency? And only ignore > > > rate-limit if that is the case ? Isn't it always the case? Utilization associated to DL tasks is given by what the user said it's needed to meet a task deadlines (admission control). If that task wakes up and we realize that adding its utilization contribution is going to require a frequency change, we should _theoretically_ always do it, or it will be too late. Now, user might have asked for a bit more than what strictly required (this is usually the case to compensate for discrepancies between theory and real world, e.g. hw transition limits), but I don't think there is a way to know "how much". :/ Thanks, - Juri > > > > I need to think further about it. > > That would be my approach FWIW. > > Increasing the frequency beyond what is necessary means wasting energy > in any case. > > Thanks, > Rafael >