From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752929AbbDCIgC (ORCPT ); Fri, 3 Apr 2015 04:36:02 -0400 Received: from mail-yh0-f50.google.com ([209.85.213.50]:33372 "EHLO mail-yh0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750747AbbDCIf4 (ORCPT ); Fri, 3 Apr 2015 04:35:56 -0400 MIME-Version: 1.0 In-Reply-To: <551E4B85.1000903@samsung.com> References: <1427961979-29477-1-git-send-email-k.kozlowski@samsung.com> <551D362B.90901@collabora.co.uk> <551E4B85.1000903@samsung.com> Date: Fri, 3 Apr 2015 10:35:56 +0200 X-Google-Sender-Auth: bC8AiL0x62UjcxlC5YPUGA5E4Co Message-ID: Subject: Re: [PATCH 1/2] ARM: EXYNOS: Get current parent clock for power domain on/off From: Krzysztof Kozlowski To: Andrzej Hajda Cc: Krzysztof Kozlowski , Javier Martinez Canillas , Kukjin Kim , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org, Marek Szyprowski Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2015-04-03 10:12 GMT+02:00 Andrzej Hajda : > On 04/02/2015 02:44 PM, Krzysztof Kozlowski wrote: >> 2015-04-02 14:29 GMT+02:00 Javier Martinez Canillas >> : >>> Hello Krzysztof, >>> >>> On 04/02/2015 10:06 AM, Krzysztof Kozlowski wrote: >>>> Using a fixed (by DTS) parent for clocks when turning on the power domain >>>> may introduce issues in other drivers. For example when such driver >>>> changes the parent during runtime and expects that he is the only place >>>> of such change. >>>> >>>> Do not rely entirely on DTS providing the fixed parent for such clocks. >>>> Instead if "pclkN" clock name is missing, grab a current parent of clock >>>> with clk_get_parent(). > > Hi Krzysztof, > > I wonder if it wouldn't be better to drop entirely pclks. Power domains > should save/restore its previous state, setting fixed parents on domain > resume can fool drivers as you described earlier. I wanted to preserve full backward compatibility (including behaviour compatibility). However I can't find valid reason to switch to some fixed clock after powering up domain so if there are not objections I will drop pclk entirely. Thanks! Krzysztof