From patchwork Fri Mar 30 15:28:53 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 10317949 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 D08466063D for ; Fri, 30 Mar 2018 15:34:31 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BEC4F2A30F for ; Fri, 30 Mar 2018 15:34:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B31C42A5DC; Fri, 30 Mar 2018 15:34:31 +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=-1.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 240652A5C5 for ; Fri, 30 Mar 2018 15:34:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=o7rb2n65pm3hl9IsNHsk8RA9blvmhgumActz7JByY/o=; b=h/o1aozws8s0MotJR0lC5O0Rtr QBVRPtrfH6nHKnBdJyM2i88Xzw12EJbLWobnxECpp1xEdS8/5vJARzcJhcTQk2mbEX4wFjRw7LYX6 MfAt+M8iu6tymvmmTfq3gO04pfRYtGgo4pb0LWR2luIf3RLViZvHuKpnj4/TNTI/tkNP8YUKCNIOs I2OoWQ1gTkkgLDjfz9ffC+ZlrwQ2pDw2UswhUdTIN3TfB6GpmC+8CWv4OkVVyNamuII9xoSWsRg/1 E8jvsGKHAZLmNubu47MflA7SMZfydu9ZOTbwir9epihB5fIZTOVPNAIwi4H4+Tc+RHuL1n2WnZDg9 eMJfe1Cg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1f1w2o-0007Qz-GB; Fri, 30 Mar 2018 15:34:22 +0000 Received: from mail-wm0-x242.google.com ([2a00:1450:400c:c09::242]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1f1vxv-0003YU-Cx for linux-arm-kernel@lists.infradead.org; Fri, 30 Mar 2018 15:29:20 +0000 Received: by mail-wm0-x242.google.com with SMTP id p9so16063892wmc.3 for ; Fri, 30 Mar 2018 08:29:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=MtOMzSr3r3e97ftAS0n9qBCzVj/Pbr6bpYWHVGqUXBY=; b=xzR1a0ATxbI5gpuwM8ovFb00w+VSAuey/88GRCPQmoSkzuCKCu0hYZF7uD2KWPhM52 YxOigRkK+e8GY/1CcjKTE9OifRetsHNNgJR6wmM5jOoMVORlEcJWyt+QJnabV5wMX+kz 2/a+ijuZEDRbmtW3myfM5M8uFm87O6HL9pE5oGV4SW3EWV82jBwH//1V2WqbBnqWecRV wDLSeDqUBN3qQkPBYoUoboZmeTKmfJ9paEB0DcnKgCRiLmNixlyXODR4QiNYwycNA/t5 h/DRO4KlID6Ac4jIFdfE+zy4E4lWR2nWQHWmXN1N+9VcE0DMWd1pkOL21NLeP3XLjzRI QN7g== 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:in-reply-to :references; bh=MtOMzSr3r3e97ftAS0n9qBCzVj/Pbr6bpYWHVGqUXBY=; b=hFy94TfmdvZ2MqnxWTjmxgMu7eN0ybiUjaKQIJxYvc42GLkWh9Y3/9dxP8OuSJ+RLA HOUVnmMLOMyK5u28HjOQhHLmZfjWH9nn7+LvuStAJu7bbsBd0lnc5WXtxhHAfCVAmy2+ 9Gf0FI2kfscnd+ywHsg5mgF5LwpKKuE0AYX6jO9ZVuOma7wRPrTjfaGHDXAyPwpokyWW DoBweOUdXbTkrJOJ3x+qM25Eh+G+U1dXraFTIgT5NdJ4M49KjcOJBV1DpZ/du1lqGJw8 l98mmgcXLwcTOLiij4k9nX6JLfBKKHUTsXIhYISHe6cezclUEKnb6v7rnTH0s3NrhVaH HrFQ== X-Gm-Message-State: AElRT7GtznFS2xt2l4MPpb879eV+yu1VHy7fOhF93YL8N0nnRirZZmL+ VjeiFEgpbKD6NpZwxAztYwi+ig== X-Google-Smtp-Source: AIpwx48pOSIvzY892HtfXjafWzulgE+h5hho9yLiKz6mHP/xnyQ4fzPN+QjTORN/xdgtM6qdJYYY1Q== X-Received: by 10.28.148.201 with SMTP id w192mr2610978wmd.112.1522423746964; Fri, 30 Mar 2018 08:29:06 -0700 (PDT) Received: from brgl-bgdev.baylibre.local ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id n49sm14429881wrn.90.2018.03.30.08.29.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 30 Mar 2018 08:29:06 -0700 (PDT) From: Bartosz Golaszewski To: Sekhar Nori , Kevin Hilman , Rob Herring , Mark Rutland , Russell King , David Lechner , Michael Turquette , Stephen Boyd , Ohad Ben-Cohen , Bjorn Andersson , Philipp Zabel Subject: [PATCH v5 5/8] remoteproc/davinci: prepare and unprepare the clock where needed Date: Fri, 30 Mar 2018 17:28:53 +0200 Message-Id: <20180330152856.12297-6-brgl@bgdev.pl> X-Mailer: git-send-email 2.16.3 In-Reply-To: <20180330152856.12297-1-brgl@bgdev.pl> References: <20180330152856.12297-1-brgl@bgdev.pl> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180330_082919_452703_23B04E6F X-CRM114-Status: GOOD ( 15.97 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Bartosz Golaszewski We're currently switching the platform to using the common clock framework. We need to explicitly prepare and unprepare the rproc clock. Signed-off-by: Bartosz Golaszewski Acked-by: Suman Anna Reviewed-by: David Lechner --- drivers/remoteproc/da8xx_remoteproc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/remoteproc/da8xx_remoteproc.c b/drivers/remoteproc/da8xx_remoteproc.c index 2b24291337b7..f134192922e0 100644 --- a/drivers/remoteproc/da8xx_remoteproc.c +++ b/drivers/remoteproc/da8xx_remoteproc.c @@ -149,9 +149,9 @@ static int da8xx_rproc_start(struct rproc *rproc) writel(rproc->bootaddr, drproc->bootreg); - ret = clk_enable(dsp_clk); + ret = clk_prepare_enable(dsp_clk); if (ret) { - dev_err(dev, "clk_enable() failed: %d\n", ret); + dev_err(dev, "clk_prepare_enable() failed: %d\n", ret); return ret; } @@ -165,7 +165,7 @@ static int da8xx_rproc_stop(struct rproc *rproc) struct da8xx_rproc *drproc = rproc->priv; davinci_clk_reset_assert(drproc->dsp_clk); - clk_disable(drproc->dsp_clk); + clk_disable_unprepare(drproc->dsp_clk); return 0; }