From patchwork Mon Jun 7 21:39:09 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 455380 Delivered-To: patch@linaro.org Received: by 2002:a17:906:72d5:0:0:0:0 with SMTP id m21csp3662672ejl; Mon, 7 Jun 2021 14:39:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyx21fhZx+t1iVVaMcI695SnkLOmk2xvFo4Bfozw23Kr7SzkdDv5q5K7Yj2cM01d2l1XL4h X-Received: by 2002:a63:dd46:: with SMTP id g6mr15629965pgj.125.1623101955737; Mon, 07 Jun 2021 14:39:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623101955; cv=none; d=google.com; s=arc-20160816; b=ZJvhrREywBZlNqkmfy5Ae/jP5wFlubAR668/EnoJJonf15pQS+FuulQo37IJ/8wd2c 7y5X8xdIDlRZrGLG4OhLGmK8QiPPOHJ/QSOIgZXVM56FL9SCAzi+a4dZIkXHZjUhhLqJ YkWBT+USYE9yeSxdOmpYGJUun1bc84XOXlW4GZJ46pkDD7PYXBkLSFmLiaig9EK8c7Tq O4BRxDrWnCPqhUFl47N8zlCyk/ZuQMnRgzVLFsk7keUoWwdfuahGdtFU2zNTb3nDf2qD H+G8GnuUisEsod9d7QF8hGFidu55Jf9223CqyaJjqrOZnW2QRZensVFiXFzUSq/hua6p lTVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:to:from:dkim-signature :delivered-to; bh=u8CKvwSQLjjj+5EJDA8ATWx2yaOhMI1EEsNUtEuV8bk=; b=EF7Rt7YvV4pemyAiDHG904ONmW4/bENxMU/B0NXFzd/f+WI8hH4E0xkF3Dw1vDCgVD SvN6BhHJV64LU06MfbgCEngBuVySCbWF6M9PHGLkg4KhsbshMfxeX527SWYPSpfD83Ql BtP1b+LcIz1/TbMFHnImHPAwjmlXtUO2O5NNd9prjIDEkFmWUhO295XhWKcmyCXtA5Zv pXKuj4az/b5bc+HnL0TRIsSR+QUub1P8mt3YsQBvPS73HK8E0K1+hRAHLEIFX21NwuCq fP4UZgqrPyqb+TaoaeIw8sofLCZySqrgS7Z1c8FSOuGSgLTAS4K4y8Xc8c0jfHY05HcQ xgfQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=EE8BrWdn; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id d23si18653141pls.300.2021.06.07.14.39.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Jun 2021 14:39:15 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) client-ip=2610:10:20:722:a800:ff:fe36:1795; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=EE8BrWdn; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0E0766EA20; Mon, 7 Jun 2021 21:39:13 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lj1-x22e.google.com (mail-lj1-x22e.google.com [IPv6:2a00:1450:4864:20::22e]) by gabe.freedesktop.org (Postfix) with ESMTPS id BE55E6EA20 for ; Mon, 7 Jun 2021 21:39:11 +0000 (UTC) Received: by mail-lj1-x22e.google.com with SMTP id u18so4016655lju.12 for ; Mon, 07 Jun 2021 14:39:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=u8CKvwSQLjjj+5EJDA8ATWx2yaOhMI1EEsNUtEuV8bk=; b=EE8BrWdnOfaSRktSGtAbHGRjUb/zfSuaXZNayvdpAMV6+DhBqv7HwiJZ0qtfYNTipo lUc1kkM4MrYxw1Unia3/QlQHLVsp7W2Ei8iqe4/yzsfmKBtaWgEabb57y5gDrGw2jm92 hDCA6mfDG9VTnyL/IBIHWRuJRfu/0eL2bQUuypQ2OsMoh67O4c+Z1AdM9IDmn48oXrfS 3ZH5HeNa1Qz1koFEd+YVMvYjQJEw5tToGmVQIOPYbDhABy0MtXqGMKcyfCeoxlI+uXBz f1ea1+X7+bWPSZla4TFXywzmTYkDMi1Sk/G4JkL44zsIi5c4+9Gtv/MVafOuGuA3DiU/ 5y4A== 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:mime-version :content-transfer-encoding; bh=u8CKvwSQLjjj+5EJDA8ATWx2yaOhMI1EEsNUtEuV8bk=; b=nmLZxVMrsREcNSuofNf2MW9XXKVP3BQhsUZvDkHlN9qGcWvSNxcowrq2PNl01h6U71 6GoiT0xGREVrehOT934NFUroMZKsNurRQrakm0ug8AU5p9dboExHbs0ltuvXIataYejz ZfSE55HZUtRfRJ3+d7G8QQ8a2TiB2OgnqFun4qXRc5NcIyYxQXA75+jk/qst/avHVHkr jcqCqLOP87SaIWY9TroDsfRo/ERDy06OD262ekhOxq74r6y4uncbp/I7LNb4m97xX8Uk m5a+TfayMnMII5gJ9E1WpeSgDoFFbdODXN/jeC4rFKcZBesuRGeifIBjzfRx8h3MgZaB B2XA== X-Gm-Message-State: AOAM532jI+deln+eKy5v7k6X8B4gojZ9xOQfqSXTNzzU1+yP6r11JQzZ /MYMR4JCZDnPTWOVwMlju99CmA== X-Received: by 2002:a05:651c:38b:: with SMTP id e11mr15788576ljp.198.1623101950184; Mon, 07 Jun 2021 14:39:10 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id h22sm688111ljk.133.2021.06.07.14.39.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Jun 2021 14:39:09 -0700 (PDT) From: Dmitry Baryshkov To: Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar Subject: [PATCH] drm/msm/dsi: do not enable PHYs when called for the slave DSI interface Date: Tue, 8 Jun 2021 00:39:09 +0300 Message-Id: <20210607213909.2186556-1-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jonathan Marek , Stephen Boyd , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, David Airlie , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Move the call to dsi_mgr_phy_enable after checking whether the DSI interface is slave, so that PHY enablement happens together with the host enablement. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dsi/dsi_manager.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.30.2 diff --git a/drivers/gpu/drm/msm/dsi/dsi_manager.c b/drivers/gpu/drm/msm/dsi/dsi_manager.c index cc18ea2b244c..d77693904a15 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_manager.c +++ b/drivers/gpu/drm/msm/dsi/dsi_manager.c @@ -374,14 +374,14 @@ static void dsi_mgr_bridge_pre_enable(struct drm_bridge *bridge) if (!msm_dsi_device_connected(msm_dsi)) return; - ret = dsi_mgr_phy_enable(id, phy_shared_timings); - if (ret) - goto phy_en_fail; - /* Do nothing with the host if it is slave-DSI in case of dual DSI */ if (is_dual_dsi && !IS_MASTER_DSI_LINK(id)) return; + ret = dsi_mgr_phy_enable(id, phy_shared_timings); + if (ret) + goto phy_en_fail; + ret = msm_dsi_host_power_on(host, &phy_shared_timings[id], is_dual_dsi, msm_dsi->phy); if (ret) { pr_err("%s: power on host %d failed, %d\n", __func__, id, ret);