From patchwork Mon Mar 17 23:00:47 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 331229 X-Patchwork-Delegate: albert.aribaud@free.fr Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id CAC832C0040 for ; Tue, 18 Mar 2014 10:02:01 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 901504B60F; Tue, 18 Mar 2014 00:01:57 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id EnU2RioG0k7i; Tue, 18 Mar 2014 00:01:57 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id D7F1B4B61D; Tue, 18 Mar 2014 00:01:49 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E54E94B5D2 for ; Tue, 18 Mar 2014 00:01:47 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id sDrpiXCXg6W1 for ; Tue, 18 Mar 2014 00:01:45 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by theia.denx.de (Postfix) with ESMTP id C845C4B5D5 for ; Tue, 18 Mar 2014 00:01:38 +0100 (CET) Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s2HN1Vb4013376 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 17 Mar 2014 19:01:31 -0400 Received: from shalem.localdomain.com (vpn1-6-244.ams2.redhat.com [10.36.6.244]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s2HN0vlh011457; Mon, 17 Mar 2014 19:01:22 -0400 From: Hans de Goede To: Ian Campbell Date: Tue, 18 Mar 2014 00:00:47 +0100 Message-Id: <1395097256-7593-4-git-send-email-hdegoede@redhat.com> In-Reply-To: <1395097256-7593-1-git-send-email-hdegoede@redhat.com> References: <1395097256-7593-1-git-send-email-hdegoede@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 Cc: u-boot@lists.denx.de, linux-sunxi@googlegroups.com, Hans de Goede Subject: [U-Boot] [PATCH u-boot sunxi 03/12] sunxi: FIXUP: sunxi: initial sun7i clocks and timer support. X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Add #ifdef CONFIG_SUN7I were appropriate to make adding sun4i / sun5i support later easier. Signed-off-by: Hans de Goede --- arch/arm/cpu/armv7/sunxi/clock.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/cpu/armv7/sunxi/clock.c b/arch/arm/cpu/armv7/sunxi/clock.c index 9cdcc8a..dd01be6 100644 --- a/arch/arm/cpu/armv7/sunxi/clock.c +++ b/arch/arm/cpu/armv7/sunxi/clock.c @@ -33,10 +33,12 @@ static void clock_init_safe(void) APB0_DIV_1 << APB0_DIV_SHIFT | CPU_CLK_SRC_PLL1 << CPU_CLK_SRC_SHIFT, &ccm->cpu_ahb_apb0_cfg); +#ifdef CONFIG_SUN7I writel(0x1 << AHB_GATE_OFFSET_DMA | readl(&ccm->ahb_gate0), &ccm->ahb_gate0); writel(0x1 << PLL6_ENABLE_OFFSET | readl(&ccm->pll6_cfg), &ccm->pll6_cfg); +#endif } #endif