From patchwork Mon Feb 26 05:09:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 129550 Delivered-To: patch@linaro.org Received: by 10.46.66.2 with SMTP id p2csp3230839lja; Sun, 25 Feb 2018 21:10:35 -0800 (PST) X-Google-Smtp-Source: AH8x224A0FE8bvBnlPVgHbcJKEsLLb5s2KQp1CFLod4UTh04Zc2QZCHTvvbJjuaKePvRsHam37lp X-Received: by 10.98.89.156 with SMTP id k28mr9254052pfj.130.1519621835290; Sun, 25 Feb 2018 21:10:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519621835; cv=none; d=google.com; s=arc-20160816; b=KCWRS0Xe9TC/9oBxS/hKaBsOIcqA9KKXW8ChGYh2n6ScPZ8AIJ0wvXasjrVSgSjTk5 0Qb4rSTvETkT8wKovJFAbpALcanJbEweQz6Y+a58VLqeMyw1hufd7ibatC3pwVszphY3 pVtf+eIaJuzkYZ5tDkqoJ0EX59dkfprNTHZA22nz+S9yxdACSGMXY0usjLbNPaRRhnNg 4SF+trPIc7vJ4w9PHlOZJFS+5loLsFThL136pOzQSR/JFvaj2HsU4cjQEDPQ26vyTxZ0 GaH0zJxh3JGvxpF9Ar/e+4Msx+p8eVE4ZVHnpxp7HLo/FUxb7NWBRcvJQQ3kvyP3P7sx y30g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=Ff3C3HNXm7RhCecxML+vCKakOrbNexctLR5loscC010=; b=q1MGaCTfBk2sZgZTGhhV37CbMJXcSKGloJt3vh43YMyT3R3FFXOgdTtZ0ouOwc1M40 b8KPPThDUSZ55zH2kQi1RRS+P1zEqAwGiayaIWkvYfgPuxdj2v7l2suUqwGZuzJoZZEA VlIfv51L61a3lK+DoCGsSjmv/rE4blSKQuNArV6PnY6GTvn75y24eJP+LJGbmlDP+LRw 7sdT2rBbXC0LFSUa+vCl1oxJc+eAGlcwEpESgkxNywi89z5deXYJjxAh6hdBKNJLtdBo 0WZ1eJTKlMd6ZDauS/6v0R4Sw1YsuT9LwfevVSHw5sj2O3Tcb/RQxF1TUJ7foF6yO0Y4 NlKQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aQnhbOxp; spf=pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id h32-v6si6199354pld.217.2018.02.25.21.10.35; Sun, 25 Feb 2018 21:10:35 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aQnhbOxp; spf=pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 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 S1751094AbeBZFKe (ORCPT + 11 others); Mon, 26 Feb 2018 00:10:34 -0500 Received: from mail-pl0-f67.google.com ([209.85.160.67]:42176 "EHLO mail-pl0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750929AbeBZFKd (ORCPT ); Mon, 26 Feb 2018 00:10:33 -0500 Received: by mail-pl0-f67.google.com with SMTP id 31so8649879ple.9 for ; Sun, 25 Feb 2018 21:10:33 -0800 (PST) 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 :in-reply-to:references; bh=Ff3C3HNXm7RhCecxML+vCKakOrbNexctLR5loscC010=; b=aQnhbOxp2IstPYerDwKIUTlA5B9irX06HGyL0Lyh7KPRLhZp4gEpds2ploH7cHhUlQ LU63tGVfctFvg5FIhCzLT+KPEO7GHm0S4k21qYdDXh9gQx3jevqnPsSxytcg01a3/v5M 7LPpk3leQPNJuu9hA/u3EPZTUs2JaZf7YbpP0= 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:in-reply-to:references; bh=Ff3C3HNXm7RhCecxML+vCKakOrbNexctLR5loscC010=; b=UwpQ/wB6W+uMvdrXE4bVQCZds7KuvRN7nie6kBT4tyPQX5O0FXwT4KNjR9OxLi7Duk n/hQceWINkcEB2YOYHxa4ezZAuDSqWWxkHKc/31PzZVRpHSxx4I8i8j/UN61qOMvUaSx rheMs6sOgTzPttcQIsJHuMGT2hznyWAq4WNu9R0KLogNFoywXeZlhOtEGdxRYKmUuDo+ Ru2v2QYVl2JZaPohbDPh7OeItbAhJLnlv+OSJQUV0GZ2u26OCCM6gw/eMGX8ZO7RnNYT FNoRfXaZ4ru3bubXpMiQzn3/zqzg2q6kU11ieFC3MN0zTWkWrvf9sirAAygXeBAT6ts4 CO8g== X-Gm-Message-State: APf1xPAA9AeAh5A4GNZWlHyegDO8iS31E3/YBggZAMqkfaVvucSRCkYE TNRRvuhjRRSr0KoywV/coIxk/Q== X-Received: by 2002:a17:902:b101:: with SMTP id q1-v6mr9508390plr.287.1519621833487; Sun, 25 Feb 2018 21:10:33 -0800 (PST) Received: from localhost ([122.172.92.38]) by smtp.gmail.com with ESMTPSA id n81sm17865703pfk.152.2018.02.25.21.10.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 25 Feb 2018 21:10:33 -0800 (PST) From: Viresh Kumar To: Rafael Wysocki Cc: Viresh Kumar , linux-pm@vger.kernel.org, Vincent Guittot Subject: [PATCH 24/27] cpufreq: sparc: Don't validate the frequency table twice Date: Mon, 26 Feb 2018 10:39:07 +0530 Message-Id: X-Mailer: git-send-email 2.15.0.194.g9af6a3dea062 In-Reply-To: References: In-Reply-To: References: Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org The cpufreq core is already validating the CPU frequency table after calling the ->init() callback of the cpufreq drivers and the drivers don't need to do the same anymore. Though they need to set the policy->freq_table field directly from the ->init() callback now. Stop validating the frequency table from sparc driver. Signed-off-by: Viresh Kumar --- drivers/cpufreq/sparc-us2e-cpufreq.c | 3 ++- drivers/cpufreq/sparc-us3-cpufreq.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) -- 2.15.0.194.g9af6a3dea062 diff --git a/drivers/cpufreq/sparc-us2e-cpufreq.c b/drivers/cpufreq/sparc-us2e-cpufreq.c index 90f33efee5fc..bbd1d1e166b8 100644 --- a/drivers/cpufreq/sparc-us2e-cpufreq.c +++ b/drivers/cpufreq/sparc-us2e-cpufreq.c @@ -292,8 +292,9 @@ static int __init us2e_freq_cpu_init(struct cpufreq_policy *policy) policy->cpuinfo.transition_latency = 0; policy->cur = clock_tick; + policy->freq_table = table; - return cpufreq_table_validate_and_show(policy, table); + return 0; } static int us2e_freq_cpu_exit(struct cpufreq_policy *policy) diff --git a/drivers/cpufreq/sparc-us3-cpufreq.c b/drivers/cpufreq/sparc-us3-cpufreq.c index 30645b0118f9..51e3c6018e74 100644 --- a/drivers/cpufreq/sparc-us3-cpufreq.c +++ b/drivers/cpufreq/sparc-us3-cpufreq.c @@ -136,8 +136,9 @@ static int __init us3_freq_cpu_init(struct cpufreq_policy *policy) policy->cpuinfo.transition_latency = 0; policy->cur = clock_tick; + policy->freq_table = table; - return cpufreq_table_validate_and_show(policy, table); + return 0; } static int us3_freq_cpu_exit(struct cpufreq_policy *policy)