Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp298290pxa; Wed, 19 Aug 2020 01:19:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0E0DNDzw5ix6st18TudEPNLt4u+tW0WZ8n8sUrgij1+gp3daTfuXagly+g4zIgaiKUtwU X-Received: by 2002:a50:99cf:: with SMTP id n15mr22653014edb.352.1597825181914; Wed, 19 Aug 2020 01:19:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597825181; cv=none; d=google.com; s=arc-20160816; b=wuCUdfx+banJ/OP6bw1C6vdA3HGzNa0jIQGhA7gP+PRS4SmT/woeN+/rMi7/Dsjc+T 4JNn+DlGwfQ1K5TT4lRKlUrRBXQ3aT40nEtmQ7zvVES87Pq29hC/90sodgHGfptpDACp EWvH6pB4WtDE6IPkP8iNvLU5Iox6y7x9y0wu9zXYxAAnngCYpeQr8u2KQ9SCV6ZCF9Hu tE/3XDGNiZ5/VY3HIpnkJx4SEThBEKKeLsMegbNB56eWU9I+SPR5UetwJ7odoOPAftPg I1HGfbKmP6PSMO6GpaIRtxIM5kJuX0kX3VFFsg3gQeY3Sndcz23bs2BPfwu662JvHJtu 2zZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ds7XnKX+bqH2VkRPifcHXESaPz03te6uVWAvUOl32R0=; b=KbxB+T5eoyVZmeTuBm/gg6N+jCSXDtVh2/1CZyNeATtlswc5TQbi0ick73/OHgXq6y asg8bBzxbwZ6RH1mwgkwLLLVpQgD+a5BOTbbrBDe0/C/RyPUJ7gXppNoK02URSZfuHbs 5HcWqy/E1AS+CBhZygeuypBiVMIJcYLfzL4v/FR5+m3BebLp1Qfksx1KbUKOlFyM2RUJ 0wZXxsxa4x3aP5ozVYQVGsbWfZFA0SjqTDrWfbrP7GKSULhGuaPMnEvVmm6LkOQ+hDga 3SxTRqhUnaeD9qIe5B9bcWn6vFLyCrrGHLLIDU8TSL5mIcXZfZPQyRQwx3jAlqyDtgQb jxhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mailerdienst.de header.s=20200217 header.b=ySkla1aR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j7si18300056ejo.66.2020.08.19.01.19.18; Wed, 19 Aug 2020 01:19:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@mailerdienst.de header.s=20200217 header.b=ySkla1aR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726863AbgHSIS3 (ORCPT + 99 others); Wed, 19 Aug 2020 04:18:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49196 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726531AbgHSISD (ORCPT ); Wed, 19 Aug 2020 04:18:03 -0400 Received: from mxout2.routing.net (mxout2.routing.net [IPv6:2a03:2900:1:a::b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9E4ABC061342 for ; Wed, 19 Aug 2020 01:18:02 -0700 (PDT) Received: from mxbox2.masterlogin.de (unknown [192.168.10.89]) by mxout2.routing.net (Postfix) with ESMTP id 9A3CA5FA67; Wed, 19 Aug 2020 08:18:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailerdienst.de; s=20200217; t=1597825080; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ds7XnKX+bqH2VkRPifcHXESaPz03te6uVWAvUOl32R0=; b=ySkla1aRE7AZ2s0mZi8YaD3ILgpg37tqRiYTVDFQ+thqdhkAktB8/FvChqSSGS9fjg1EcP FcDHwoXH4qKxAs0A9XJse9fzm6Vgq0rCb7n4s4CFKD9cg2SQFJdk09/uWbi4M6dW3F00of fceqAWRMJ6awtSfuakJ30cBNxzZIqlI= Received: from localhost.localdomain (fttx-pool-185.76.97.101.bambit.de [185.76.97.101]) by mxbox2.masterlogin.de (Postfix) with ESMTPSA id E571310058A; Wed, 19 Aug 2020 08:17:59 +0000 (UTC) From: Frank Wunderlich To: linux-mediatek@lists.infradead.org Cc: Frank Wunderlich , Chun-Kuang Hu , Philipp Zabel , David Airlie , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Daniel Vetter , Matthias Brugger , linux-arm-kernel@lists.infradead.org Subject: [PATCH v5 2/7] drm/mediatek: add ddp routing for mt7623 Date: Wed, 19 Aug 2020 10:17:47 +0200 Message-Id: <20200819081752.4805-3-linux@fw-web.de> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200819081752.4805-1-linux@fw-web.de> References: <20200819081752.4805-1-linux@fw-web.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Frank Wunderlich on BPi-R2/mt7623 main-path have to be routed to DPI0 (hdmi) instead of DSI0 using compatible "mt7623-mmsys" already defined in dts Signed-off-by: Frank Wunderlich Reviewed-by: Chun-Kuang Hu --- drivers/gpu/drm/mediatek/mtk_drm_drv.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_drm_drv.c b/drivers/gpu/drm/mediatek/mtk_drm_drv.c index 040a8f393fe2..2350e3200b59 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_drv.c +++ b/drivers/gpu/drm/mediatek/mtk_drm_drv.c @@ -74,6 +74,19 @@ static const enum mtk_ddp_comp_id mt2701_mtk_ddp_ext[] = { DDP_COMPONENT_DPI0, }; +static const enum mtk_ddp_comp_id mt7623_mtk_ddp_main[] = { + DDP_COMPONENT_OVL0, + DDP_COMPONENT_RDMA0, + DDP_COMPONENT_COLOR0, + DDP_COMPONENT_BLS, + DDP_COMPONENT_DPI0, +}; + +static const enum mtk_ddp_comp_id mt7623_mtk_ddp_ext[] = { + DDP_COMPONENT_RDMA1, + DDP_COMPONENT_DSI0, +}; + static const enum mtk_ddp_comp_id mt2712_mtk_ddp_main[] = { DDP_COMPONENT_OVL0, DDP_COMPONENT_COLOR0, @@ -127,6 +140,14 @@ static const struct mtk_mmsys_driver_data mt2701_mmsys_driver_data = { .shadow_register = true, }; +static const struct mtk_mmsys_driver_data mt7623_mmsys_driver_data = { + .main_path = mt7623_mtk_ddp_main, + .main_len = ARRAY_SIZE(mt7623_mtk_ddp_main), + .ext_path = mt7623_mtk_ddp_ext, + .ext_len = ARRAY_SIZE(mt7623_mtk_ddp_ext), + .shadow_register = true, +}; + static const struct mtk_mmsys_driver_data mt2712_mmsys_driver_data = { .main_path = mt2712_mtk_ddp_main, .main_len = ARRAY_SIZE(mt2712_mtk_ddp_main), @@ -422,6 +443,8 @@ static const struct of_device_id mtk_ddp_comp_dt_ids[] = { static const struct of_device_id mtk_drm_of_ids[] = { { .compatible = "mediatek,mt2701-mmsys", .data = &mt2701_mmsys_driver_data}, + { .compatible = "mediatek,mt7623-mmsys", + .data = &mt7623_mmsys_driver_data}, { .compatible = "mediatek,mt2712-mmsys", .data = &mt2712_mmsys_driver_data}, { .compatible = "mediatek,mt8173-mmsys", -- 2.25.1