From patchwork Wed Oct 3 23:00:28 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hilman X-Patchwork-Id: 1543761 Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 0D695DFF71 for ; Wed, 3 Oct 2012 23:01:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932466Ab2JCXBe (ORCPT ); Wed, 3 Oct 2012 19:01:34 -0400 Received: from mail-pb0-f46.google.com ([209.85.160.46]:50600 "EHLO mail-pb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932457Ab2JCXAi (ORCPT ); Wed, 3 Oct 2012 19:00:38 -0400 Received: by mail-pb0-f46.google.com with SMTP id rr4so10334004pbb.19 for ; Wed, 03 Oct 2012 16:00:38 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=jd93FhskqzUZkiSduuhBosr8e5+r043aiz4Qb3p6x5Y=; b=INkGBE5bFGcj0fRJ0vgyUVZ+ZC8BRHh1KgRVhTZMqlPB1qN7UEln7W5i/AI9lFajXG w8+tvJiJyuPJbubeSOEfKGUbssUIlptbCiZ62GVtk9huRYzfVdYMT2FRR3jzDy4N5lhF uC+73uZdekvmKLkpmwafZSqakg/Yn/pzz/RgSMFfbc558zb2YkbkvvmnBvdTy/TXxgEA aX3JgJ8FWn2rL3/kjRd5bYhdqQ2ntUG9LBhisQd9uG5WYlmPnWcnIEET7oSbOygR3NAI VAw++LMYYAV9PKT48HOrYb6xlCdsG1XVQwM+xzXwpqHuz7QLJ7YbP3L3E+40UaFsfIiU XnsA== Received: by 10.68.129.5 with SMTP id ns5mr16440999pbb.103.1349305238266; Wed, 03 Oct 2012 16:00:38 -0700 (PDT) Received: from localhost (c-24-19-7-36.hsd1.wa.comcast.net. [24.19.7.36]) by mx.google.com with ESMTPS id st6sm3255346pbc.58.2012.10.03.16.00.37 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 03 Oct 2012 16:00:37 -0700 (PDT) From: Kevin Hilman To: "Rafael J. Wysocki" , linux-omap@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org Subject: [PATCH 3/4] cpufreq: OMAP: fix clock usage to be SoC independent, remove plat/ includes Date: Wed, 3 Oct 2012 16:00:28 -0700 Message-Id: <1349305229-28480-4-git-send-email-khilman@deeprootsystems.com> X-Mailer: git-send-email 1.7.9.2 In-Reply-To: <1349305229-28480-1-git-send-email-khilman@deeprootsystems.com> References: <1349305229-28480-1-git-send-email-khilman@deeprootsystems.com> X-Gm-Message-State: ALoCoQkOES94vYIeiaNN2ig56/wxhtWgBdxlltNGDGsTwsJ9RLBzBiyOA2R7Mvact5HeSrlCiQCi Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org From: Paul Walmsley OMAP core code now has SoC-independent clock alias for the scalable CPU clock. Using it means driver is SoC independent and will work for AM3xxx SoCs as well as OMAP1/3/4. While here, remove some unnecessary plat/ includes that are interfering with multi-subarch ARM kernels. Signed-off-by: Paul Walmsley Cc: Rafael J. Wysocki [tony@atomide.com: updated already changed clock aliases] Signed-off-by: Tony Lindgren [khilman@ti.com: minor shortlog/changelog updates] Signed-off-by: Kevin Hilman --- drivers/cpufreq/omap-cpufreq.c | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/drivers/cpufreq/omap-cpufreq.c b/drivers/cpufreq/omap-cpufreq.c index 7d4d455..5d1f5e4 100644 --- a/drivers/cpufreq/omap-cpufreq.c +++ b/drivers/cpufreq/omap-cpufreq.c @@ -30,19 +30,14 @@ #include #include -#include -#include #include -#include - /* OPP tolerance in percentage */ #define OPP_TOLERANCE 4 static struct cpufreq_frequency_table *freq_table; static atomic_t freq_table_users = ATOMIC_INIT(0); static struct clk *mpu_clk; -static char *mpu_clk_name; static struct device *mpu_dev; static struct regulator *mpu_reg; @@ -179,7 +174,7 @@ static int __cpuinit omap_cpu_init(struct cpufreq_policy *policy) { int result = 0; - mpu_clk = clk_get(NULL, mpu_clk_name); + mpu_clk = clk_get(NULL, "cpufreq_ck"); if (IS_ERR(mpu_clk)) return PTR_ERR(mpu_clk); @@ -260,18 +255,6 @@ static struct cpufreq_driver omap_driver = { static int __init omap_cpufreq_init(void) { - if (cpu_is_omap24xx()) - mpu_clk_name = "virt_prcm_set"; - else if (cpu_is_omap34xx()) - mpu_clk_name = "dpll1_ck"; - else if (cpu_is_omap44xx()) - mpu_clk_name = "dpll_mpu_ck"; - - if (!mpu_clk_name) { - pr_err("%s: unsupported Silicon?\n", __func__); - return -EINVAL; - } - mpu_dev = omap_device_get_by_hwmod_name("mpu"); if (IS_ERR(mpu_dev)) { pr_warning("%s: unable to get the mpu device\n", __func__);