Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp621053imm; Thu, 6 Sep 2018 07:41:23 -0700 (PDT) X-Google-Smtp-Source: ANB0VdY9S/CdvWsXRs7g15GqghPKv/8mL6cJwXNdlJ653TIR+VhZ3uQKbsUAR3HGtdlZKuYmCTCj X-Received: by 2002:a63:b44c:: with SMTP id n12-v6mr3061691pgu.337.1536244883436; Thu, 06 Sep 2018 07:41:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536244883; cv=none; d=google.com; s=arc-20160816; b=PpRp+nzf7eyXWnW4zoXFh0yj5NAKNL9Qb5XfM/PA3cIjUPgJbdPuGuJZO0MrBh3xcz yfS7TLp9aaOet+6aFQ/A+scvj7U7YpcNmSR93U5vKqTzb07P4WWLB+slLh/zpfH8Vktj 9XfSf1HB6s0a+emktXy3B1n8kr86yNcqiR2s/3nQM5suOZGTznxzZwzMySqXbxAjbEEi 2GKvxe0QQNe0N47cJp/iEPQYO+c1m/cPsdj9+8Ns/jSSvr/YG+dv417me38o3HgMNapi ncM/kUDvHbjavRaMes2Hip1zD1kK+C+kVjXIIyJrHXslfgvKLG1sgUPE+Xnfhee9UpzK vIMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=UOCcNopnxkLlV7Q/Tp7eE/uK3LVAttxDyF7bazSe3AI=; b=OeqxhlwB2KoOOnxhcErF/W2YIqN2/XdG5YT2Yl8+byg3HTgBHWIHQc1mq84XzGvsuy mURmR5Q4BUgPcq2FpwDUruOKrIOqE1eAHJzBWGsENai5P4wg3RiFKzcwVN+GBf2/D8UZ 0PjmWM39cuAfb8OCHuJI0os91kWwnmeKOO2xSEj9mN935pKgDrjtZ2z8FX1n8g82IDlk j2wTRb0TCQEvrqsZyhjdHoSW3dQh+hUH3wbCCnIUadcWpEdgegCbwWA0kNuk4Q688QHm XPIMlAszVSUBddpBIkFHVbjZpGvBzB4IMe+ATMJOxyHuygYAn6gZyLOfjOlg8HiXWMYm jGLQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n28-v6si5367475pfg.127.2018.09.06.07.41.04; Thu, 06 Sep 2018 07:41:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730142AbeIFTOm (ORCPT + 99 others); Thu, 6 Sep 2018 15:14:42 -0400 Received: from foss.arm.com ([217.140.101.70]:46780 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729735AbeIFTOl (ORCPT ); Thu, 6 Sep 2018 15:14:41 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 08B4F7A9; Thu, 6 Sep 2018 07:38:50 -0700 (PDT) Received: from queper01-lin (queper01-lin.Emea.Arm.com [10.4.13.27]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E54FC3F614; Thu, 6 Sep 2018 07:38:45 -0700 (PDT) Date: Thu, 6 Sep 2018 15:38:44 +0100 From: Quentin Perret To: "Rafael J. Wysocki" Cc: Peter Zijlstra , "Rafael J. Wysocki" , Linux Kernel Mailing List , Linux PM , Greg Kroah-Hartman , Ingo Molnar , Dietmar Eggemann , Morten Rasmussen , Chris Redpath , Patrick Bellasi , Valentin Schneider , Vincent Guittot , Thara Gopinath , Viresh Kumar , Todd Kjos , Joel Fernandes , Steve Muckle , adharmap@codeaurora.org, Saravana Kannan , Pavan Kondeti , Juri Lelli , Eduardo Valentin , Srinivas Pandruvada , currojerez@riseup.net, Javi Merino Subject: Re: [PATCH v6 13/14] sched/topology: Make Energy Aware Scheduling depend on schedutil Message-ID: <20180906143842.xlxcg5notwdaflww@queper01-lin> References: <20180820094420.26590-1-quentin.perret@arm.com> <20180820094420.26590-14-quentin.perret@arm.com> <20180904105906.t5i7twyyt2omc45b@queper01-lin> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20171215 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Rafael, On Thursday 06 Sep 2018 at 11:18:55 (+0200), Rafael J. Wysocki wrote: > I'm not a particular fan of notifiers to be honest and you don't need > to add an extra chain just in order to be able to register a callback > from a single user. Right. I agree there are alternatives to using notifiers. I used them because they're existing infrastructure, and because they let me do what I want without too much troubles, which are two important points. > That can be achieved with a single callback > pointer too, but also you could just call a function exported by the > scheduler directly from where in the cpufreq code it needs to be > called. Are you thinking about something comparable to what is done in cpufreq_add_update_util_hook() (kernel/sched/cpufreq.c) for example ? That would probably have the same drawback as my current implementation, that is that the scheduler is notified of _all_ governor changes, not only changes to/from sugov although this is the only thing we care about for EAS. We could also hook things in sugov_start & sugov_stop directly, and keep all changes into the scheduler ... That is slightly harder to implement on the scheduler topology side, though. Thoughts ? > > Also, is there any hope that the 12 first patches could make it in 4.20 > > on their own ? Or is it already too late ? > > I'm walking through them right now, albeit somewhat slowly due to > various distractions, so we'll see. Thanks ! Quentin