From patchwork Mon Mar 21 16:29:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sui Jingfeng <15330273260@189.cn> X-Patchwork-Id: 12787532 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E24F7C433EF for ; Mon, 21 Mar 2022 16:30:01 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 06F4810E3A1; Mon, 21 Mar 2022 16:30:01 +0000 (UTC) Received: from 189.cn (ptr.189.cn [183.61.185.104]) by gabe.freedesktop.org (Postfix) with ESMTP id 111EE10E3CF for ; Mon, 21 Mar 2022 16:29:59 +0000 (UTC) HMM_SOURCE_IP: 10.64.8.43:55736.678671471 HMM_ATTACHE_NUM: 0000 HMM_SOURCE_TYPE: SMTP Received: from clientip-114.242.206.180 (unknown [10.64.8.43]) by 189.cn (HERMES) with SMTP id B0B891002A6; Tue, 22 Mar 2022 00:29:54 +0800 (CST) Received: from ([114.242.206.180]) by gateway-151646-dep-b7fbf7d79-vjdjk with ESMTP id d23863fc0f3a4a70b7ff6078ead2ba9e for mripard@kernel.org; Tue, 22 Mar 2022 00:29:57 CST X-Transaction-ID: d23863fc0f3a4a70b7ff6078ead2ba9e X-Real-From: 15330273260@189.cn X-Receive-IP: 114.242.206.180 X-MEDUSA-Status: 0 From: Sui Jingfeng <15330273260@189.cn> To: Maxime Ripard , Thomas Zimmermann , Roland Scheidegger , Zack Rusin , Christian Gmeiner , David Airlie , Daniel Vetter , Rob Herring , Thomas Bogendoerfer , Dan Carpenter , Krzysztof Kozlowski , Andrey Zhizhikin , Sam Ravnborg , "David S . Miller" , Jiaxun Yang , Lucas Stach , Maarten Lankhorst , Ilia Mirkin , Qing Zhang , suijingfeng Subject: [PATCH v11 4/7] MIPS: Loongson64: dts: introduce ls2k1000 pai evaluation board Date: Tue, 22 Mar 2022 00:29:13 +0800 Message-Id: <20220321162916.1116541-5-15330273260@189.cn> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220321162916.1116541-1-15330273260@189.cn> References: <20220321162916.1116541-1-15330273260@189.cn> 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: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: suijingfeng ___________________ ____________________ | -------| | | | CRTC0 --> | DVO0 ------------------------> | 1024x600 DPI Panel | | _ _ -------| | Which panel to use |____________________| | | | | | | | with this board is a ___________________ | |_| |_| | | choice of the user | | | | +--------------------> | 800x480 DPI Panel | | DC In LS2K1000 | |___________________| | _ _ | +------+ | | | | | <---->| i2c1 |-----------+ | |_| |_| | +------+ | | | | | _________ | -------| +---------+ | | | | CRTC1 --> | DVO1 ---> | sii9022 | --> HDMI connector --> | Monitor | | -------| +---------+ |_________| |___________________| The sii9022 HDMI transmitter working in transparent mode, in this case the edid is read from the monitor directly, not through sil9022's ddc channel. The PMON[2] firmware of this board is responsible for configure the sii9022 encoder at boot time. Due to i2c driver for lsk2000 SoC is not upstream yet, we simply replace the sii9022 with a 1024x768 panel. The i2c0 is not get used by lsdc driver for this board, so there no need to worry about DVO0. [1] https://wiki.debian.org/InstallingDebianOn/Lemote/Loongson2K1000 [2] https://github.com/loongson-community/pmon Signed-off-by: suijingfeng Signed-off-by: Sui Jingfeng <15330273260@189.cn> --- arch/mips/boot/dts/loongson/ls2k1000_pai.dts | 102 +++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 arch/mips/boot/dts/loongson/ls2k1000_pai.dts diff --git a/arch/mips/boot/dts/loongson/ls2k1000_pai.dts b/arch/mips/boot/dts/loongson/ls2k1000_pai.dts new file mode 100644 index 000000000000..0b0172d90677 --- /dev/null +++ b/arch/mips/boot/dts/loongson/ls2k1000_pai.dts @@ -0,0 +1,102 @@ +// SPDX-License-Identifier: GPL-2.0 + +/dts-v1/; + +#include "loongson64-2k1000.dtsi" + +/ { + model = "LS2K1000_PAI_UDB_V1.5"; + + panel: display@0 { + compatible = "hontron,070JII2135-A2", "panel-dpi"; + label = "LCD070CG1024600+DC21"; + + rotation = <0>; + width-mm = <86>; + height-mm = <154>; + + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + #address-cells = <1>; + #size-cells = <0>; + + panel_in: endpoint@0 { + reg = <0>; + remote-endpoint = <&dc_out_rgb0>; + }; + }; + + panel-timing { + clock-frequency = <51200000>; + hactive = <1024>; + vactive = <600>; + hsync-len = <4>; + hfront-porch = <160>; + hback-porch = <156>; + vfront-porch = <11>; + vback-porch = <23>; + vsync-len = <1>; + + hsync-active = <0>; + vsync-active = <0>; + de-active = <1>; + pixelclk-active = <1>; + }; + }; + + monitor: display@1 { + compatible = "panel-dpi"; + + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + #address-cells = <1>; + #size-cells = <0>; + + monitor_in: endpoint@0 { + reg = <0>; + remote-endpoint = <&dc_out_rgb1>; + }; + }; + + panel-timing { + clock-frequency = <65000000>; + hactive = <1024>; + vactive = <768>; + hfront-porch = <24>; + hsync-len = <136>; + hback-porch = <160>; + vfront-porch = <3>; + vback-porch = <6>; + vsync-len = <29>; + + hsync-active = <0>; + vsync-active = <0>; + de-active = <1>; + pixelclk-active = <1>; + }; + }; +}; + +&lsdc { + ports { + port@0 { + endpoint { + remote-endpoint = <&panel_in>; + }; + }; + + port@1 { + endpoint { + remote-endpoint = <&monitor_in>; + }; + }; + }; +};