From patchwork Sat Jan 20 17:14:09 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Lechner X-Patchwork-Id: 10176633 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4703A6056F for ; Sat, 20 Jan 2018 18:06:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 24FDF2013C for ; Sat, 20 Jan 2018 18:06:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 19A9320174; Sat, 20 Jan 2018 18:06:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 12CB82013C for ; Sat, 20 Jan 2018 18:06:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=nsNUbgDiQQs5E9t0Gyf7Qh5gbiie0K7e3VKDNBJhiQ4=; b=DuVIwgHgGBxa2ShetFI11VFEa7 APzteuqQeAOo07OzmT7sVnlSzzME84Qf+7/UfqAtP4OUGJIUzgHH+8nRItALxntYxfYRz1eV5T7LS eRnGFxbZvxiUSz/GSMCWyfa6ZrNUYjkv6xcQCdg2+gPimBU5Tv9dPcX3lDg2qZojAwpIBpgFI8n6u B9GiZzuRdV5N2LAXbfng+h+S9uvlAvC6Pq7dKnw0kUow9wnZqs3NuUSLbNIVIgPGt0+suuqsz0Uj5 neTwciPJJBhCZ2CKS5ugncYR5aqbNjwnL7bXAQS/u9Csgwj4IlWuY8R7kdQ/kpPzVL98VUV31eNR7 CqjPdGWA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1ecxXT-0006yp-9C; Sat, 20 Jan 2018 18:06:47 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1ecxJI-0004NQ-8p for linux-arm-kernel@bombadil.infradead.org; Sat, 20 Jan 2018 17:52:08 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=mlYRCGUeojD6x6dn5vCvkQ2Uf+2zwl8Lxua8TDFdvc0=; b=TA+rF9sP/lcBJFlQEYnVodC2v pJqm+cGeExL88m8lQtfNx07H0CcIWYvfyErr9oVpEUKrDgT6B4gegDypPwtnhSjakYI2nb1aMG8B2 qylYTguClfA4wl7eE8/OZ4ZIEYfgF1cpNCQQLpzqn0mmJF7s07gu8i4sPfKMaeq9MKlBEw/Uoic3K x39bO+Z7aP3MWY/x1j4Sb7Q3E/oYXfI6mGD+bl8cUIFvJmgn/P50NbK18OqwEt/cMJElKYFzkpoZm 67/C785MVLNmLjHOfAZlHHXRTbBwFgUHqpbGMj8cwVqjR8T0aSROYGLlGzeKG6JcJ9v4B+aW/v52p /5immTvzw==; Received: from vern.gendns.com ([206.190.152.46]) by casper.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1ecx34-000607-2f for linux-arm-kernel@lists.infradead.org; Sat, 20 Jan 2018 17:35:24 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lechnology.com; s=default; h=References:In-Reply-To:Message-Id:Date:Subject :Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=mlYRCGUeojD6x6dn5vCvkQ2Uf+2zwl8Lxua8TDFdvc0=; b=OqrVqz1oMKs50zx/Zwm9atioZ l/J6gBJ1mt0ryQ8b9DZ11F3uoTqrPKoQ3ARuVClEa/wi2xi/mnVx0UgqUklxUrIxnlAG05uQdR+de 3AbWtb+Y4X7VGE8IQWCF4YtRBHHoIHPkXzdY42XB4FFVb7Y7zhKeByl8k05YVvqLtBMe0oWYKEINq lmUF2UByH60TPFw9LRO5fQcdG61xp/8CFC6qkhQsV9+Lj1mX9AuMjdb5SA2CZ9ig9jMH5owHYHD1W MGhCIfPqJIFjcjZjUYVKE7vczKQOGEh3J8WP48jhGbkb5PHeXbVCXzanKP0Zxik0tehZQiz8UcbIu pfKsquu8w==; Received: from 108-198-5-147.lightspeed.okcbok.sbcglobal.net ([108.198.5.147]:53590 helo=freyr.lechnology.com) by vern.gendns.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-SHA256:128) (Exim 4.89_1) (envelope-from ) id 1ecwji-00059q-7i; Sat, 20 Jan 2018 12:15:22 -0500 From: David Lechner To: linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v6 30/41] ARM: davinci: switch to common clock framework Date: Sat, 20 Jan 2018 11:14:09 -0600 Message-Id: <1516468460-4908-31-git-send-email-david@lechnology.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1516468460-4908-1-git-send-email-david@lechnology.com> References: <1516468460-4908-1-git-send-email-david@lechnology.com> X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - vern.gendns.com X-AntiAbuse: Original Domain - lists.infradead.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lechnology.com X-Get-Message-Sender-Via: vern.gendns.com: authenticated_id: davidmain+lechnology.com/only user confirmed/virtual account not confirmed X-Authenticated-Sender: vern.gendns.com: davidmain@lechnology.com X-Source: X-Source-Args: X-Source-Dir: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180120_173522_250071_02107BF4 X-CRM114-Status: GOOD ( 12.00 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , David Lechner , Kevin Hilman , Stephen Boyd , Michael Turquette , Sekhar Nori , linux-kernel@vger.kernel.org, Bartosz Golaszewski , Rob Herring , Adam Ford MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP This switches ARCH_DAVINCI to use the common clock framework. The legacy clock code in arch/arm/mach-davinci/ is no longer used. New drivers in drivers/clk/davinci/ are used instead. A few macros had to be moved to prevent compile errors. Signed-off-by: David Lechner Reviewed-by: Sekhar Nori --- v6 changes: - clean up indent on Common objects section arch/arm/Kconfig | 2 +- arch/arm/mach-davinci/Makefile | 4 ++-- arch/arm/mach-davinci/clock.h | 4 ---- arch/arm/mach-davinci/davinci.h | 4 ++++ arch/arm/mach-davinci/psc.h | 2 -- 5 files changed, 7 insertions(+), 9 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 51c8df5..3a12f9e 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -604,7 +604,7 @@ config ARCH_S3C24XX config ARCH_DAVINCI bool "TI DaVinci" select ARCH_HAS_HOLES_MEMORYMODEL - select CLKDEV_LOOKUP + select COMMON_CLK select CPU_ARM926T select GENERIC_ALLOCATOR select GENERIC_CLOCKEVENTS diff --git a/arch/arm/mach-davinci/Makefile b/arch/arm/mach-davinci/Makefile index 4e81780..8725d8b 100644 --- a/arch/arm/mach-davinci/Makefile +++ b/arch/arm/mach-davinci/Makefile @@ -5,8 +5,8 @@ # # Common objects -obj-y := time.o clock.o serial.o psc.o \ - usb.o common.o sram.o aemif.o +obj-y := time.o serial.o usb.o \ + common.o sram.o aemif.o obj-$(CONFIG_DAVINCI_MUX) += mux.o diff --git a/arch/arm/mach-davinci/clock.h b/arch/arm/mach-davinci/clock.h index d7894d5..2d05856 100644 --- a/arch/arm/mach-davinci/clock.h +++ b/arch/arm/mach-davinci/clock.h @@ -12,10 +12,6 @@ #ifndef __ARCH_ARM_DAVINCI_CLOCK_H #define __ARCH_ARM_DAVINCI_CLOCK_H -#define DAVINCI_PLL1_BASE 0x01c40800 -#define DAVINCI_PLL2_BASE 0x01c40c00 -#define MAX_PLL 2 - /* PLL/Reset register offsets */ #define PLLCTL 0x100 #define PLLCTL_PLLEN BIT(0) diff --git a/arch/arm/mach-davinci/davinci.h b/arch/arm/mach-davinci/davinci.h index 270cef8..f5206a6 100644 --- a/arch/arm/mach-davinci/davinci.h +++ b/arch/arm/mach-davinci/davinci.h @@ -35,6 +35,10 @@ #include #include +#define DAVINCI_PLL1_BASE 0x01c40800 +#define DAVINCI_PLL2_BASE 0x01c40c00 +#define DAVINCI_PWR_SLEEP_CNTRL_BASE 0x01c41000 + #define DAVINCI_SYSTEM_MODULE_BASE 0x01c40000 #define SYSMOD_VDAC_CONFIG 0x2c #define SYSMOD_VIDCLKCTL 0x38 diff --git a/arch/arm/mach-davinci/psc.h b/arch/arm/mach-davinci/psc.h index 8af9f09..b58707c 100644 --- a/arch/arm/mach-davinci/psc.h +++ b/arch/arm/mach-davinci/psc.h @@ -27,8 +27,6 @@ #ifndef __ASM_ARCH_PSC_H #define __ASM_ARCH_PSC_H -#define DAVINCI_PWR_SLEEP_CNTRL_BASE 0x01C41000 - /* Power and Sleep Controller (PSC) Domains */ #define DAVINCI_GPSC_ARMDOMAIN 0 #define DAVINCI_GPSC_DSPDOMAIN 1