From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752117AbeAJWDh (ORCPT + 1 other); Wed, 10 Jan 2018 17:03:37 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:39902 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751097AbeAJWDf (ORCPT ); Wed, 10 Jan 2018 17:03:35 -0500 DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 546BB60724 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=sboyd@codeaurora.org Date: Wed, 10 Jan 2018 14:03:33 -0800 From: Stephen Boyd To: David Lechner Cc: linux-clk@vger.kernel.org, Michael Turquette , linux-kernel@vger.kernel.org Subject: Re: [PATCH] clk: divider: fix clk_round_rate() when CLK_DIVIDER_READ_ONLY && CLK_RATE_SET_PARENT Message-ID: <20180110220333.GF28313@codeaurora.org> References: <1515262769-22665-1-git-send-email-david@lechnology.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1515262769-22665-1-git-send-email-david@lechnology.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: On 01/06, David Lechner wrote: > clk_round_rate() 'answers the question "if I were to pass @rate to > clk_set_rate(), what clock rate would I end up with?" without changing > the hardware'. > > Currently, clk_divider_round_rate() returns the "current value" when > divider->flags & CLK_DIVIDER_READ_ONLY. But, if CLK_SET_RATE_PARENT is > set, then clk_set_rate() is supposed to propagate the rate change to the > parent clock. So, we need to do check for CLK_SET_RATE_PARENT and if it > is set, ask the parent clock what rate it can provide given the current > divider value. > > Signed-off-by: David Lechner Jerome sent a patch the day before that probably addresses the same thing. See the message-id of 20180105170959.17266-2-jbrunet@baylibre.com for more info. -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project