From patchwork Wed Jul 19 15:25:25 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Philipp Zabel X-Patchwork-Id: 9852403 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 99776602BD for ; Wed, 19 Jul 2017 15:28:43 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 870E8285E0 for ; Wed, 19 Jul 2017 15:28:43 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7B792285F5; Wed, 19 Jul 2017 15:28:43 +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 [65.50.211.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 19F16285E0 for ; Wed, 19 Jul 2017 15:28:43 +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=9tYvoQW84M/kynMKMU1Oi7D62+7a7MXNW1umQjSCQe4=; b=GwSNswimlb6tQelfwrfGy9as4C HwEZNvZAuZxUsO3fRdBVsfh+RMXhpSSbSLTLbys8nDn/rwCbZFgm3rdgHGGnz3se91NMj2wWbO9f8 AvEm5HHlSPQGqI/CG6fH6yc9ueWNoDZdM0YWR0G+QSY1FS9bsxqiuiuFbBQYuoosqgqme58p58GWp n7cfYDOS0A4vDWKrvpi0wxor+vC+PjsnwgF6+GgXeQbfMuQ1fWMBUMFUytO1GGDxjitkM5LUZKbam KL8HnWS2iCHxq9yl3gK6b8gNfuljQ/RYT5DB9qEaGNtfihkOQ7ROqkfW8M+U+uFGSdkBltzW+88p+ 9y93/2mA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dXqu2-0001Fy-MU; Wed, 19 Jul 2017 15:28:42 +0000 Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dXqtx-00012s-1D for linux-rockchip@lists.infradead.org; Wed, 19 Jul 2017 15:28:40 +0000 Received: from dude.hi.pengutronix.de ([2001:67c:670:100:1d::7] helo=dude.pengutronix.de.) by metis.ext.pengutronix.de with esmtp (Exim 4.84_2) (envelope-from ) id 1dXqtW-0001si-Im; Wed, 19 Jul 2017 17:28:10 +0200 From: Philipp Zabel To: linux-kernel@vger.kernel.org Subject: [PATCH 021/102] drm/rockchip: explicitly request exclusive reset control Date: Wed, 19 Jul 2017 17:25:25 +0200 Message-Id: <20170719152646.25903-22-p.zabel@pengutronix.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170719152646.25903-1-p.zabel@pengutronix.de> References: <20170719152646.25903-1-p.zabel@pengutronix.de> X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::7 X-SA-Exim-Mail-From: p.zabel@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-rockchip@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170719_082837_348476_1F8ECFA7 X-CRM114-Status: GOOD ( 12.06 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-rockchip@lists.infradead.org, dri-devel@lists.freedesktop.org, Heiko Stuebner , Philipp Zabel , Mark Yao MIME-Version: 1.0 Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+patchwork-linux-rockchip=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Commit a53e35db70d1 ("reset: Ensure drivers are explicit when requesting reset lines") started to transition the reset control request API calls to explicitly state whether the driver needs exclusive or shared reset control behavior. Convert all drivers requesting exclusive resets to the explicit API call so the temporary transition helpers can be removed. No functional changes. Cc: Mark Yao Cc: Heiko Stuebner Cc: dri-devel@lists.freedesktop.org Cc: linux-rockchip@lists.infradead.org Signed-off-by: Philipp Zabel --- drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 2 +- drivers/gpu/drm/rockchip/cdn-dp-core.c | 8 ++++---- drivers/gpu/drm/rockchip/dw-mipi-dsi.c | 2 +- drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c index 9606121fa185a..172930e7645e7 100644 --- a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c +++ b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c @@ -297,7 +297,7 @@ static int rockchip_dp_init(struct rockchip_dp_device *dp) return PTR_ERR(dp->pclk); } - dp->rst = devm_reset_control_get(dev, "dp"); + dp->rst = devm_reset_control_get_exclusive(dev, "dp"); if (IS_ERR(dp->rst)) { dev_err(dev, "failed to get dp reset control\n"); return PTR_ERR(dp->rst); diff --git a/drivers/gpu/drm/rockchip/cdn-dp-core.c b/drivers/gpu/drm/rockchip/cdn-dp-core.c index 9b0b0588bbedb..b7f5c5d9f245d 100644 --- a/drivers/gpu/drm/rockchip/cdn-dp-core.c +++ b/drivers/gpu/drm/rockchip/cdn-dp-core.c @@ -765,25 +765,25 @@ static int cdn_dp_parse_dt(struct cdn_dp_device *dp) return PTR_ERR(dp->grf_clk); } - dp->spdif_rst = devm_reset_control_get(dev, "spdif"); + dp->spdif_rst = devm_reset_control_get_exclusive(dev, "spdif"); if (IS_ERR(dp->spdif_rst)) { DRM_DEV_ERROR(dev, "no spdif reset control found\n"); return PTR_ERR(dp->spdif_rst); } - dp->dptx_rst = devm_reset_control_get(dev, "dptx"); + dp->dptx_rst = devm_reset_control_get_exclusive(dev, "dptx"); if (IS_ERR(dp->dptx_rst)) { DRM_DEV_ERROR(dev, "no uphy reset control found\n"); return PTR_ERR(dp->dptx_rst); } - dp->core_rst = devm_reset_control_get(dev, "core"); + dp->core_rst = devm_reset_control_get_exclusive(dev, "core"); if (IS_ERR(dp->core_rst)) { DRM_DEV_ERROR(dev, "no core reset control found\n"); return PTR_ERR(dp->core_rst); } - dp->apb_rst = devm_reset_control_get(dev, "apb"); + dp->apb_rst = devm_reset_control_get_exclusive(dev, "apb"); if (IS_ERR(dp->apb_rst)) { DRM_DEV_ERROR(dev, "no apb reset control found\n"); return PTR_ERR(dp->apb_rst); diff --git a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c index 21b9737662ae9..c3501ae59db35 100644 --- a/drivers/gpu/drm/rockchip/dw-mipi-dsi.c +++ b/drivers/gpu/drm/rockchip/dw-mipi-dsi.c @@ -1221,7 +1221,7 @@ static int dw_mipi_dsi_bind(struct device *dev, struct device *master, * Note that the reset was not defined in the initial device tree, so * we have to be prepared for it not being found. */ - apb_rst = devm_reset_control_get(dev, "apb"); + apb_rst = devm_reset_control_get_exclusive(dev, "apb"); if (IS_ERR(apb_rst)) { ret = PTR_ERR(apb_rst); if (ret == -ENOENT) { diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c index 5d450332c2fd7..18b582cd81e50 100644 --- a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c +++ b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c @@ -1443,7 +1443,7 @@ static int vop_initial(struct vop *vop) /* * do hclk_reset, reset all vop registers. */ - ahb_rst = devm_reset_control_get(vop->dev, "ahb"); + ahb_rst = devm_reset_control_get_exclusive(vop->dev, "ahb"); if (IS_ERR(ahb_rst)) { dev_err(vop->dev, "failed to get ahb reset\n"); ret = PTR_ERR(ahb_rst); @@ -1469,7 +1469,7 @@ static int vop_initial(struct vop *vop) /* * do dclk_reset, let all config take affect. */ - vop->dclk_rst = devm_reset_control_get(vop->dev, "dclk"); + vop->dclk_rst = devm_reset_control_get_exclusive(vop->dev, "dclk"); if (IS_ERR(vop->dclk_rst)) { dev_err(vop->dev, "failed to get dclk reset\n"); ret = PTR_ERR(vop->dclk_rst);