From patchwork Fri Dec 13 19:59:39 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomasz Figa X-Patchwork-Id: 3342441 Return-Path: X-Original-To: patchwork-linux-samsung-soc@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 CD3AC9F2A9 for ; Fri, 13 Dec 2013 19:59:58 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D45DB20783 for ; Fri, 13 Dec 2013 19:59:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0823B20781 for ; Fri, 13 Dec 2013 19:59:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752673Ab3LMT74 (ORCPT ); Fri, 13 Dec 2013 14:59:56 -0500 Received: from mail-ee0-f52.google.com ([74.125.83.52]:50628 "EHLO mail-ee0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752607Ab3LMT74 (ORCPT ); Fri, 13 Dec 2013 14:59:56 -0500 Received: by mail-ee0-f52.google.com with SMTP id d17so1061196eek.25 for ; Fri, 13 Dec 2013 11:59:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=38pozV0cL0m5vX3o6OIO39hmUQBSPcQwRXxS+hnRG5I=; b=CSe+K3kkFPTPOxZ6o8cwNLNMwYySUuMQ2bWfMCCnwxKwfyN7KEYkI6P9t1yNrsKWB5 pGk/WgUujCCkEStpWhhjgYex4wanZFlq1rX0sb16AYw0zUkdt4lMVj/b3mg6+zLCJMhv GoNmEPB/uT+BcM9XdAwOpbCnzRQRJFcmh6XQSvY4MqFJ8LJ8lNpX1pk7DhWP4vSHGgVt Dh1fT/jRphtw5f+9aRp0aksV86kEATlslX55BoyICiRVDDDxYMPocj20QCb4juD/GyWI 2+Kz6ysd4kIRIYya0H4QkHwUGoiXf/Dttc0eKf5upFv97Z5B6hg6uuLyZVZfZftP9/NV bVOg== X-Received: by 10.14.2.73 with SMTP id 49mr4673914eee.15.1386964795302; Fri, 13 Dec 2013 11:59:55 -0800 (PST) Received: from flatron.tomeq (87-207-52-162.dynamic.chello.pl. [87.207.52.162]) by mx.google.com with ESMTPSA id g7sm10346258eet.12.2013.12.13.11.59.54 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Dec 2013 11:59:54 -0800 (PST) From: Tomasz Figa To: linux-samsung-soc@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, Kukjin Kim , Arnd Bergmann , Olof Johansson , Sebastian Hesselbarth , Tomasz Figa Subject: [PATCH CRITICAL] ARM: s3c64xx: dt: Fix boot failure due to double clock initialization Date: Fri, 13 Dec 2013 20:59:39 +0100 Message-Id: <1386964779-29457-1-git-send-email-tomasz.figa@gmail.com> X-Mailer: git-send-email 1.8.5.1 Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@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, RP_MATCHES_RCVD, T_DKIM_INVALID, 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 Commit 4178bac ARM: call of_clk_init from default time_init handler added implicit call to of_clk_init() from default time_init callback, but it did not change platforms calling it from other callbacks, despite of not having custom time_init callbacks. This caused double clock initialization on such platforms, leading to boot failures. An example of such platform is mach-s3c64xx. This patch fixes boot failure on s3c64xx by dropping custom init_irq callback, which had a call to of_clk_init() and moving system reset initialization to init_machine callback. This allows us to have clocks initialized properly without a need to have custom init_time or init_irq callbacks. Signed-off-by: Tomasz Figa --- arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) NOTE: This is a critical boot regression fix for mach-s3c64xx that should be merged for next 3.13-rc release. diff --git a/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c b/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c index 7eb9a10..2fddf38 100644 --- a/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c +++ b/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c @@ -8,8 +8,6 @@ * published by the Free Software Foundation. */ -#include -#include #include #include @@ -48,15 +46,9 @@ static void __init s3c64xx_dt_map_io(void) panic("SoC is not S3C64xx!"); } -static void __init s3c64xx_dt_init_irq(void) -{ - of_clk_init(NULL); - samsung_wdt_reset_of_init(); - irqchip_init(); -}; - static void __init s3c64xx_dt_init_machine(void) { + samsung_wdt_reset_of_init(); of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); } @@ -79,7 +71,6 @@ DT_MACHINE_START(S3C6400_DT, "Samsung S3C64xx (Flattened Device Tree)") /* Maintainer: Tomasz Figa */ .dt_compat = s3c64xx_dt_compat, .map_io = s3c64xx_dt_map_io, - .init_irq = s3c64xx_dt_init_irq, .init_machine = s3c64xx_dt_init_machine, .restart = s3c64xx_dt_restart, MACHINE_END