From patchwork Thu Feb 15 10:19:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 10220811 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 05EAE601E7 for ; Thu, 15 Feb 2018 10:20:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E4FAF2910C for ; Thu, 15 Feb 2018 10:20:28 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D613B2911B; Thu, 15 Feb 2018 10:20:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D36242910C for ; Thu, 15 Feb 2018 10:20:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755426AbeBOKUG (ORCPT ); Thu, 15 Feb 2018 05:20:06 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:36696 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755421AbeBOKUF (ORCPT ); Thu, 15 Feb 2018 05:20:05 -0500 Received: by mail-wm0-f67.google.com with SMTP id f3so26922328wmc.1 for ; Thu, 15 Feb 2018 02:20:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=42RAbqlGHCZ4eIhegJR7hwQMHc57dkSzwnjgxZb5CN0=; b=jP1i990qx76Nq19uYMNaGP8I9iMy4BinnUSIDNVqxCEhVYG/BCGMbv2BqBB/RbHH8Y 5lNq80x0uhd4HR/NQ/+kOB3lxwHtabl5lLtn20ZiInd+dmyfcYpJ6HA9+5wNFFAV7R1u /SuEfBHRZUBt4tf3Bl+hVPAla0mw5MgLV47f2XjDmWE28XDp6kMPS/wl+3aPEpREeDg7 2bmQHEKGavjI3ACbJ0FxXP2XRhpplzeXrrv9a95vJ7URSxStMFHgY01MRgVAvwcbA3L4 joudoaj/5sImGBE9O+pi6Y3QKNZRU38ukzjYSkI9bNZS/3CMWLjoYNBjNC93+E3EUtQn aeuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=42RAbqlGHCZ4eIhegJR7hwQMHc57dkSzwnjgxZb5CN0=; b=RPRmmoMjGBltt+jjuVoRcpQUHqL8eCHMqv00ESZDQpTcb6fQDJlPqsGaTXO838Y/UR mK6Hw1kF8WYHCSIbxB2e56FFKYk73N2kaMie479kVAsjEm8wnzmEXvBlV/v5lFF9V9Yo ksBjwZOE7cARzjdeh+rtXAPeURrisZk5m0ZRg1/DX2JYy/MO57X1gEi2uzxUyCencaUQ nGG/EIusnhzH6Knoouj2DBwmviO1IIVRW5+iiK0GxFlLVkgV5mQ5ZKhetDRNn8Mg0B2P xCESLo53+D33CYNzTMpHik2DYO8+2xZomUIs27DZPlFFRVfHBOdggTLc1K74DY7kESmC 7LAA== X-Gm-Message-State: APf1xPArAhBgooapQGumSgYn7J06Psh3gvAYSiSXBRCFtTW2A5bXw3r0 AAE59+s60PdbGqwTQFl7ItJd1Q== X-Google-Smtp-Source: AH8x225dfJ0w6C26vwD7H8R5ikuSHSRBL7RzJuL9AHqhxkdHxMDmlBZ25y7sQSj4XtmKVMrCxfqLvA== X-Received: by 10.28.32.5 with SMTP id g5mr1512492wmg.62.1518690003896; Thu, 15 Feb 2018 02:20:03 -0800 (PST) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id j77sm26128745wmf.37.2018.02.15.02.20.03 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 15 Feb 2018 02:20:03 -0800 (PST) From: Jerome Brunet To: Michael Turquette , Stephen Boyd Cc: Jerome Brunet , linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] clk: fix phase reported being zero Date: Thu, 15 Feb 2018 11:19:58 +0100 Message-Id: <20180215101958.22676-1-jbrunet@baylibre.com> X-Mailer: git-send-email 2.14.3 Sender: linux-clk-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-clk@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP While introducing clk_core_set_phase_nolock, assigning core->phase was mistakenly removed. Fixing this now Fixes: 9e4d04adeb1a ("clk: add clk_core_set_phase_nolock function") Signed-off-by: Jerome Brunet --- drivers/clk/clk.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c index 9d56be6ead39..b33d362239e7 100644 --- a/drivers/clk/clk.c +++ b/drivers/clk/clk.c @@ -2314,6 +2314,9 @@ static int clk_core_set_phase_nolock(struct clk_core *core, int degrees) if (core->ops->set_phase) ret = core->ops->set_phase(core->hw, degrees); + if (!ret) + core->phase = degrees; + trace_clk_set_phase_complete(core, degrees); return ret;