From patchwork Fri Jul 6 22:56:34 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kim Phillips X-Patchwork-Id: 1168331 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 9E4BA3FC33 for ; Fri, 6 Jul 2012 23:07:51 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1SnHU7-0007O4-C8; Fri, 06 Jul 2012 22:58:47 +0000 Received: from ch1ehsobe006.messaging.microsoft.com ([216.32.181.186] helo=ch1outboundpool.messaging.microsoft.com) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1SnHU0-0007Nd-1m for linux-arm-kernel@lists.infradead.org; Fri, 06 Jul 2012 22:58:41 +0000 Received: from mail68-ch1-R.bigfish.com (10.43.68.233) by CH1EHSOBE012.bigfish.com (10.43.70.62) with Microsoft SMTP Server id 14.1.225.23; Fri, 6 Jul 2012 22:56:29 +0000 Received: from mail68-ch1 (localhost [127.0.0.1]) by mail68-ch1-R.bigfish.com (Postfix) with ESMTP id 20C4FA02F4; Fri, 6 Jul 2012 22:56:29 +0000 (UTC) X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPV:NLI; H:mail.freescale.net; RD:none; EFVD:NLI X-SpamScore: -2 X-BigFish: VS-2(zz98dI1432Izz1202hzz8275dhz2dh2a8h668h839h944hd24he5bhf0ah107ah) Received: from mail68-ch1 (localhost.localdomain [127.0.0.1]) by mail68-ch1 (MessageSwitch) id 1341615386345311_5491; Fri, 6 Jul 2012 22:56:26 +0000 (UTC) Received: from CH1EHSMHS001.bigfish.com (snatpool2.int.messaging.microsoft.com [10.43.68.236]) by mail68-ch1.bigfish.com (Postfix) with ESMTP id 487E94C0218; Fri, 6 Jul 2012 22:56:26 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by CH1EHSMHS001.bigfish.com (10.43.70.1) with Microsoft SMTP Server (TLS) id 14.1.225.23; Fri, 6 Jul 2012 22:56:26 +0000 Received: from tx30smr01.am.freescale.net (10.81.153.31) by 039-SN1MMR1-002.039d.mgd.msft.net (10.84.1.15) with Microsoft SMTP Server (TLS) id 14.2.298.5; Fri, 6 Jul 2012 17:58:33 -0500 Received: from x9.am.freescale.net (x9.am.freescale.net [10.82.120.9]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with SMTP id q66MwUQM004529; Fri, 6 Jul 2012 15:58:30 -0700 Date: Fri, 6 Jul 2012 17:56:34 -0500 From: Kim Phillips To: Shawn Guo Subject: Re: [PATCH v2] rtc: snvs: add Freescale rtc-snvs driver Message-ID: <20120706175634.a98fb53a9a1fdf40bd4febb3@freescale.com> In-Reply-To: <20120706002254.GB20175@S2101-09.ap.freescale.net> References: <1341416294-3194-1-git-send-email-shawn.guo@linaro.org> <20120705182829.d13d6992406e02e1024552e3@freescale.com> <20120706002254.GB20175@S2101-09.ap.freescale.net> Organization: Freescale Semiconductor, Inc. X-Mailer: Sylpheed 3.2.0beta5 (GTK+ 2.24.10; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-OriginatorOrg: freescale.com X-Spam-Note: CRM114 invocation failed X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [216.32.181.186 listed in list.dnswl.org] -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Alessandro Zummo , Sascha Hauer , Stephen Boyd , linux-arm-kernel@lists.infradead.org, rtc-linux@googlegroups.com 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 Fri, 6 Jul 2012 08:22:56 +0800 Shawn Guo wrote: > On Thu, Jul 05, 2012 at 06:28:29PM -0500, Kim Phillips wrote: > > On Wed, 4 Jul 2012 23:38:14 +0800 > > Shawn Guo wrote: > > > > > +static const struct of_device_id __devinitconst snvs_dt_ids[] = { > > > + { .compatible = "fsl,sec-v4.0-mon-rtc-lp", }, > > > > the driver should be compatible with "fsl,sec-v4.0-mon", and its > > probe function search for "fsl,sec-v4.0-mon-rtc-lp" sub-compatibles > > (and possibly "fsl,sec-v4.0-mon-rtc-hp" in the future?). > > > So you think snvs is all about rtc (lp and hp), nothing else? If that no, I'm aware that it's more than a couple of RTCs. > is true, it's reasonable to do what you suggested here. Otherwise, we > should have a snvs driver be compatible with "fsl,sec-v4.0-mon", and > this driver should be responsible for populate all the sub-devices of > snvs, rtc-lp, rtc-hp, and others. In the latter case, rtc-snvs should > just stay as it stands right now. but it doesn't function as it stands right now, at least on Power. The compatible in the device tree's sec_mon node "fsl,sec-v4.0-mon" and the driver's "fsl,sec-v4.0-mon-rtc-lp" don't match. Here are the device tree changes I used: btw, I don't see any imx6q.dtsi changes. Kim diff --git a/arch/powerpc/boot/dts/fsl/qoriq-sec4.2-0.dtsi b/arch/powerpc/boot/dts/fsl/qoriq-sec4.2-0.dtsi index 7990e0d..14c933b 100644 --- a/arch/powerpc/boot/dts/fsl/qoriq-sec4.2-0.dtsi +++ b/arch/powerpc/boot/dts/fsl/qoriq-sec4.2-0.dtsi @@ -104,6 +104,14 @@ crypto: crypto@300000 { sec_mon: sec_mon@314000 { compatible = "fsl,sec-v4.2-mon", "fsl,sec-v4.0-mon"; + #address-cells = <1>; + #size-cells = <1>; + ranges = <0 0x314000 0x1000>; reg = <0x314000 0x1000>; interrupts = <93 2 0 0>; + + sec_mon_rtc_lp@34 { + compatible = "fsl,sec-v4.2-mon-rtc-lp", "fsl,sec-v4.0-mon-rtc-lp"; + reg = <0x34 0x58>; + }; };