From patchwork Wed Aug 11 11:58:40 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 495163 Delivered-To: patch@linaro.org Received: by 2002:a05:6638:396:0:0:0:0 with SMTP id y22csp4900005jap; Wed, 11 Aug 2021 05:06:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwe01j+9YuUKulojkC9LeJGcCMBdSZk/4IEHhSL3BS0FQ+GIVhrrBpuI9Ivz4/Yh/elCaV9 X-Received: by 2002:a05:6402:b56:: with SMTP id bx22mr11051305edb.285.1628683586726; Wed, 11 Aug 2021 05:06:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628683586; cv=none; d=google.com; s=arc-20160816; b=JTxp4ypl1xOG5j70uA4CiJlkX6WKU4O61SLUqwr8LAZ279za8fvC9PN0AHB6OhcsEU TLd2JjNKfakG9jdf0sVZKoZMccO5Dg0XadtyxrfjYmyW8gnZekZRDdI8FJbJDhbkhdTO KufDbEm9Q/hGBtpEkxlH9RDFnEX+EOmRtpaQVSXNnJyCwRIViINvFYI/YGxyGcDknRVc HY8dFw5eHQ+uuRLDDrxZoVg3zXz1EG4nnu7l9pXKKH3qWO8xh2Uj2XXAobK+xKGAtX+B SQjKWQ/q0s15gFeyhLo05nGS/QrKd9lxLHm8UMQxPG1Pe7Sav9XNi2j4evpAjU+lvsq/ fPyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=rjqWWeUctts4V9t7V1TVNNowsy6/ZHXWitYbSRTUDSc=; b=P6MBREDSM6HYhIh+E5bksWdghDqQmbZ+bY0g/rG+XEEWqYVtULxUarAZcdrJiAkWEV PMJ2/NOxX0cailkWVQnI6JyCkAGLpbxZhwL0ePwHW7r4ebQfpcGLtJSDezfxU+JtREQq qGt0SH33gbojiiwOhnDpM63I8Vlr+seKdq8P5piwz4ikTJPEmXsC2JjbjK1pTuZlmBms dCINfGhDBKclmNahxUlQG3eeTB4uQzukiYihMCCTXh7H2l+jroEOrnJWHzTStuj2QEpn VywPeLDujGo//PPotwaLmtfwZqt8T/eR/5Rc+ETMKpGe8qpIfr3TPO8c5ZjnwvmrPK23 rMLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="GDcrWYD/"; spf=pass (google.com: domain of linux-pm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-pm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w11si24410170edd.252.2021.08.11.05.06.26; Wed, 11 Aug 2021 05:06:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-pm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="GDcrWYD/"; spf=pass (google.com: domain of linux-pm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-pm-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237541AbhHKMGp (ORCPT + 7 others); Wed, 11 Aug 2021 08:06:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50832 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237537AbhHKMGo (ORCPT ); Wed, 11 Aug 2021 08:06:44 -0400 Received: from mail-pl1-x635.google.com (mail-pl1-x635.google.com [IPv6:2607:f8b0:4864:20::635]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4C2EFC061765 for ; Wed, 11 Aug 2021 05:06:21 -0700 (PDT) Received: by mail-pl1-x635.google.com with SMTP id l11so2407722plk.6 for ; Wed, 11 Aug 2021 05:06:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=rjqWWeUctts4V9t7V1TVNNowsy6/ZHXWitYbSRTUDSc=; b=GDcrWYD/meMGdmLUcwRP+ZSS1yHCTBfETzpliLc0BUmSRq1VDCDFIdqogWXghBAXhy GGpoLbqpYOnvSOL70DilcmuBjmb7CQV+pUCwpHHftCTKSy30gAZv+ksKZPLnUACmonjQ t5Out2pAzeJpd3jQEunHadrC0ZZVPadZyLS+UfVDzTIOC+UxnZHvJwYDK19eVfvQQh44 az45xkP3tRAD8a4eJIRfA2Qq83zJ1pab59IGeIUCUIBkrlU1fsm/HREzVPTGgW/JLLaB sdIHBvnVWgFslF2UDmdbia8Rmnp2Hm/jkH6/IkgTv37+QdCX35BzvaujNkenzDVcAfu3 ADOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rjqWWeUctts4V9t7V1TVNNowsy6/ZHXWitYbSRTUDSc=; b=W2Vn/y2JL8bwxn0DkOQTbSnoOY3sM/POugfTnIaIeVmHLsESX8h86kTi4Loc2ANvON i4xDMt+eQ2pvN9sFDBco3hMtjaypzZ68ygi5SXeZmQ44+N3cnRh5HXVYiQe3LThTYC3T 99JgahBoKu2jOCA/0pLsTWpHfXP0GipZLn8phAN8de1fi+HBmJAmQdjq+lzMLy0RGoGW XUVPqAXehnWDod+JhsQ5lRbc9CgRIi7Nj2ZubNDzRSwzThjpw3bF6cGT8GYcLahnvjX0 NwdDM1zP5BrPPIA3xhfQ6DizBLNlcAjP+zYyuAQeKA1zsDFQSSw8vXx11VmS7ILSJ5af qQPQ== X-Gm-Message-State: AOAM530yZkdglNmzVgE+IfPf+VQtSwKX25F4GfbKBQ9zzKcMrz9xQtx/ HysPWSqxvBwToVeIjC9OxO34zbjnkmY9oA== X-Received: by 2002:a65:5bc9:: with SMTP id o9mr107174pgr.24.1628683580894; Wed, 11 Aug 2021 05:06:20 -0700 (PDT) Received: from localhost ([122.172.201.85]) by smtp.gmail.com with ESMTPSA id s31sm33016791pgm.27.2021.08.11.05.06.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 11 Aug 2021 05:06:20 -0700 (PDT) From: Viresh Kumar To: Rafael Wysocki , Viresh Kumar Cc: linux-pm@vger.kernel.org, Vincent Guittot , Lukasz Luba , Quentin Perret , linux-kernel@vger.kernel.org Subject: [PATCH V2 2/9] cpufreq: dt: Use auto-registration for energy model Date: Wed, 11 Aug 2021 17:28:40 +0530 Message-Id: <8c7478a9aa26740448539e9fdaba22789cb28287.1628682874.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.31.1.272.g89b43f80a514 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org Set the newly added .register_em() callback with cpufreq_register_em_with_opp() to automatically register with the EM core. Signed-off-by: Viresh Kumar --- drivers/cpufreq/cpufreq-dt.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) -- 2.31.1.272.g89b43f80a514 diff --git a/drivers/cpufreq/cpufreq-dt.c b/drivers/cpufreq/cpufreq-dt.c index ece52863ba62..8fcaba541539 100644 --- a/drivers/cpufreq/cpufreq-dt.c +++ b/drivers/cpufreq/cpufreq-dt.c @@ -143,8 +143,6 @@ static int cpufreq_init(struct cpufreq_policy *policy) cpufreq_dt_attr[1] = &cpufreq_freq_attr_scaling_boost_freqs; } - dev_pm_opp_of_register_em(cpu_dev, policy->cpus); - return 0; out_clk_put: @@ -184,6 +182,7 @@ static struct cpufreq_driver dt_cpufreq_driver = { .exit = cpufreq_exit, .online = cpufreq_online, .offline = cpufreq_offline, + .register_em = cpufreq_register_em_with_opp, .name = "cpufreq-dt", .attr = cpufreq_dt_attr, .suspend = cpufreq_generic_suspend,