From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tomeu Vizoso Subject: Re: [PATCH v3 04/13] of: document new emc-timings subnode in nvidia,tegra124-car Date: Fri, 07 Nov 2014 14:10:57 +0100 Message-ID: <545CC4E1.4010605@collabora.com> References: <1414599796-30597-1-git-send-email-tomeu.vizoso@collabora.com> <1414599796-30597-5-git-send-email-tomeu.vizoso@collabora.com> <545B172C.4060105@nvidia.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: In-Reply-To: Sender: linux-tegra-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Rob Herring , Alexandre Courbot Cc: "linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , Javier Martinez Canillas , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , Kumar Gala , Stephen Warren , Thierry Reding , Alexandre Courbot , Peter De Schrijver , "devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" List-Id: devicetree@vger.kernel.org On 11/06/2014 04:12 PM, Rob Herring wrote: > On Thu, Nov 6, 2014 at 12:37 AM, Alexandre Courbot wrote: >> On 10/30/2014 01:22 AM, Tomeu Vizoso wrote: >>> #clock-cells = <1>; >>> #reset-cells = <1>; >>> }; >>> @@ -60,4 +83,23 @@ Example board file: >>> &tegra_car { >>> clocks = <&clk_32k> <&osc>; >>> }; >>> + >>> + clock@0,60006000 { >>> + emc-timings@3 { >>> + nvidia,ram-code = <3>; >>> + >>> + timing@12750000 { >>> + clock-frequency = <12750000>; >>> + nvidia,parent-clock-frequency = >>> <408000000>; >>> + clocks = <&tegra_car TEGRA124_CLK_PLL_P>; >>> + clock-names = "emc-parent"; > > Why do you need both clocks and hardcoded values? clock-frequency is > the desired freq you want to set TEGRA124_CLK_PLL_P to? For the EMC clock to run at 12.75 MHz, its parent should become TEGRA124_CLK_PLL_P and it has to be running at 408 MHz. > The clocks property really belongs as part of the memory controller > node or a memory device node. What would be the rationale for that? The clock provider needs to know what clock should become the parent of the EMC clock when changing rates. Thanks, Tomeu