From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1427787AbcBSPBM (ORCPT ); Fri, 19 Feb 2016 10:01:12 -0500 Received: from mail-oi0-f52.google.com ([209.85.218.52]:34485 "EHLO mail-oi0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1424800AbcBSPBK (ORCPT ); Fri, 19 Feb 2016 10:01:10 -0500 Subject: Re: [PATCH V3 2/2] sched: idle: IRQ based next prediction for idle period To: "Rafael J. Wysocki" References: <1455637383-14412-1-git-send-email-daniel.lezcano@linaro.org> <1455637383-14412-2-git-send-email-daniel.lezcano@linaro.org> <56C59C32.1000903@linaro.org> Cc: Nicolas Pitre , Thomas Gleixner , Peter Zijlstra , "linux-pm@vger.kernel.org" , Linux Kernel Mailing List , Vincent Guittot From: Daniel Lezcano Message-ID: <56C72E31.9010707@linaro.org> Date: Fri, 19 Feb 2016 15:01:05 +0000 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 02/18/2016 07:57 PM, Rafael J. Wysocki wrote: > On Thu, Feb 18, 2016 at 11:25 AM, Daniel Lezcano > wrote: >> On 02/17/2016 11:21 PM, Rafael J. Wysocki wrote: >> >> [ ... ] >> >>>>> Reviewed-by: Nicolas Pitre >>>> >>>> >>>> Well, I'm likely overlooking something, but how is this going to be >>>> hooked up to the code in idle.c? >>> >>> >>> My somewhat educated guess is that sched_idle() in your patch is >>> intended to replace cpuidle_idle_call(), right? >> >> >> Well, no. I was planning to first have it to use a different code path as >> experimental code in order to focus improving the accuracy of the prediction >> and then merge or replace cpuidle_idle_call() with sched_idle(). > > In that case, what about making it a proper cpuidle governor that > people can test and play with in a usual way? Then it may potentially > benefit everybody and not just your experimental setup and you may get > coverage on systems you have no access to normally. > > There is some boilerplate code to add for this purpose, but that's not > that bad IMO. Hi Rafael, sorry for the delay in the responses. Actually, adding a new governor is precisely what I would like to avoid because the objective is the scheduler acts as the governor. Here, it is the 'predictor' and the API to enter an idle state conforming the idle duration and the latency constraint. Concerning the testing, it is quite easy to switch from idle_sched to 'menu' via on sched_debug or whatever option we want to add. > > So I'm still unsure why you want to replace cpuidle_idle_call() with > sched_idle(). Is there anything wrong with it that it needs to be > replaced? I don't want to replace cpuidle_idle_call() with sched_idle(). How we integrate the API is something I would like to discuss with another patchset focused in this integration only. For reference: https://lkml.org/lkml/2016/1/12/530 -- Daniel -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog