From patchwork Tue Mar 4 16:19:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tero Kristo X-Patchwork-Id: 25692 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pb0-f71.google.com (mail-pb0-f71.google.com [209.85.160.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 02E8A2066C for ; Tue, 4 Mar 2014 16:20:14 +0000 (UTC) Received: by mail-pb0-f71.google.com with SMTP id up15sf14653089pbc.10 for ; Tue, 04 Mar 2014 08:20:14 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe:content-type; bh=BQ/hXpg+iydhJQhEtBlC4pOo1GJ5vs6ty+tGT93WAkI=; b=aU/lglPu1TIcZr2avy5ZQSrKQ0C3cUA7L3IdSz02m3HDzgLIQHPAetfJw95y3ZiOBP FIW++y14Kq0Ecwx4Hl/AFif9+7EurGD40q55NGqmx60eixhCSbiCo0Nde2ibAOYrU66N A/nxwaVfLyPmu2Qq4nhPOs3s7leIEtrbSLktrOFwfcmngCWCFbQ2KgF6zJBHS+4Y3rJK 8RWJmMU4YjZBR3FZ2k2WZhhIHEkTiK2MuJ6q8oXtwPzKWccEjrJzelisB39q6zh7FWcu I85pOTV2p0AfEFpjCm4npufASUn+gU3YVWmr+olLFT4akIfvlGXkc+lK9IZBtfVqMbYJ 2njw== X-Gm-Message-State: ALoCoQkYQ9rZih0OOZGW02yDw5hfe0AsDEIQnD5SMK2gkFcPwiPfqYuTk2RMSYGTTfP8MJCbfC+X X-Received: by 10.67.2.101 with SMTP id bn5mr150652pad.29.1393950014265; Tue, 04 Mar 2014 08:20:14 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.38.47 with SMTP id s44ls2637416qgs.70.gmail; Tue, 04 Mar 2014 08:20:14 -0800 (PST) X-Received: by 10.52.242.167 with SMTP id wr7mr208887vdc.32.1393950014147; Tue, 04 Mar 2014 08:20:14 -0800 (PST) Received: from mail-ve0-f178.google.com (mail-ve0-f178.google.com [209.85.128.178]) by mx.google.com with ESMTPS id sm10si4389407vec.43.2014.03.04.08.20.14 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 04 Mar 2014 08:20:14 -0800 (PST) Received-SPF: neutral (google.com: 209.85.128.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.178; Received: by mail-ve0-f178.google.com with SMTP id jw12so3244668veb.9 for ; Tue, 04 Mar 2014 08:20:14 -0800 (PST) X-Received: by 10.220.209.197 with SMTP id gh5mr125386vcb.65.1393950014058; Tue, 04 Mar 2014 08:20:14 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.130.193 with SMTP id u1csp138042vcs; Tue, 4 Mar 2014 08:20:13 -0800 (PST) X-Received: by 10.68.170.228 with SMTP id ap4mr255885pbc.149.1393950013147; Tue, 04 Mar 2014 08:20:13 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id wq4si14758274pbc.137.2014.03.04.08.20.11; Tue, 04 Mar 2014 08:20:11 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751492AbaCDQUI (ORCPT + 5 others); Tue, 4 Mar 2014 11:20:08 -0500 Received: from devils.ext.ti.com ([198.47.26.153]:48403 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751282AbaCDQUG (ORCPT ); Tue, 4 Mar 2014 11:20:06 -0500 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id s24GJhr7015171; Tue, 4 Mar 2014 10:19:43 -0600 Received: from DFLE73.ent.ti.com (dfle73.ent.ti.com [128.247.5.110]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id s24GJhvv032310; Tue, 4 Mar 2014 10:19:43 -0600 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE73.ent.ti.com (128.247.5.110) with Microsoft SMTP Server id 14.3.174.1; Tue, 4 Mar 2014 10:19:43 -0600 Received: from localhost.localdomain (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id s24GJdR0017797; Tue, 4 Mar 2014 10:19:41 -0600 From: Tero Kristo To: , , , CC: Subject: [PATCH 01/18] ARM: OMAP3: CM: remove a few OMAP34XX_CM_REGADDR defines Date: Tue, 4 Mar 2014 18:19:01 +0200 Message-ID: <1393949958-816-2-git-send-email-t-kristo@ti.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1393949958-816-1-git-send-email-t-kristo@ti.com> References: <1393949958-816-1-git-send-email-t-kristo@ti.com> MIME-Version: 1.0 Sender: linux-omap-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: t-kristo@ti.com X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.178 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Remove a few OMAP34XX_CM_REGADDR defines and replace these with offset based register accesses instead. Signed-off-by: Tero Kristo --- arch/arm/mach-omap2/cm3xxx.c | 12 ++++++++---- arch/arm/mach-omap2/cm3xxx.h | 6 ++---- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/arch/arm/mach-omap2/cm3xxx.c b/arch/arm/mach-omap2/cm3xxx.c index f6f0288..60c2c9f 100644 --- a/arch/arm/mach-omap2/cm3xxx.c +++ b/arch/arm/mach-omap2/cm3xxx.c @@ -388,7 +388,8 @@ void omap3_cm_save_context(void) omap2_cm_read_mod_reg(OMAP3430_IVA2_MOD, CM_CLKSEL1); cm_context.iva2_cm_clksel2 = omap2_cm_read_mod_reg(OMAP3430_IVA2_MOD, CM_CLKSEL2); - cm_context.cm_sysconfig = __raw_readl(OMAP3430_CM_SYSCONFIG); + cm_context.cm_sysconfig = + omap2_cm_read_mod_reg(OCP_MOD, OMAP3430_CM_SYSCONFIG); cm_context.sgx_cm_clksel = omap2_cm_read_mod_reg(OMAP3430ES2_SGX_MOD, CM_CLKSEL); cm_context.dss_cm_clksel = @@ -418,7 +419,8 @@ void omap3_cm_save_context(void) omap2_cm_read_mod_reg(PLL_MOD, OMAP3430ES2_CM_CLKSEL5); cm_context.pll_cm_clken2 = omap2_cm_read_mod_reg(PLL_MOD, OMAP3430ES2_CM_CLKEN2); - cm_context.cm_polctrl = __raw_readl(OMAP3430_CM_POLCTRL); + cm_context.cm_polctrl = + omap2_cm_read_mod_reg(OCP_MOD, OMAP3430_CM_POLCTRL); cm_context.iva2_cm_fclken = omap2_cm_read_mod_reg(OMAP3430_IVA2_MOD, CM_FCLKEN); cm_context.iva2_cm_clken_pll = @@ -519,7 +521,8 @@ void omap3_cm_restore_context(void) CM_CLKSEL1); omap2_cm_write_mod_reg(cm_context.iva2_cm_clksel2, OMAP3430_IVA2_MOD, CM_CLKSEL2); - __raw_writel(cm_context.cm_sysconfig, OMAP3430_CM_SYSCONFIG); + omap2_cm_write_mod_reg(cm_context.cm_sysconfig, OCP_MOD, + OMAP3430_CM_SYSCONFIG); omap2_cm_write_mod_reg(cm_context.sgx_cm_clksel, OMAP3430ES2_SGX_MOD, CM_CLKSEL); omap2_cm_write_mod_reg(cm_context.dss_cm_clksel, OMAP3430_DSS_MOD, @@ -547,7 +550,8 @@ void omap3_cm_restore_context(void) OMAP3430ES2_CM_CLKSEL5); omap2_cm_write_mod_reg(cm_context.pll_cm_clken2, PLL_MOD, OMAP3430ES2_CM_CLKEN2); - __raw_writel(cm_context.cm_polctrl, OMAP3430_CM_POLCTRL); + omap2_cm_write_mod_reg(cm_context.cm_polctrl, OCP_MOD, + OMAP3430_CM_POLCTRL); omap2_cm_write_mod_reg(cm_context.iva2_cm_fclken, OMAP3430_IVA2_MOD, CM_FCLKEN); omap2_cm_write_mod_reg(cm_context.iva2_cm_clken_pll, OMAP3430_IVA2_MOD, diff --git a/arch/arm/mach-omap2/cm3xxx.h b/arch/arm/mach-omap2/cm3xxx.h index 8224c91..0301557 100644 --- a/arch/arm/mach-omap2/cm3xxx.h +++ b/arch/arm/mach-omap2/cm3xxx.h @@ -29,12 +29,10 @@ * These registers appear once per CM module. */ -#define OMAP3430_CM_REVISION OMAP34XX_CM_REGADDR(OCP_MOD, 0x0000) -#define OMAP3430_CM_SYSCONFIG OMAP34XX_CM_REGADDR(OCP_MOD, 0x0010) -#define OMAP3430_CM_POLCTRL OMAP34XX_CM_REGADDR(OCP_MOD, 0x009c) +#define OMAP3430_CM_SYSCONFIG 0x0010 +#define OMAP3430_CM_POLCTRL 0x009c #define OMAP3_CM_CLKOUT_CTRL_OFFSET 0x0070 -#define OMAP3430_CM_CLKOUT_CTRL OMAP_CM_REGADDR(OMAP3430_CCR_MOD, 0x0070) /* * Module specific CM register offsets from CM_BASE + domain offset