From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DF56BECDFB8 for ; Tue, 24 Jul 2018 12:26:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A464520880 for ; Tue, 24 Jul 2018 12:26:32 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A464520880 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388624AbeGXNcp (ORCPT ); Tue, 24 Jul 2018 09:32:45 -0400 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:50226 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388264AbeGXNco (ORCPT ); Tue, 24 Jul 2018 09:32:44 -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 1352780D; Tue, 24 Jul 2018 05:26:30 -0700 (PDT) Received: from e108498-lin.Emea.Arm.com (e108498-lin.emea.arm.com [10.4.13.130]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id EECB33F6A8; Tue, 24 Jul 2018 05:26:25 -0700 (PDT) From: Quentin Perret To: peterz@infradead.org, rjw@rjwysocki.net, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org Cc: gregkh@linuxfoundation.org, mingo@redhat.com, dietmar.eggemann@arm.com, morten.rasmussen@arm.com, chris.redpath@arm.com, patrick.bellasi@arm.com, valentin.schneider@arm.com, vincent.guittot@linaro.org, thara.gopinath@linaro.org, viresh.kumar@linaro.org, tkjos@google.com, joel@joelfernandes.org, smuckle@google.com, adharmap@quicinc.com, skannan@quicinc.com, pkondeti@codeaurora.org, juri.lelli@redhat.com, edubezval@gmail.com, srinivas.pandruvada@linux.intel.com, currojerez@riseup.net, javi.merino@kernel.org, quentin.perret@arm.com Subject: [PATCH v5 13/14] OPTIONAL: arch_topology: Start Energy Aware Scheduling Date: Tue, 24 Jul 2018 13:25:20 +0100 Message-Id: <20180724122521.22109-14-quentin.perret@arm.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180724122521.22109-1-quentin.perret@arm.com> References: <20180724122521.22109-1-quentin.perret@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Energy Aware Scheduling (EAS) starts when the scheduling domains are built if the Energy Model (EM) is present. However, in the typical case of Arm/Arm64 systems, the EM is provided after the scheduling domains are first built at boot time, which results in EAS staying disabled. Fix this issue by re-building the scheduling domain from the arch topology driver, once CPUfreq is up and running and the asymmetry in CPU capacities has been detected. Cc: Greg Kroah-Hartman Signed-off-by: Quentin Perret --- drivers/base/arch_topology.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/base/arch_topology.c b/drivers/base/arch_topology.c index e7cb0c6ade81..5b9f107f2e4a 100644 --- a/drivers/base/arch_topology.c +++ b/drivers/base/arch_topology.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include #include @@ -247,6 +248,7 @@ static void parsing_done_workfn(struct work_struct *work) cpufreq_unregister_notifier(&init_cpu_capacity_notifier, CPUFREQ_POLICY_NOTIFIER); free_cpumask_var(cpus_to_visit); + rebuild_sched_domains(); } #else -- 2.18.0