From patchwork Thu Dec 13 18:51:02 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeykumar Sankaran X-Patchwork-Id: 10729629 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E303913BF for ; Thu, 13 Dec 2018 18:51:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D6E642C85C for ; Thu, 13 Dec 2018 18:51:10 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CB2E02C88B; Thu, 13 Dec 2018 18:51:10 +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=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 732F92C88C for ; Thu, 13 Dec 2018 18:51:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726533AbeLMSvK (ORCPT ); Thu, 13 Dec 2018 13:51:10 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:33086 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726453AbeLMSvJ (ORCPT ); Thu, 13 Dec 2018 13:51:09 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id D8FAC6071B; Thu, 13 Dec 2018 18:51:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1544727068; bh=W1y5LDdRCbhBY7ts/fkusokxmGWejB5+NX25RzKWS0w=; h=From:To:Cc:Subject:Date:From; b=mrDhau54rDHVUPQNObyZRG3fpKPZG/lKE0xGlOOXCqS1rGRi9w5qP2Y79o89fMnC7 80+S/lMP0uEB3eTh2ATQSlixYk2MJ1V4jg7ZmmAad8/KdWxx1tpj3vdxRTXc49PUWY pzRlQQMftrrB0xhS9lFSWYDW0o430jYchLwzpnX0= Received: from jeykumar-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jsanka@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 2CD9F602F8; Thu, 13 Dec 2018 18:51:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1544727068; bh=W1y5LDdRCbhBY7ts/fkusokxmGWejB5+NX25RzKWS0w=; h=From:To:Cc:Subject:Date:From; b=mrDhau54rDHVUPQNObyZRG3fpKPZG/lKE0xGlOOXCqS1rGRi9w5qP2Y79o89fMnC7 80+S/lMP0uEB3eTh2ATQSlixYk2MJ1V4jg7ZmmAad8/KdWxx1tpj3vdxRTXc49PUWY pzRlQQMftrrB0xhS9lFSWYDW0o430jYchLwzpnX0= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 2CD9F602F8 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=jsanka@codeaurora.org From: Jeykumar Sankaran To: dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, linux-arm-msm@vger.kernel.org Cc: Jeykumar Sankaran , seanpaul@chromium.org, robdclark@gmail.com, hoegsberg@google.com, jcrouse@codeaurora.org Subject: [PATCH v3 1/3] drm/msm/dpu: fix documentation for intf_type Date: Thu, 13 Dec 2018 10:51:02 -0800 Message-Id: <1544727064-26763-1-git-send-email-jsanka@codeaurora.org> X-Mailer: git-send-email 1.9.1 Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Fix intf_type description in msm_disp_info to show that it represents drm encoder mode of the display. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/msm_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/msm_drv.h b/drivers/gpu/drm/msm/msm_drv.h index 60a7da0..4b0ae70 100644 --- a/drivers/gpu/drm/msm/msm_drv.h +++ b/drivers/gpu/drm/msm/msm_drv.h @@ -119,7 +119,7 @@ struct msm_display_topology { /** * struct msm_display_info - defines display properties - * @intf_type: DRM_MODE_CONNECTOR_ display type + * @intf_type: DRM_MODE_ENCODER_ type * @capabilities: Bitmask of display flags * @num_of_h_tiles: Number of horizontal tiles in case of split interface * @h_tile_instance: Controller instance used per tile. Number of elements is From patchwork Thu Dec 13 18:51:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeykumar Sankaran X-Patchwork-Id: 10729633 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DEE233E9D for ; Thu, 13 Dec 2018 18:51:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D39952C88E for ; Thu, 13 Dec 2018 18:51:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BEAEE2C88D; Thu, 13 Dec 2018 18:51:12 +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=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 5C5962C88E for ; Thu, 13 Dec 2018 18:51:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727417AbeLMSvL (ORCPT ); Thu, 13 Dec 2018 13:51:11 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:33178 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726453AbeLMSvL (ORCPT ); Thu, 13 Dec 2018 13:51:11 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 1D93460740; Thu, 13 Dec 2018 18:51:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1544727070; bh=bG8xNfRtN25DWFKF6e6zW7nux0kZHYRzO31OtPAjKP0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RZcd5zwQYTZvzXVVndfuI9t2NumrRMn/l6n6KLYVTIHJ9KTb9LJ8ruv3g6QHgFaS1 IVF2VmXI6bXJ8L1bCngQY9lN6SU1ZbdTroyXOYEzdglkmXyocM2isGv4oGSd6sDhlx NrZsnLo6evv7jt9vsdX/tQI8dRy9XExA2eiShAeQ= Received: from jeykumar-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jsanka@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 53B6960795; Thu, 13 Dec 2018 18:51:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1544727069; bh=bG8xNfRtN25DWFKF6e6zW7nux0kZHYRzO31OtPAjKP0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=j0fqpbj2cDeaEwBt7ETK6XQ3pZtSVAbA+3O3v83IxllbglN3x4yzpnC2o8+I+DAn2 A5GNAsloMyj3DfmgtRJFfosRO02Z7CQCpTBXY+g7MfTfL9U1uFEznMa+fa0mtZW7Ky xNBA/FdrObSqqG8H5qhOVmRsj+WBv1Fd/ICHcpgE= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 53B6960795 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=jsanka@codeaurora.org From: Jeykumar Sankaran To: dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, linux-arm-msm@vger.kernel.org Cc: Jeykumar Sankaran , seanpaul@chromium.org, robdclark@gmail.com, hoegsberg@google.com, jcrouse@codeaurora.org Subject: [PATCH v3 2/3] drm/msm/dpu: handle failures while initializing displays Date: Thu, 13 Dec 2018 10:51:03 -0800 Message-Id: <1544727064-26763-2-git-send-email-jsanka@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1544727064-26763-1-git-send-email-jsanka@codeaurora.org> References: <1544727064-26763-1-git-send-email-jsanka@codeaurora.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Bail out KMS hw init on display initialization failures with proper error logging. changes in v3: - introduced in the series Signed-off-by: Jeykumar Sankaran --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 39 +++++++++++++++++++++++---------- 1 file changed, 27 insertions(+), 12 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c index 685686e..39c8549 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c @@ -405,33 +405,36 @@ static void dpu_kms_wait_for_commit_done(struct msm_kms *kms, } } -static void _dpu_kms_initialize_dsi(struct drm_device *dev, +static int _dpu_kms_initialize_dsi(struct drm_device *dev, struct msm_drm_private *priv, struct dpu_kms *dpu_kms) { struct drm_encoder *encoder = NULL; - int i, rc; + int i, rc = 0; + + if (!(priv->dsi[0] || priv->dsi[1])) + return rc; /*TODO: Support two independent DSI connectors */ encoder = dpu_encoder_init(dev, DRM_MODE_ENCODER_DSI); - if (IS_ERR_OR_NULL(encoder)) { + if (IS_ERR(encoder)) { DPU_ERROR("encoder init failed for dsi display\n"); - return; + return PTR_ERR(encoder); } for (i = 0; i < ARRAY_SIZE(priv->dsi); i++) { - if (!priv->dsi[i]) { - DPU_DEBUG("invalid msm_dsi for ctrl %d\n", i); - return; - } + if (!priv->dsi[i]) + continue; rc = msm_dsi_modeset_init(priv->dsi[i], dev, encoder); if (rc) { DPU_ERROR("modeset_init failed for dsi[%d], rc = %d\n", i, rc); - continue; + return rc; } } + + return rc; } /** @@ -442,16 +445,24 @@ static void _dpu_kms_initialize_dsi(struct drm_device *dev, * @dpu_kms: Pointer to dpu kms structure * Returns: Zero on success */ -static void _dpu_kms_setup_displays(struct drm_device *dev, +static int _dpu_kms_setup_displays(struct drm_device *dev, struct msm_drm_private *priv, struct dpu_kms *dpu_kms) { - _dpu_kms_initialize_dsi(dev, priv, dpu_kms); + int rc = 0; + + rc = _dpu_kms_initialize_dsi(dev, priv, dpu_kms); + if (rc) { + DPU_ERROR("failed to initialize dsi, rc = %d\n", rc); + return rc; + } /** * Extend this function to initialize other * types of displays */ + + return rc; } static void _dpu_kms_drm_obj_destroy(struct dpu_kms *dpu_kms) @@ -517,7 +528,11 @@ static int _dpu_kms_drm_obj_init(struct dpu_kms *dpu_kms) * Create encoder and query display drivers to create * bridges and connectors */ - _dpu_kms_setup_displays(dev, priv, dpu_kms); + ret = _dpu_kms_setup_displays(dev, priv, dpu_kms); + if (ret) { + DPU_ERROR("failed to setup display, rc = %d\n", ret); + goto fail; + } max_crtc_count = min(catalog->mixer_count, (u32)dev->mode_config.num_encoder); From patchwork Thu Dec 13 18:51:04 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeykumar Sankaran X-Patchwork-Id: 10729635 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2D93B14E2 for ; Thu, 13 Dec 2018 18:51:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 213992C887 for ; Thu, 13 Dec 2018 18:51:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 159D02C885; Thu, 13 Dec 2018 18:51:13 +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=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 8F8572C888 for ; Thu, 13 Dec 2018 18:51:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726453AbeLMSvM (ORCPT ); Thu, 13 Dec 2018 13:51:12 -0500 Received: from smtp.codeaurora.org ([198.145.29.96]:33362 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727296AbeLMSvL (ORCPT ); Thu, 13 Dec 2018 13:51:11 -0500 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 7235C607BA; Thu, 13 Dec 2018 18:51:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1544727071; bh=zblgWsekb0AJdXPkvCbMewnNvsUDP3iR4tDMAo7mCag=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IVkVHlFt8PCMqL2qsppAAfty/DyYSwt5vtC3RqrnR6uaR6QhGLGsd/WQCs9xMn81p GVvgpczuGUhOu4tULlUqVoTBe4xXLtJZityc6gZt6hu5g5Ac2QkCCnmMGjzrCvZzXA Dk8OolZYVZ1mWIFZ2EFrFmBmGp2trkdlrM01yf7E= Received: from jeykumar-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jsanka@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 2B98A607BA; Thu, 13 Dec 2018 18:51:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1544727070; bh=zblgWsekb0AJdXPkvCbMewnNvsUDP3iR4tDMAo7mCag=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BhEICdoQyK2GmOyVTAhCj4HZtEov9QdZdiBftVP2Nvi3EpFqBaD1E6ZoRkxDd0WnV MKRzm+btFIUgr2tqgtN0qlkoCQfmZtJwjtLHoAxubVXpIqAM7Sq3F1wwllr6rPrElI PgEZ2742rtemhJHZlgj6TYBhZ4VtFRkE4ARbRu6k= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 2B98A607BA 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=jsanka@codeaurora.org From: Jeykumar Sankaran To: dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, linux-arm-msm@vger.kernel.org Cc: Jeykumar Sankaran , seanpaul@chromium.org, robdclark@gmail.com, hoegsberg@google.com, jcrouse@codeaurora.org Subject: [PATCH v3 3/3] drm/msm/dpu: add display port support in DPU Date: Thu, 13 Dec 2018 10:51:04 -0800 Message-Id: <1544727064-26763-3-git-send-email-jsanka@codeaurora.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1544727064-26763-1-git-send-email-jsanka@codeaurora.org> References: <1544727064-26763-1-git-send-email-jsanka@codeaurora.org> Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add display port support in DPU by creating hooks for DP encoder enumeration and encoder mode initialization. This change is based on the SDM845 Display port driver changes[1]. changes in v2: - rebase on [2] (Sean Paul) - remove unwanted error checks and switch cases (Jordan Crouse) changes in v3: - add dp support after fixing the current code base for error logging (Sean Paul) [1] https://lwn.net/Articles/768265/ [2] https://lkml.org/lkml/2018/11/17/87 Signed-off-by: Jeykumar Sankaran Reviewed-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 8 ++--- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 51 +++++++++++++++++++++++++---- 2 files changed, 49 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c index 36158b7..b79fd9d 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c @@ -2029,7 +2029,7 @@ static int dpu_encoder_setup_display(struct dpu_encoder_virt *dpu_enc, { int ret = 0; int i = 0; - enum dpu_intf_type intf_type; + enum dpu_intf_type intf_type = INTF_NONE; struct dpu_enc_phys_init_params phys_params; if (!dpu_enc || !dpu_kms) { @@ -2052,9 +2052,9 @@ static int dpu_encoder_setup_display(struct dpu_encoder_virt *dpu_enc, case DRM_MODE_ENCODER_DSI: intf_type = INTF_DSI; break; - default: - DPU_ERROR_ENC(dpu_enc, "unsupported display interface type\n"); - return -EINVAL; + case DRM_MODE_ENCODER_TMDS: + intf_type = INTF_DP; + break; } WARN_ON(disp_info->num_of_h_tiles < 1); diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c index 39c8549..ba3e75c 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c @@ -437,6 +437,32 @@ static int _dpu_kms_initialize_dsi(struct drm_device *dev, return rc; } +static int _dpu_kms_initialize_displayport(struct drm_device *dev, + struct msm_drm_private *priv, + struct dpu_kms *dpu_kms) +{ + struct drm_encoder *encoder = NULL; + int rc = 0; + + if (!priv->dp) + return rc; + + encoder = dpu_encoder_init(dev, DRM_MODE_ENCODER_TMDS); + if (IS_ERR(encoder)) { + DPU_ERROR("encoder init failed for dsi display\n"); + return PTR_ERR(encoder); + } + + rc = msm_dp_modeset_init(priv->dp, dev, encoder); + if (rc) { + DPU_ERROR("modeset_init failed for DP, rc = %d\n", rc); + drm_encoder_cleanup(encoder); + return rc; + } + + return rc; +} + /** * _dpu_kms_setup_displays - create encoders, bridges and connectors * for underlying displays @@ -457,6 +483,12 @@ static int _dpu_kms_setup_displays(struct drm_device *dev, return rc; } + rc = _dpu_kms_initialize_displayport(dev, priv, dpu_kms); + if (rc) { + DPU_ERROR("failed to initialize display port, rc = %d\n", rc); + return rc; + } + /** * Extend this function to initialize other * types of displays @@ -675,13 +707,20 @@ static void _dpu_kms_set_encoder_mode(struct msm_kms *kms, info.capabilities = cmd_mode ? MSM_DISPLAY_CAP_CMD_MODE : MSM_DISPLAY_CAP_VID_MODE; - /* TODO: No support for DSI swap */ - for (i = 0; i < ARRAY_SIZE(priv->dsi); i++) { - if (priv->dsi[i]) { - info.h_tile_instance[info.num_of_h_tiles] = i; - info.num_of_h_tiles++; + switch (info.intf_type) { + case DRM_MODE_ENCODER_DSI: + /* TODO: No support for DSI swap */ + for (i = 0; i < ARRAY_SIZE(priv->dsi); i++) { + if (priv->dsi[i]) { + info.h_tile_instance[info.num_of_h_tiles] = i; + info.num_of_h_tiles++; + } } - } + break; + case DRM_MODE_ENCODER_TMDS: + info.num_of_h_tiles = 1; + break; + }; rc = dpu_encoder_setup(encoder->dev, encoder, &info); if (rc)