From patchwork Thu Jul 12 00:46:44 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Turquette X-Patchwork-Id: 1186271 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork1.kernel.org (Postfix) with ESMTP id CA39A3FC8E for ; Thu, 12 Jul 2012 00:51:15 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1Sp7Ye-000238-Ux; Thu, 12 Jul 2012 00:47:05 +0000 Received: from na3sys009aog110.obsmtp.com ([74.125.149.203]) by merlin.infradead.org with smtps (Exim 4.76 #1 (Red Hat Linux)) id 1Sp7YT-00022m-41 for linux-arm-kernel@lists.infradead.org; Thu, 12 Jul 2012 00:46:55 +0000 Received: from mail-gg0-f176.google.com ([209.85.161.176]) (using TLSv1) by na3sys009aob110.postini.com ([74.125.148.12]) with SMTP ID DSNKT/4eeWn5ZgCplCxDqeofRiB0GQLF+VIl@postini.com; Wed, 11 Jul 2012 17:46:52 PDT Received: by ggnk4 with SMTP id k4so2325495ggn.21 for ; Wed, 11 Jul 2012 17:46:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent :x-gm-message-state; bh=ToMZWZqXYrD08CNQ32f4TIwLBq5PZZkeHcO+DeWfiBo=; b=nuw1CVyD6Dl5bjahrKljakMOG4sXfDTdZW+P4x57VsL+PuwuMF1ji3Sq+Cg4KOvQBE hk4UfRBFVz3BZGfLZTwplkTMlY/BnnsCkT9RwlcVeBLai0X4M91cmlTFkicFy2p0xwvq V/ylFb8PQn4OonAVCCSewKQQxP+HKaHEjRCjocHEc4c2KHZHUZIcWZUkMI6Nz8H7ergQ kTc0IH7YeLFOXQhLOlWWt/TPGdbuSXGiotizbNx8HwMy4eiJa1vFOvo2eLCAE6D/W6Zo s1Ar68zN+xdpAWman/1oDLFTHOBHnwQ5dlc8cEGafUkuYxvTN1w18D2ny6Kbzf9ZTarf rOfg== Received: by 10.66.83.33 with SMTP id n1mr85891746pay.7.1342054009041; Wed, 11 Jul 2012 17:46:49 -0700 (PDT) Received: from gmail.com (nsc-e-gw.nsc.com. [12.238.8.30]) by mx.google.com with ESMTPS id nv6sm2683870pbc.42.2012.07.11.17.46.46 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 11 Jul 2012 17:46:47 -0700 (PDT) Date: Wed, 11 Jul 2012 17:46:44 -0700 From: Mike Turquette To: Rob Herring Subject: Re: [GIT PULL] DT clk binding support for 3.6 Message-ID: <20120712004644.GH2772@gmail.com> References: <4FF86BD9.3050805@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <4FF86BD9.3050805@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-Gm-Message-State: ALoCoQkLKgh+mv8PGFXWcvhTl5MQ6lunWswvR7f82VsQAVbYMSZ9eCeBYk7n/LVrfFRk7bH7djGk X-Spam-Note: CRM114 invocation failed X-Spam-Score: -4.2 (----) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-4.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [74.125.149.203 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Grant Likely , Mike Turquette , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org On 20120707-12:03, Rob Herring wrote: > Mike, > > Please pull DT clk binding and highbank clk support for 3.6. The only > real change from 3.5 pull request is returning error values rather than > NULL to align with the rest of the clk framework. There's been a little > discussion but otherwise has been quiet. > Hi Rob, I agree that these patches have seen enough time on the list. I did find one problem in testing: the high bank clock registration function writes to clk_hb->hw.init which is marked const. I fixed it up in the below patch. That fix is now squashed into into the final patch in your series on the clk-next branch. Let me know if you have any objections. Regards, Mike > Rob > > The following changes since commit 6887a4131da3adaab011613776d865f4bcfb5678: > > Linux 3.5-rc5 (2012-06-30 16:08:57 -0700) > > are available in the git repository at: > > git://sources.calxeda.com/kernel/linux.git clk-for-3.6 > > for you to fetch changes up to 39a8e38a03823c3acaec02c6d7c551e268cb2139: > > clk: add highbank clock support (2012-07-01 17:04:45 -0500) > > ---------------------------------------------------------------- > Grant Likely (2): > clk: add DT clock binding support > clk: add DT fixed-clock binding support > > Rob Herring (2): > dt: add clock binding doc to primecell bindings > clk: add highbank clock support > > .../devicetree/bindings/arm/primecell.txt | 6 + > .../devicetree/bindings/clock/calxeda.txt | 17 + > .../devicetree/bindings/clock/clock-bindings.txt | 117 +++++++ > .../devicetree/bindings/clock/fixed-clock.txt | 21 ++ > arch/arm/Kconfig | 1 + > arch/arm/boot/dts/highbank.dts | 91 +++++- > arch/arm/mach-highbank/Makefile | 2 +- > arch/arm/mach-highbank/clock.c | 62 ---- > arch/arm/mach-highbank/highbank.c | 7 + > drivers/clk/Makefile | 1 + > drivers/clk/clk-fixed-rate.c | 23 ++ > drivers/clk/clk-highbank.c | 345 > ++++++++++++++++++++ > drivers/clk/clk.c | 140 ++++++++ > drivers/clk/clkdev.c | 77 +++++ > include/linux/clk-provider.h | 16 + > include/linux/clk.h | 19 ++ > 16 files changed, 881 insertions(+), 64 deletions(-) > create mode 100644 Documentation/devicetree/bindings/clock/calxeda.txt > create mode 100644 > Documentation/devicetree/bindings/clock/clock-bindings.txt > create mode 100644 Documentation/devicetree/bindings/clock/fixed-clock.txt > delete mode 100644 arch/arm/mach-highbank/clock.c > create mode 100644 drivers/clk/clk-highbank.c > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/drivers/clk/clk-highbank.c b/drivers/clk/clk-highbank.c index 2f61065..52fecad 100644 --- a/drivers/clk/clk-highbank.c +++ b/drivers/clk/clk-highbank.c @@ -277,7 +277,7 @@ static __init struct clk *hb_clk_init(struct device_node *node, const struct clk struct hb_clk *hb_clk; const char *clk_name = node->name; const char *parent_name; - struct clk_init_data init_data; + struct clk_init_data init; int rc; rc = of_property_read_u32(node, "reg", ®); @@ -292,13 +292,14 @@ static __init struct clk *hb_clk_init(struct device_node *node, const struct clk of_property_read_string(node, "clock-output-names", &clk_name); - hb_clk->hw.init = &init_data; - hb_clk->hw.init->name = clk_name; - hb_clk->hw.init->num_parents = 1; + init.name = clk_name; + init.ops = ops; + init.flags = 0; parent_name = of_clk_get_parent_name(node, 0); - hb_clk->hw.init->parent_names = &parent_name; - hb_clk->hw.init->ops = ops; - hb_clk->hw.init->flags = 0; + init.parent_names = &parent_name; + init.num_parents = 1; + + hb_clk->hw.init = &init; clk = clk_register(NULL, &hb_clk->hw); if (WARN_ON(IS_ERR(clk))) {