From patchwork Wed Dec 17 09:42:24 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 5505911 X-Patchwork-Delegate: horms@verge.net.au Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 93FA69F30B for ; Wed, 17 Dec 2014 09:39:43 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B409A209EA for ; Wed, 17 Dec 2014 09:39:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DDFA2209CF for ; Wed, 17 Dec 2014 09:39:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751856AbaLQJjl (ORCPT ); Wed, 17 Dec 2014 04:39:41 -0500 Received: from mail-pd0-f180.google.com ([209.85.192.180]:63290 "EHLO mail-pd0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751841AbaLQJjk (ORCPT ); Wed, 17 Dec 2014 04:39:40 -0500 Received: by mail-pd0-f180.google.com with SMTP id w10so15918857pde.39 for ; Wed, 17 Dec 2014 01:39:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:date:message-id:in-reply-to:references:subject; bh=KDPbtCayKcG4or8SNmDNyLStEcz4lzUy0pWJH8c9ezE=; b=gb3K4cYJ7gZZvxddkJ5fEfiWIxMwS+9kGQeyjKF4xgkZYF7VlqKRPIMLb6oyC1pPqL nEcr92p2D82TtaQVJV3U6OjIZbHr38aXsWxmFsQiJohXuBBrvvjh64tqi2pRq95vwfYr E8g7Xh0PNOSxfy4XEzsnicGHu13m32y+ZW47OViQX8erpgJsvDCuzlohoJO8xEjOLKtZ uw9rb9y3nhDRftIkN22bXY9sOGE5yjPr3xZcOaucSF4PyBv/tTSO40e/RowFPmrU3D6u rX6CLQP6mR14/IS7EPQkfRARWtQiYBzVBj3w6ECsxilersyihrZPXGgr+xLk+KeXeBc6 B2xA== X-Received: by 10.70.46.201 with SMTP id x9mr68980865pdm.154.1418809180087; Wed, 17 Dec 2014 01:39:40 -0800 (PST) Received: from [127.0.0.1] (s214090.ppp.asahi-net.or.jp. [220.157.214.90]) by mx.google.com with ESMTPSA id fn5sm3336332pdb.55.2014.12.17.01.39.37 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Dec 2014 01:39:39 -0800 (PST) From: Magnus Damm To: linux-sh@vger.kernel.org Cc: ulrich.hecht+renesas@gmail.com, Magnus Damm , horms@verge.net.au, geert+renesas@glider.be Date: Wed, 17 Dec 2014 18:42:24 +0900 Message-Id: <20141217094224.7039.64925.sendpatchset@w520> In-Reply-To: <20141217094204.7039.45337.sendpatchset@w520> References: <20141217094204.7039.45337.sendpatchset@w520> Subject: [PATCH v2 02/05] ARM: shmobile: sh73a0: Introduce generic setup callback Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Magnus Damm Add a generic sh73a0 machine setup callback for the upcoming sh73a0 multiplatform case. Cache needs to be configured, and legacy clocks must be omitted. Signed-off-by: Magnus Damm --- arch/arm/mach-shmobile/setup-sh73a0.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- 0001/arch/arm/mach-shmobile/setup-sh73a0.c +++ work/arch/arm/mach-shmobile/setup-sh73a0.c 2014-12-16 19:10:22.000000000 +0900 @@ -30,6 +30,7 @@ #include #include +#include #include #include #include @@ -777,8 +778,6 @@ void __init sh73a0_add_early_devices(voi shmobile_setup_console(); } -#ifdef CONFIG_USE_OF - void __init sh73a0_add_standard_devices_dt(void) { /* clocks are setup late during boot in the case of DT */ @@ -794,6 +793,17 @@ static void sh73a0_restart(enum reboot_m writel((1 << 31), RESCNT2); } +#ifdef CONFIG_USE_OF + +static void __init sh73a0_generic_init(void) +{ +#ifdef CONFIG_CACHE_L2X0 + /* Shared attribute override enable, 64K*8way */ + l2x0_init(IOMEM(0xf0100000), 0x00400000, 0xc20f0fff); +#endif + of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); +} + static const char *sh73a0_boards_compat_dt[] __initdata = { "renesas,sh73a0", NULL, @@ -803,7 +813,7 @@ DT_MACHINE_START(SH73A0_DT, "Generic SH7 .smp = smp_ops(sh73a0_smp_ops), .map_io = sh73a0_map_io, .init_early = shmobile_init_delay, - .init_machine = sh73a0_add_standard_devices_dt, + .init_machine = sh73a0_generic_init, .init_late = shmobile_init_late, .restart = sh73a0_restart, .dt_compat = sh73a0_boards_compat_dt,