From patchwork Tue Jul 15 17:00:19 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: sam-the-6 X-Patchwork-Id: 33676 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ie0-f198.google.com (mail-ie0-f198.google.com [209.85.223.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id EAA93201F1 for ; Tue, 15 Jul 2014 17:02:25 +0000 (UTC) Received: by mail-ie0-f198.google.com with SMTP id rl12sf25384310iec.5 for ; Tue, 15 Jul 2014 10:02:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=XceyrMr1yYga8xiAQ1rlqJcMcPX+0g/JNMKtqlGJcd4=; b=LVH8syT0ppPejpkXK95jobnul3QKgL6iTb8vLbP7+wX1OiW4LUYroKbzsPlWJH/5EF aNn+9XxwXH1DEzSHD+H5EornuoiFn7AVFkASl4Xh+3H2++ppEos8wUBrxrijwYRKl57j HgR5TRY+b2GIOjenxbwDixMAxC0hg9so5YthzNRkAWkArtI06NmqRrtclICxb85POtam j2bSR3e+IDDduPTJW92Qog8YXPB4IhAqA59bOlMIhA+jhQGPrNvnaIg6YDzP7w569OVs Imd1AG0NeibOotc33MTUDGUGiZaamAcYksHQ9ykqSGcwO/QpY/Lf9ie/2xr9gl4+BZkF dvyw== X-Gm-Message-State: ALoCoQkWx5jfGHCDdGbttZ0YVKIvF72cnWnzbXmlcCyMdaB82qow4ZoowiXblo89U7zPGpZwx6H4 X-Received: by 10.42.90.68 with SMTP id j4mr8817576icm.3.1405443745426; Tue, 15 Jul 2014 10:02:25 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.41.231 with SMTP id z94ls151436qgz.63.gmail; Tue, 15 Jul 2014 10:02:25 -0700 (PDT) X-Received: by 10.220.1.70 with SMTP id 6mr1998616vce.62.1405443745298; Tue, 15 Jul 2014 10:02:25 -0700 (PDT) Received: from mail-vc0-x234.google.com (mail-vc0-x234.google.com [2607:f8b0:400c:c03::234]) by mx.google.com with ESMTPS id mg6si7057719vec.35.2014.07.15.10.02.25 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 15 Jul 2014 10:02:25 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 2607:f8b0:400c:c03::234 as permitted sender) client-ip=2607:f8b0:400c:c03::234; Received: by mail-vc0-f180.google.com with SMTP id ij19so1087835vcb.39 for ; Tue, 15 Jul 2014 10:02:25 -0700 (PDT) X-Received: by 10.58.182.234 with SMTP id eh10mr2209619vec.41.1405443745178; Tue, 15 Jul 2014 10:02:25 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp230468vcb; Tue, 15 Jul 2014 10:02:24 -0700 (PDT) X-Received: by 10.70.9.195 with SMTP id c3mr23892750pdb.21.1405443744313; Tue, 15 Jul 2014 10:02:24 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ty7si12246246pab.10.2014.07.15.10.02.23; Tue, 15 Jul 2014 10:02:23 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755861AbaGORCR (ORCPT + 28 others); Tue, 15 Jul 2014 13:02:17 -0400 Received: from mail-we0-f170.google.com ([74.125.82.170]:42925 "EHLO mail-we0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754929AbaGORCF (ORCPT ); Tue, 15 Jul 2014 13:02:05 -0400 Received: by mail-we0-f170.google.com with SMTP id w62so5652933wes.29 for ; Tue, 15 Jul 2014 10:02:04 -0700 (PDT) X-Received: by 10.194.6.10 with SMTP id w10mr29032046wjw.51.1405443724572; Tue, 15 Jul 2014 10:02:04 -0700 (PDT) Received: from Debian ([94.54.73.8]) by mx.google.com with ESMTPSA id p3sm33811499wjw.13.2014.07.15.10.02.02 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 15 Jul 2014 10:02:03 -0700 (PDT) Received: from sam by Debian with local (Exim 4.80) (envelope-from ) id 1X7676-0003zM-EN; Tue, 15 Jul 2014 20:02:00 +0300 From: Sam Asadi To: gregkh@linuxfoundation.org Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, Roger Quadros , Tero Kristo , sam-the-6 Subject: [PATCH 04/94] clk: ti: am43x: Fix boot with CONFIG_SOC_AM33XX disabled Date: Tue, 15 Jul 2014 20:00:19 +0300 Message-Id: <1405443709-15288-4-git-send-email-asadi.samuel@gmail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1405443709-15288-1-git-send-email-asadi.samuel@gmail.com> References: <1405443709-15288-1-git-send-email-asadi.samuel@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Original-Sender: asadi.samuel@gmail.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 2607:f8b0:400c:c03::234 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org; dkim=neutral (body hash did not verify) header.i=@; dmarc=fail (p=NONE dis=NONE) header.from=gmail.com Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Roger Quadros Define ti_clk_register_dpll_x2() and of_ti_am3_dpll_x2_setup() if AM43XX is defined. Fixes the below boot issue. [ 2.157258] gpmc_l3_clk not enabled [ 2.161194] gpmc_l3_clk not enabled [ 2.164896] Division by zero in kernel. [ 2.169055] CPU: 0 PID: 321 Comm: kworker/u2:2 Tainted: G W 3.16.0-rc1-00008-g4c0e520 #273 [ 2.178880] Workqueue: deferwq deferred_probe_work_func [ 2.184459] [] (unwind_backtrace) from [] (show_stack+0x10/0x14) [ 2.192752] [] (show_stack) from [] (dump_stack+0x80/0x9c) [ 2.200486] [] (dump_stack) from [] (Ldiv0+0x8/0x10) [ 2.207678] [] (Ldiv0) from [] (gpmc_calc_divider+0x24/0x40) [ 2.215490] [] (gpmc_calc_divider) from [] (gpmc_cs_set_timings+0x18/0x474) [ 2.224783] [] (gpmc_cs_set_timings) from [] (gpmc_nand_init+0x74/0x1a8) [ 2.233791] [] (gpmc_nand_init) from [] (gpmc_probe+0x52c/0x874) [ 2.242089] [] (gpmc_probe) from [] (platform_drv_probe+0x18/0x48) [ 2.250534] [] (platform_drv_probe) from [] (driver_probe_device+0x104/0x22c) [ 2.259988] [] (driver_probe_device) from [] (bus_for_each_drv+0x44/0x8c) [ 2.269087] [] (bus_for_each_drv) from [] (device_attach+0x74/0x8c) [ 2.277620] [] (device_attach) from [] (bus_probe_device+0x88/0xb0) [ 2.286074] [] (bus_probe_device) from [] (deferred_probe_work_func+0x60/0x90) [ 2.295611] [] (deferred_probe_work_func) from [] (process_one_work+0x1b4/0x4bc) [ 2.305288] [] (process_one_work) from [] (worker_thread+0x148/0x550) [ 2.313954] [] (worker_thread) from [] (kthread+0xc8/0xe4) [ 2.321628] [] (kthread) from [] (ret_from_fork+0x14/0x2c) Signed-off-by: Roger Quadros Reported-by: Tony Lindgren Signed-off-by: Tero Kristo Signed-off-by: sam-the-6 --- drivers/clk/ti/dpll.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/clk/ti/dpll.c b/drivers/clk/ti/dpll.c index abd956d..79791e1 100644 --- a/drivers/clk/ti/dpll.c +++ b/drivers/clk/ti/dpll.c @@ -161,7 +161,8 @@ cleanup: } #if defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5) || \ - defined(CONFIG_SOC_DRA7XX) || defined(CONFIG_SOC_AM33XX) + defined(CONFIG_SOC_DRA7XX) || defined(CONFIG_SOC_AM33XX) || \ + defined(CONFIG_SOC_AM43XX) /** * ti_clk_register_dpll_x2 - Registers a DPLLx2 clock * @node: device node for this clock @@ -322,7 +323,7 @@ CLK_OF_DECLARE(ti_omap4_dpll_x2_clock, "ti,omap4-dpll-x2-clock", of_ti_omap4_dpll_x2_setup); #endif -#ifdef CONFIG_SOC_AM33XX +#if defined(CONFIG_SOC_AM33XX) || defined(CONFIG_SOC_AM43XX) static void __init of_ti_am3_dpll_x2_setup(struct device_node *node) { ti_clk_register_dpll_x2(node, &dpll_x2_ck_ops, NULL);