From patchwork Fri Aug 9 09:48:09 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 2841815 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 492D0BF546 for ; Fri, 9 Aug 2013 09:49:04 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 273AC20499 for ; Fri, 9 Aug 2013 09:49:03 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 258D520498 for ; Fri, 9 Aug 2013 09:49:02 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7jJA-0002pG-Qz; Fri, 09 Aug 2013 09:48:32 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7jJ0-00084W-Qt; Fri, 09 Aug 2013 09:48:22 +0000 Received: from mail-pa0-x22f.google.com ([2607:f8b0:400e:c03::22f]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7jIx-00082D-6r for linux-arm-kernel@lists.infradead.org; Fri, 09 Aug 2013 09:48:20 +0000 Received: by mail-pa0-f47.google.com with SMTP id kl13so4761079pab.34 for ; Fri, 09 Aug 2013 02:47:57 -0700 (PDT) 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=cXB6HgcHUQyYiwqa6ynUUknsarGBeRsAoQPR9CjwOYw=; b=uDTHU9tP8SdDzc9DyLtYyre8OdxP6bcpGTeY4NHaA6UYjSfnOxPL0pIPpgnyoHfHWJ Qdn+263AMFRARNuDskTCvM93Jfm7CLVgGc0lrEp0XZmq8HOy94n/aUvJjYeFMj8KwDDa LZF2/j18VQEZ2Xlnh1/CtTyhtU5kN8tO7SvC2tKeSa+9ANhtpBDV7ag+EuRRXD2NRhiC xwKW5xvwzSQxAz6EyVge+Xj3j/ZhIHOdnQ/SIirXqw0SZXHcRr+GzdO5VgJu9OlB/Ddk ZApEEKdYXgd4r/MSbMLwHLh1wgQOwpAGwPHR45m2ZlHnmouI9ZFhNekNMqSuUkM9OIPC 3IJg== X-Received: by 10.68.131.168 with SMTP id on8mr10554611pbb.97.1376041677804; Fri, 09 Aug 2013 02:47:57 -0700 (PDT) Received: from [127.0.0.1] (ac230065.ppp.asahi-net.or.jp. [183.77.230.65]) by mx.google.com with ESMTPSA id xe9sm21597360pab.0.2013.08.09.02.47.54 for (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 09 Aug 2013 02:47:56 -0700 (PDT) From: Magnus Damm To: linux-sh@vger.kernel.org Date: Fri, 09 Aug 2013 18:48:09 +0900 Message-Id: <20130809094809.6530.49246.sendpatchset@w520> In-Reply-To: <20130809094748.6530.16511.sendpatchset@w520> References: <20130809094748.6530.16511.sendpatchset@w520> Subject: [PATCH 02/14] ARM: shmobile: r8a7740: Remove ->init_machine() special case X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130809_054819_370429_B2F9DBF3 X-CRM114-Status: GOOD ( 11.03 ) X-Spam-Score: -2.0 (--) Cc: olof@lixom.net, horms@verge.net.au, Magnus Damm , linux-arm-kernel@lists.infradead.org, arnd@arndb.de X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=unavailable 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 No need to special case r8a7740 ->init_machine(), so get rid of undesired clock setup from the generic long term r8a7740 DT support code. Rework the code to let r8a7740_add_dt_devices() act like other SoCs and make the board DT reference code setup clocks for us. Signed-off-by: Magnus Damm --- arch/arm/mach-shmobile/board-armadillo800eva-reference.c | 4 +++- arch/arm/mach-shmobile/include/mach/r8a7740.h | 2 +- arch/arm/mach-shmobile/setup-r8a7740.c | 11 +---------- 3 files changed, 5 insertions(+), 12 deletions(-) --- 0001/arch/arm/mach-shmobile/board-armadillo800eva-reference.c +++ work/arch/arm/mach-shmobile/board-armadillo800eva-reference.c 2013-08-08 15:37:27.000000000 +0900 @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -168,7 +169,8 @@ static void __init eva_init(void) l2x0_init(IOMEM(0xf0002000), 0x40440000, 0x82000fff); #endif - r8a7740_add_standard_devices_dt(); + r8a7740_add_dt_devices(); + of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); r8a7740_pm_init(); } --- 0001/arch/arm/mach-shmobile/include/mach/r8a7740.h +++ work/arch/arm/mach-shmobile/include/mach/r8a7740.h 2013-08-08 15:33:40.000000000 +0900 @@ -52,7 +52,7 @@ extern void r8a7740_init_irq_of(void); extern void r8a7740_map_io(void); extern void r8a7740_add_early_devices(void); extern void r8a7740_add_standard_devices(void); -extern void r8a7740_add_standard_devices_dt(void); +extern void r8a7740_add_dt_devices(void); extern void r8a7740_clock_init(u8 md_ck); extern void r8a7740_pinmux_init(void); extern void r8a7740_pm_init(void); --- 0001/arch/arm/mach-shmobile/setup-r8a7740.c +++ work/arch/arm/mach-shmobile/setup-r8a7740.c 2013-08-08 15:37:11.000000000 +0900 @@ -26,7 +26,6 @@ #include #include #include -#include #include #include #include @@ -1009,11 +1008,10 @@ void __init r8a7740_add_early_devices_dt shmobile_setup_console(); } -void __init r8a7740_add_standard_devices_dt(void) +void __init r8a7740_add_dt_devices(void) { platform_add_devices(r8a7740_devices_dt, ARRAY_SIZE(r8a7740_devices_dt)); - of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); } void __init r8a7740_init_delay(void) @@ -1051,12 +1049,6 @@ void __init r8a7740_init_irq_of(void) iounmap(pfc_inta_ctrl); } -static void __init r8a7740_generic_init(void) -{ - r8a7740_clock_init(0); - r8a7740_add_standard_devices_dt(); -} - static const char *r8a7740_boards_compat_dt[] __initdata = { "renesas,r8a7740", NULL, @@ -1066,7 +1058,6 @@ DT_MACHINE_START(R8A7740_DT, "Generic R8 .map_io = r8a7740_map_io, .init_early = r8a7740_init_delay, .init_irq = r8a7740_init_irq_of, - .init_machine = r8a7740_generic_init, .dt_compat = r8a7740_boards_compat_dt, MACHINE_END