From patchwork Tue Oct 20 17:42:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847531 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 311A11744 for ; Tue, 20 Oct 2020 17:43:26 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D78B821D6C for ; Tue, 20 Oct 2020 17:43:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Z9W6VLqC"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="wdF9uoO+" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D78B821D6C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=+RbJll7LmfP0z1GMfBoQi3kmCm9qBSv38VA9ZTMPqVU=; b=Z9W6VLqCpXDbFsxp5WqnAAaSI N0gj5W7hO4Low21QsKSlojuMlRZA1JSBamJTTRp58y2ZjfzSwwUCabIxqF57TbRhODkm2d/g374SW 8/D8zJOAhK9Oz3yLv/hP71Id8oKr5xieIdIcs1OfDXYhuRHKbDCvi8FpYTeKZ8Y7eEI5ZvzBkvCs6 QS3j90HoDN0VTaP6AVE/NK+1b75XBU3XeVgzJJrfx7FAHg2B18WE2Fz+0T62VcYAfpYRk9DYOrscX LYYArU4R02q/0hvIvMz/hcFhy85Yfy8UeQux4hdeJk70qFTqcxAeeFD9Hjl1TH1Sj0Ed0k1SyK5UK XfWnNoE5w==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfP-0006Z2-C0; Tue, 20 Oct 2020 17:43:23 +0000 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvf3-0006PR-HJ for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:04 +0000 Received: by mail-wm1-x344.google.com with SMTP id e2so2937609wme.1 for ; Tue, 20 Oct 2020 10:43:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=WPldaAln0wKV7enamBXwVRl5MAfLsITQC/GnZaAj1po=; b=wdF9uoO+Ykbhxvbj/BpimI1WuFHEdYHMfvhomEaYkckQkI4DtzI3Dr/dLEZjcQeH61 TRk+GZZuWg4DrKcU9BlaJP59g048zt5611B7itGSWHXYrjTwCTfLXo9cWlKuekgY5nqD F/Y9Srju0qajoPep+dnWtRxj+TIIc/6v7TTjeHY/qCzDyfC0wXVB24XYjeDA9guBd2T2 NoFzhVNKNZ8Cr1sBnaulV99aq8LB6POuSCaCZQPmoKyRyDzowb6anbSOS3ac6FCrS5gz tj42kqp7bAFF+RTciFBlHkcSGW3kblhffsApqgY4Udc4K5gJ3Y8YgApx54/WsQYGhUZ1 4SOg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=WPldaAln0wKV7enamBXwVRl5MAfLsITQC/GnZaAj1po=; b=afzrF6XSuHdrhy0rEtnXZocmhJQtdNjLmrcRHfFNSaRUVLks38t8T9uzOQkriaTA0R 4QM3pHqwssmQDWLIzGFKKV5J2f/TFMT1DnjiVN+1NDVXjExNafMD5+t9Y/FC8D+kCeF2 JrVcIBEZdXiuqGlMjcMKh71Ek54TBOcEEpOleWqzDllbEjDo3p02iOaU4ioRQMFBCdcn 4DZuQkwAaVeRNFp91Upcw8IR0mqCP+Pya1GPrAi4Il385z7EUZxAgrl5rfVMyoS8hSM8 jb1efFbBUuTUwUylBKTl9o5EHFPZXHp6kvMWh8arOacx/eYuHDVjbN/VK+QyPqghKzzg w8Nw== X-Gm-Message-State: AOAM531chGhFyHb5HpV6sRVKUH6jZ+0RangkgE9RiEsrj+0sdAQ6Uehj lsv8WUUTMSUC4UBm4tSdzX+l4dm5rYJzBw== X-Google-Smtp-Source: ABdhPJzc5f87ZwIDIbbgCVZgs9r3XrFUb0sfEhjseIGs62RR8xgLtEjhevlVDme05La0zhRYaSYRAA== X-Received: by 2002:a1c:4c03:: with SMTP id z3mr3983936wmf.24.1603215779042; Tue, 20 Oct 2020 10:42:59 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.42.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:42:58 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 1/8] dt-bindings: display: mediatek: disp: add documentation for MT8167 SoC Date: Tue, 20 Oct 2020 19:42:46 +0200 Message-Id: <20201020174253.3757771-2-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134301_595248_9CCDBA64 X-CRM114-Status: GOOD ( 13.34 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:344 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org Add binding documentation for the MT8167 SoC Signed-off-by: Fabien Parent Reviewed-by: Chun-Kuang Hu --- .../devicetree/bindings/display/mediatek/mediatek,disp.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,disp.txt b/Documentation/devicetree/bindings/display/mediatek/mediatek,disp.txt index 121220745d46..33977e15bebd 100644 --- a/Documentation/devicetree/bindings/display/mediatek/mediatek,disp.txt +++ b/Documentation/devicetree/bindings/display/mediatek/mediatek,disp.txt @@ -43,7 +43,7 @@ Required properties (all function blocks): "mediatek,-dpi" - DPI controller, see mediatek,dpi.txt "mediatek,-disp-mutex" - display mutex "mediatek,-disp-od" - overdrive - the supported chips are mt2701, mt7623, mt2712 and mt8173. + the supported chips are mt2701, mt7623, mt2712, mt8167 and mt8173. - reg: Physical base address and length of the function block register space - interrupts: The interrupt signal from the function block (required, except for merge and split function blocks). @@ -59,7 +59,7 @@ Required properties (DMA function blocks): "mediatek,-disp-ovl" "mediatek,-disp-rdma" "mediatek,-disp-wdma" - the supported chips are mt2701 and mt8173. + the supported chips are mt2701, mt8167 and mt8173. - larb: Should contain a phandle pointing to the local arbiter device as defined in Documentation/devicetree/bindings/memory-controllers/mediatek,smi-larb.txt - iommus: Should point to the respective IOMMU block with master port as From patchwork Tue Oct 20 17:42:47 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847529 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5670616BC for ; Tue, 20 Oct 2020 17:43:25 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 06D7121D6C for ; Tue, 20 Oct 2020 17:43:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="rMK9CR3O"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="zWcQSDXl" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 06D7121D6C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=vqbkjpiWwtKxsP4ibyBcXhugGAPfXFt0F5tfE0G0txU=; b=rMK9CR3O9xIur/CrT2/uyiL1w 6eNx9FgasLDwyUeA/A0RwJigcdO0f4vTK8Yat03jG++R5KNvLw7nRuN+PMqfk8YebP9j6jKwPfb64 3104H+/XH5QW3Vf202Ab2tyck+NOSFZkhN9eNWM2VxmDwAavli096cxKk1owKvAmN9qKihR48TAmS XoCclNEJwO/c1igcESTeQH0/BbHfD+KARdshHLV39HCpr4VeiqZfIZsfKA3hn4Epa/ILcOyystmSf eLajrpMj/OTJFyTAqsNwtfUlu3NeWuSmxawWUKkLhznb05ZbsPZM98ckUrh+YhWiBD1up1j3Zaa+E JcyzxgeYQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfO-0006Yg-Jd; Tue, 20 Oct 2020 17:43:22 +0000 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvf3-0006Q4-Sq for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:04 +0000 Received: by mail-wm1-x341.google.com with SMTP id d3so2927007wma.4 for ; Tue, 20 Oct 2020 10:43:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=g4H4mc6v2t0oOJX5XSAB3K/LcyD6Rk2g297NTsU0GuU=; b=zWcQSDXlGP/96zUAfH5qPzycQ/AK5pvGi5nwVMEHX2j4ynLCXSTLE9qp2r/ZgqpVUR HA4D1J8T985dXMnBot5cPB28dimAo8DbYhVpKNYcT1r16Dp5UCWtXkC7BhzEAmk6lA2g LpHwQfBiC//6+oOIGn6NZOgytNPgkOhkrdzAhDd/Ff3HFLkWlrnIZt4BF44SrQs54cRx StyTw8GWO+LWjQ83yf9x00GL0dvfB3wxR/joYpUni8MOUFzJyYVcAffIhlF8gMBjZJun aWGPqjxjC2VoTAS83J6nVKBM90FEti2y28QHrYBcXLGmR3o0dUCskFCU3YFDFYZAOM2K +J9w== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=g4H4mc6v2t0oOJX5XSAB3K/LcyD6Rk2g297NTsU0GuU=; b=MO/PivX4SSvEVwOJGcOXvOLM0QZ6mSuKdPhaPWdw8+39o5wSVkFyusho1YdCptTEfs 6nBo8NjOAQVuRtEo6+Lr1GKA0fzb+SuebdUQctb6oUu+KMfOwgUHm7v1NVof6a4fzYfA DqGp1bVnk0hfwwGm9gnssI5j69sp3MSqqeoqv30hn0SMJdpmP2A3jBbBHxhnZoEPLn74 riSNQ1AnCDZF+EMyjIC107FyElExu+fF3JVPTJONcDXjcL4T6M7YepCjEgxAwhX0auTK 3PoCllHJDx3+oR1d12kXS3DO2myKkg885234cqwURU7qX7HFsekmMQ2B84JFxaOFL4Dk Ub9w== X-Gm-Message-State: AOAM53303tTRcvgyr9NjuLvaWk7d5O8COvNXGMXxntb4nbMpjemkSYuR OVrlN9zjrASqbuO/uiRY1Vnw+Bk4Fqubyw== X-Google-Smtp-Source: ABdhPJzkT8+U0NpjdVHnhaATbgwrjwpAwrtedA64YWHG7Oi+SvHzjUWaApwcG7WmvLCZ+XbT8s7K3g== X-Received: by 2002:a7b:cd85:: with SMTP id y5mr4068624wmj.168.1603215780592; Tue, 20 Oct 2020 10:43:00 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.42.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:00 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 2/8] dt-bindings: display: mediatek: dsi: add documentation for MT8167 SoC Date: Tue, 20 Oct 2020 19:42:47 +0200 Message-Id: <20201020174253.3757771-3-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134301_957337_A089E7AF X-CRM114-Status: GOOD ( 12.01 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:341 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org Add binding documentation for the MT8167 SoC. The SoC needs an additional clock compared to the already supported SoC: mipi26m. Signed-off-by: Fabien Parent --- .../devicetree/bindings/display/mediatek/mediatek,dsi.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/display/mediatek/mediatek,dsi.txt b/Documentation/devicetree/bindings/display/mediatek/mediatek,dsi.txt index f06f24d405a5..10ae6be7225e 100644 --- a/Documentation/devicetree/bindings/display/mediatek/mediatek,dsi.txt +++ b/Documentation/devicetree/bindings/display/mediatek/mediatek,dsi.txt @@ -7,12 +7,13 @@ channel output. Required properties: - compatible: "mediatek,-dsi" -- the supported chips are mt2701, mt7623, mt8173 and mt8183. +- the supported chips are mt2701, mt7623, mt8167, mt8173 and mt8183. - reg: Physical base address and length of the controller's registers - interrupts: The interrupt signal from the function block. - clocks: device clocks See Documentation/devicetree/bindings/clock/clock-bindings.txt for details. -- clock-names: must contain "engine", "digital", and "hs" +- clock-names: must contain "engine", "digital", "hs" + Can optionnally also contain "mipi26m" - phys: phandle link to the MIPI D-PHY controller. - phy-names: must contain "dphy" - port: Output port node with endpoint definitions as described in @@ -26,7 +27,7 @@ The MIPI TX configuration module controls the MIPI D-PHY. Required properties: - compatible: "mediatek,-mipi-tx" -- the supported chips are mt2701, 7623, mt8173 and mt8183. +- the supported chips are mt2701, 7623, mt8167, mt8173 and mt8183. - reg: Physical base address and length of the controller's registers - clocks: PLL reference clock - clock-output-names: name of the output clock line to the DSI encoder From patchwork Tue Oct 20 17:42:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847533 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 6951916BC for ; Tue, 20 Oct 2020 17:43:44 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 22F0021D6C for ; Tue, 20 Oct 2020 17:43:44 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="cEa7lke8"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="m61n/shu" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 22F0021D6C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=dWvBQ5xkx4o5P/+xaNtbJl3lV5dif3gg47e0q5HBa0U=; b=cEa7lke8BiWUhFGV2zoR+VwZG 60tDy3/7r0e42yCQzt+c8kIT4YyC92EMEU+W9PrpUSeL7iBtrYfiPYg2QY27vFwTevn+mls9dLNXh +dWyVacHRHcbjiXbQtfuERvNXPY1eWa9p0dERS+UWv0nQVauBEXZqdJYxUhaZj0p49a4mTmUDI8Fy 2APkMs4aCGtKl4A9Qbgtt+jmApEC5PIt/lNVXHFU5e79qRYItzHh1IxXrSe/m6X9Obwayv6IcNp6D qjXsstbebprdOHXMSAvZtwBsU8FbKFMF8FQ6djtAD4xHd06zMm/ln16vK4WYLCjgHNLe+gNGxCwWX Z8XXMS+1w==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfg-0006eR-If; Tue, 20 Oct 2020 17:43:40 +0000 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvf5-0006RQ-6v for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:07 +0000 Received: by mail-wm1-x343.google.com with SMTP id k18so2933067wmj.5 for ; Tue, 20 Oct 2020 10:43:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=AJDT7M7U/DertPjHbQd+Y+qplapGoAL1OhIVqnBxURE=; b=m61n/shu260RiFLmYCOqn3vOgiflYZZAgoGSbOU1Gj7R0KO30b1TFe9gEsoSLUR3/V mIvnJJ8cvHNP4vT1ykTljPUZqS5hWNfBRbtkw/BkDXR6U8sAx+e77RFs1huAF1INPkWU OszFMX+4wJr1VMdaQWYHYrrtkUMV2tnU1a+6CO+AJVTCol0l9IwUrpRyUoK7T10ioyqW 7X3L8c6oCQZfEy/Crye6MxZ4Fw17AlwxG72CdHiqGOmJvjnaWW2IpexTquL98PVkgVv1 5SQ3GZzKZ04XwkZISIO3bkpHJqqojqoAwN4Hf4xxpn7g3+9njPeirmkpG75HHzpHZPys f9AA== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=AJDT7M7U/DertPjHbQd+Y+qplapGoAL1OhIVqnBxURE=; b=KsUviJyP+C5WQTUnmM+RsRUHZkbCJAxHvzC5F/RDPKpjOqWi10vjnPH6jgLGSjxL29 EEqXkbltqBHEPJuYPtkz8LcqQeR5aoDbjAUpIg5216G+kZJiU1r56Jv5qfJaNGJvPg1E IZst+UUUHVnsPneAsl6vmbcsJmp2U1aWWlliAMW7B8sEy9ls0Odw0tqc3od/fNP/Bwc7 XwHdjrPmEi8U47Gll/YM0zi9Avzqs7rAEF/6ItoYxRDp1q6oKLtmRQ9hHESo0Pj/2xOH WKc8oq/83LpDrpa+1b4gAFo58p6+zmPBgQR0dFLPjb0ZHlMEwMyonoxkDM5M0uzOvEtG KYMA== X-Gm-Message-State: AOAM530n/fYhmLJu85fOCcbfFwt12DjQKfHegpg3Ia2fbvMh5J6I55Yh 74uXTZ/VlEv9lmuKI03PwsW8qnRD/71Cng== X-Google-Smtp-Source: ABdhPJyiJ1X/RENQ6UMwjnjaZvMP64TrGUC2bLTjtsjWwKG9+Q1UUxrR5oo9Xj19HjmItbczgvkGyw== X-Received: by 2002:a05:600c:21d3:: with SMTP id x19mr4078470wmj.170.1603215782078; Tue, 20 Oct 2020 10:43:02 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:01 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 3/8] drm/mediatek: add disp-color MT8167 support Date: Tue, 20 Oct 2020 19:42:48 +0200 Message-Id: <20201020174253.3757771-4-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134303_283227_ED8B0EE8 X-CRM114-Status: GOOD ( 11.75 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:343 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org Add support for disp-color on MT8167 SoC. Signed-off-by: Fabien Parent Reviewed-by: Chun-Kuang Hu --- drivers/gpu/drm/mediatek/mtk_disp_color.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_disp_color.c b/drivers/gpu/drm/mediatek/mtk_disp_color.c index 3ae9c810845b..a1227cefbf31 100644 --- a/drivers/gpu/drm/mediatek/mtk_disp_color.c +++ b/drivers/gpu/drm/mediatek/mtk_disp_color.c @@ -16,6 +16,7 @@ #define DISP_COLOR_CFG_MAIN 0x0400 #define DISP_COLOR_START_MT2701 0x0f00 +#define DISP_COLOR_START_MT8167 0x0400 #define DISP_COLOR_START_MT8173 0x0c00 #define DISP_COLOR_START(comp) ((comp)->data->color_offset) #define DISP_COLOR_WIDTH(comp) (DISP_COLOR_START(comp) + 0x50) @@ -148,6 +149,10 @@ static const struct mtk_disp_color_data mt2701_color_driver_data = { .color_offset = DISP_COLOR_START_MT2701, }; +static const struct mtk_disp_color_data mt8167_color_driver_data = { + .color_offset = DISP_COLOR_START_MT8167, +}; + static const struct mtk_disp_color_data mt8173_color_driver_data = { .color_offset = DISP_COLOR_START_MT8173, }; @@ -155,6 +160,8 @@ static const struct mtk_disp_color_data mt8173_color_driver_data = { static const struct of_device_id mtk_disp_color_driver_dt_match[] = { { .compatible = "mediatek,mt2701-disp-color", .data = &mt2701_color_driver_data}, + { .compatible = "mediatek,mt8167-disp-color", + .data = &mt8167_color_driver_data}, { .compatible = "mediatek,mt8173-disp-color", .data = &mt8173_color_driver_data}, {}, From patchwork Tue Oct 20 17:42:49 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847535 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0258216BC for ; Tue, 20 Oct 2020 17:43:47 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id AFB3921D6C for ; Tue, 20 Oct 2020 17:43:46 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="zz6nDVPZ"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="WbHD959s" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org AFB3921D6C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=iAHVnSQHbpQUPv+RXxA/w3W1DjPsArErwVkALgJflAg=; b=zz6nDVPZ7D2b5a0pMncGp5J5L glnWT8vtCBVwZF5rIdFBxdrssZID3qL48i+dab5i9VD4XhkAJNHkcbkqg7zZXb4l+P0kRkHkvodDG TcehQLc9fXzKq1zOVliZh8FeKP10BaE7HVgnngEZgKWs6KO4nAkDIVyHXap5GosYd6WOk1lgxu7RJ loOPtwgltYkumVa9RSRj69B7J6s3j9iylgCwKU2gd28gNVaDX4Gxgd4h66tFg8RSBDpi7tZWF1ey5 6sjUT7YnFd3hRYNMUd3v82uNu76ZHY0khWJ67pf8VmbWwVaWQ5CdKQXWeshZ7wPH2cd7Zu9KS873W IKHLPhyiw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfj-0006fc-2P; Tue, 20 Oct 2020 17:43:43 +0000 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvf6-0006S8-NZ for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:07 +0000 Received: by mail-wm1-x341.google.com with SMTP id c194so2702374wme.2 for ; Tue, 20 Oct 2020 10:43:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=tBhINe5+YmVPHfb1/p3z/ZugBR00FYyA2WW1AgRCGAM=; b=WbHD959s2sqRdOZIhuLjT2Bq0V9cHBGUM6oT9iAegHQsQ+NASd6sENwppAqbr4Aoju nx2mJZJa/SiVwmMqJQAUM6ktcpeVWNJ2NtRR+IjvbJF0dvxDCBbvCYBD3j5lRtQGCnts EeC4nyMrnqSwmfzfLQuvSWY8Vo2I6I766NCOwnNT52Aq8ka8jUDgLkG8sr1xEPnNSO9x 2QJwoYC4uhbNJFSLbBNr3FR1JY6T/tNfwoY9g5jp08J6Gjxp3bhlsu2xVxDukEL8SVhI c8jPjI0t01rU7NJCIYkxPF6B3R6mvCBkIQCc/ex2IUXOxCO9ihFdQrjBOs7JaNAhmFBH i4zg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=tBhINe5+YmVPHfb1/p3z/ZugBR00FYyA2WW1AgRCGAM=; b=tKZc4kYc4p491XopKpg0REMmyKEsSGrj58CwLBxHBM5ARdOSVdINY0tiaG3SzK9r7k qSFzsAlHx1slxwoXP7736tHSzHHEhEJQesNGP6B5VrrauPz38nMsekeAftincQ1NlwLQ hkIE3E59jzkc7c6esLjqirRDfMGIDYadQOjxqj/jON05cfC91LGyRbNNx6nEhAPT4Bre WnMNriiQUgX+u9tQs5LdM9iBdeDMpXYDONUBPh61Fx56dWifxDKktAdxSyvpzGbfwp/d quOjthIdd+FoqLO4WBfG0tGaD9OllpbYhc31/uNLXA46qsz0FXoP87mHleTEamTOYGWk qFuA== X-Gm-Message-State: AOAM533KL7zmsIN1yKoXzxHK6Of5uweLyy7fPu27iocFilNa3NMAXC9P LK85l4TPn66g5gPZ6gEEb4dMr5+d3CZiWg== X-Google-Smtp-Source: ABdhPJzYZnrg/xFUR1Exo3D3a8p65ayChvkyZu0pYYwQ4gWPnT+Pl6BY9opLW0tRMMKBzlTaAg9jxw== X-Received: by 2002:a05:600c:4107:: with SMTP id j7mr3965065wmi.44.1603215783589; Tue, 20 Oct 2020 10:43:03 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:03 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 4/8] drm/mediatek: dsi: add pdata variable to start clk in HS mode Date: Tue, 20 Oct 2020 19:42:49 +0200 Message-Id: <20201020174253.3757771-5-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134304_830525_74D6E91E X-CRM114-Status: GOOD ( 14.91 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:341 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org On MT8167, DSI seems to work fine only if we start the clk in HS mode. If we don't start the clk in HS but try to switch later to HS, the display does not work. This commit adds a platform data variable to be used to start the DSI clk in HS mode at power on. Signed-off-by: Fabien Parent --- drivers/gpu/drm/mediatek/mtk_dsi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c b/drivers/gpu/drm/mediatek/mtk_dsi.c index 4a188a942c38..461643c05689 100644 --- a/drivers/gpu/drm/mediatek/mtk_dsi.c +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c @@ -175,6 +175,7 @@ struct mtk_dsi_driver_data { const u32 reg_cmdq_off; bool has_shadow_ctl; bool has_size_ctl; + bool use_hs_on_power_on; }; struct mtk_dsi { @@ -671,7 +672,7 @@ static int mtk_dsi_poweron(struct mtk_dsi *dsi) mtk_dsi_clk_ulp_mode_leave(dsi); mtk_dsi_lane0_ulp_mode_leave(dsi); - mtk_dsi_clk_hs_mode(dsi, 0); + mtk_dsi_clk_hs_mode(dsi, !!dsi->driver_data->use_hs_on_power_on); return 0; err_disable_engine_clk: From patchwork Tue Oct 20 17:42:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847539 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A26AB1744 for ; Tue, 20 Oct 2020 17:44:03 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 5822F2223C for ; Tue, 20 Oct 2020 17:44:01 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="yEM7KD/H"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="Y0K8WJVB" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 5822F2223C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=zsak3jDwKjDb087IalyYJHBk87QpECEUefObKB/wZ78=; b=yEM7KD/HR7+Kdp9kXhqiQ3czR l4iYeQyRNxaUHz3ePTD9dIPdI5P4iDBhDYXdKayZkUzZPN1S89G63MVsL0goRLwpGtbqzAV9d34Ig bXZTNkvFXkUhOhMhGjqqzSSGaZcAfiW2lUnqLIWJfvHbcuio6KB/O3S9rQrGovEojajb2egpvxr7T QkyVLQpgvvDUXQR6ywL1ijAytOaHvg3tIhh+ra62TsLk5dUblbV1KEPo0BO6J4QvhFLi4bYDzxdnS cCz1Mq5lV9/guWrtiu4W0AnwjQxVbxrdEx04Y/5gz/xp02OHoTkLgq7S3GPgzXfJGXc8Ew714l97L VEZ6TUl/A==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfz-0006sY-3p; Tue, 20 Oct 2020 17:43:59 +0000 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvf8-0006Sy-6n for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:11 +0000 Received: by mail-wm1-x344.google.com with SMTP id c77so2706456wmd.4 for ; Tue, 20 Oct 2020 10:43:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=twq11JCTg4YQPPBb170KYVskL+0y3cSGC0QSvk3HH7Y=; b=Y0K8WJVBkIOPg/vWN/gU1vxXt++vSz7StmVppBiSGnmhyGQBKOMQ8hAIb04Afhwj6a 62+XiBskbzrvJhI4iA0oRmM8jG4MwFzf8EzwA9mCx+eRDjY5tuMZVIjPVJ8rJQ2l4mjy apDGCrIAKYw2L5zy+NC2R9nsPefpTGiANnp5FUzPb6gSHYA1D1/yvF9vZW62tnEW5JcL xwFxp2jAZEsl/dwdQzPJ5USMd9KZCSRimXYGtlaWRbKTSqVErYT5qC9uimgEP7SMH445 ob07PhCQGEjZ7ZEZ1pg47Ci1z5OU9XyECBPwHRgN1OQ1psyp6Mqkj4qX5B7Dx+Smj61Z eOzA== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=twq11JCTg4YQPPBb170KYVskL+0y3cSGC0QSvk3HH7Y=; b=G0WsUigybFJXR4QKYqv/gGr/f1k88WuIO6lY/G0adArmmFRqQXAcn+laLBBoKZBn/t vH5A5K8IGIKg746mVcjy/gexuFFpu641JRrlAhBfa1f8LtlqzckMCNJVxR9qiQ921ieb PgxpTf+SvYuTxuYwEqElAyAq9BNIhCXUuolmU33AN/yZfKPTFQjB9tbaQsR4QUdoo13R SrOqMml/m5COCGD5Qpwe4mPH+XW4KYPv7w4AdEoXKKI3Q7I7fYDY+NTPzcWOCzgkEX6n osujEt7asWmlMl7HQBMJVQHxREBFkM3Jt/aw8s8N6pVs95Ue8NTvS+1U9d8GnS9HFssU nR/w== X-Gm-Message-State: AOAM5323ytE/U+cvdeCV6dlhSd3E0j7UVYVMRh837WW9wKYzGRhV27sy HTtkq4CCdB0Yyobv6lHIhVRG2V3KUTw+GA== X-Google-Smtp-Source: ABdhPJyenmhTxFRDWjoJTAfZ9z3NaV+DCbnu64Fauv9XbNcdJIz9d1gaggKnqTTQxm1DBo/NklsnPQ== X-Received: by 2002:a1c:de8a:: with SMTP id v132mr2244614wmg.173.1603215785045; Tue, 20 Oct 2020 10:43:05 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:04 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 5/8] drm/mediatek: dsi: add support for mipi26m clk Date: Tue, 20 Oct 2020 19:42:50 +0200 Message-Id: <20201020174253.3757771-6-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134306_314678_D2E30E6E X-CRM114-Status: GOOD ( 14.68 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:344 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org MT8167 SoC needs an additional clock to be enabled. Add support for the mipi26m clk. Signed-off-by: Fabien Parent --- drivers/gpu/drm/mediatek/mtk_dsi.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c b/drivers/gpu/drm/mediatek/mtk_dsi.c index 461643c05689..08786734df8e 100644 --- a/drivers/gpu/drm/mediatek/mtk_dsi.c +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c @@ -193,6 +193,7 @@ struct mtk_dsi { struct clk *engine_clk; struct clk *digital_clk; struct clk *hs_clk; + struct clk *mipi26m; u32 data_rate; @@ -653,6 +654,12 @@ static int mtk_dsi_poweron(struct mtk_dsi *dsi) goto err_disable_engine_clk; } + ret = clk_prepare_enable(dsi->mipi26m); + if (ret < 0) { + dev_err(dev, "Failed to enable mipi26m clock: %d\n", ret); + goto err_phy_power_off; + } + mtk_dsi_enable(dsi); if (dsi->driver_data->has_shadow_ctl) @@ -710,6 +717,7 @@ static void mtk_dsi_poweroff(struct mtk_dsi *dsi) clk_disable_unprepare(dsi->engine_clk); clk_disable_unprepare(dsi->digital_clk); + clk_disable_unprepare(dsi->mipi26m); phy_power_off(dsi->phy); } @@ -1086,6 +1094,8 @@ static int mtk_dsi_probe(struct platform_device *pdev) goto err_unregister_host; } + dsi->mipi26m = devm_clk_get_optional(dev, "mipi26m"); + dsi->hs_clk = devm_clk_get(dev, "hs"); if (IS_ERR(dsi->hs_clk)) { ret = PTR_ERR(dsi->hs_clk); From patchwork Tue Oct 20 17:42:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847541 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C9FEA16BC for ; Tue, 20 Oct 2020 17:44:08 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 80EE222244 for ; Tue, 20 Oct 2020 17:44:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="kfbcmZSq"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="WnvZJski" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 80EE222244 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=OvKamrVmTrkpHo8A+xvTDIsEYflMznyEMrPrVNi2hU0=; b=kfbcmZSq5GdgXeqWNU1HzpqCZ oprNc1bee0sE9UPxvYyJCiRTl+Zi1eiBnpxonXD3+wHxNTSMA8/sVdIU9/6447diwyIKFjM50X6cv Wgz4GZ9aJsurLEB0H+bOFgXTS4vYxR9t/MRuG0xPnwd6FFLfTMPMQxUQ2j2l1NdTUwTzNgb7Bt496 afgWCdHc7hknN5ZlDdlX+A8zBr98jTNPW7OqeUkRzoq5PXUJvGtW3orvCImnLLSvTzhnNSu7ORvwZ GSLRCA5WRTNPRQi5ja3tXGKb/EeC8qZUjqneXm5LqDpcuVUNjBT08GOhoUZGTU18dZzRyqgN2Kut2 JgfXFFSXQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvg4-0006xC-Am; Tue, 20 Oct 2020 17:44:04 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfA-0006Tg-Et for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:11 +0000 Received: by mail-wr1-x442.google.com with SMTP id s9so3213595wro.8 for ; Tue, 20 Oct 2020 10:43:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=jUKyzhSGhUR/Bwwd5x38HZWQ53tYZ5QssSwc3z6VJCg=; b=WnvZJskixl0tYxIjUvfdGfd3sQFS/qQ7mBwPCXEslhPAIP8Mf53G5brThLZkuzn0PQ +N5GMsL02ari+rbsuqrlf032XTeg8kuwW3GwGPH1d4tNoXxfMqJ2Zez9pn/tIx2U1z/9 jaenEiZWJsAmrEMpVm6IxMNe0N3rFNPM0qxiMdEG+GuZHrKd03khMy+vPcRYWJL3gsE2 Ltm4+juqIRNNziZDNWoMPqgkpInngwFBFbdB+u6m3CDOXjQr9UWQciRtoA844ZGOAemA TswLIGcpSC7erqVAnCrGGIjwmnkplMMEYZOCkGEhCFQ2ukKKR72z5EmSwl4aLfH1dsS0 /I1g== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=jUKyzhSGhUR/Bwwd5x38HZWQ53tYZ5QssSwc3z6VJCg=; b=aBX7bRYvrxG9x+4Hs+c0X+s4V9/vpNH4GJX5XwyHSucT9LxRLZzEINUlsZ8IfHPXfg s31snktmpGi7eva++fe17FYhdregKjE9uxpl5lFRg+sO3npDnQwiqmxoA5Q8R37KW/lM ulrDv8nT8CHMDYJaTBZB7xgPQcelP/mHVBlP8FQl/WAP/8Tcq0sD6QRHSzuX72kgUMpL umNCzQGSeTnyo4qDG8EuWYXp59EoknVl22BDliujYOvDwC3Z7sHdUybTFcOpEl0TkiPq gSBcv3evkc8b0EGA+mSJjfn3ajI+r6enTqyL5YhGzp+i2/Cst6Yzp6HPJ6LmKIUyOKPh /yxg== X-Gm-Message-State: AOAM532FxsbCDK7+umpzUbV7eEBU7OKA6cKrQeWJLS0kEgJvB9s541jW 5ojGtgi/edabgXUSHKbnUO/XpYpwZZgBfA== X-Google-Smtp-Source: ABdhPJylIT9S52zEh0LE5r5mbFdXBQ69vOLAAksKF1Kpq3OlZP0kKeEVshgGZzd/uO0H63x7NnFyfg== X-Received: by 2002:a5d:5604:: with SMTP id l4mr4614953wrv.140.1603215787049; Tue, 20 Oct 2020 10:43:07 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:06 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 6/8] drm/mediatek: dsi: add support for MT8167 SoC Date: Tue, 20 Oct 2020 19:42:51 +0200 Message-Id: <20201020174253.3757771-7-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134308_543521_EDBA2060 X-CRM114-Status: GOOD ( 12.78 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:442 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org Add platform data to support the MT8167 SoC. Signed-off-by: Fabien Parent --- drivers/gpu/drm/mediatek/mtk_dsi.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_dsi.c b/drivers/gpu/drm/mediatek/mtk_dsi.c index 08786734df8e..d90dd0f83292 100644 --- a/drivers/gpu/drm/mediatek/mtk_dsi.c +++ b/drivers/gpu/drm/mediatek/mtk_dsi.c @@ -1182,6 +1182,11 @@ static int mtk_dsi_remove(struct platform_device *pdev) return 0; } +static const struct mtk_dsi_driver_data mt8167_dsi_driver_data = { + .reg_cmdq_off = 0x180, + .use_hs_on_power_on = true, +}; + static const struct mtk_dsi_driver_data mt8173_dsi_driver_data = { .reg_cmdq_off = 0x200, }; @@ -1199,6 +1204,8 @@ static const struct mtk_dsi_driver_data mt8183_dsi_driver_data = { static const struct of_device_id mtk_dsi_of_match[] = { { .compatible = "mediatek,mt2701-dsi", .data = &mt2701_dsi_driver_data }, + { .compatible = "mediatek,mt8167-dsi", + .data = &mt8167_dsi_driver_data }, { .compatible = "mediatek,mt8173-dsi", .data = &mt8173_dsi_driver_data }, { .compatible = "mediatek,mt8183-dsi", From patchwork Tue Oct 20 17:42:52 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847543 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id CC57F1744 for ; Tue, 20 Oct 2020 17:44:10 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8621E21D6C for ; Tue, 20 Oct 2020 17:44:10 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Q2x0xqcF"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="CXwhUZUU" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8621E21D6C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=v6mQ+NCt3Seso1oQ9/urjDWQeBa2GmTshUjmUX/MYLM=; b=Q2x0xqcFek06LNHTBAmRoytTg jlHtGoZZZrPbPLbL1vaB8YpWpb3SduHy5T91LvIh8bHDkRwMk/Y+tyD+KiwSZYzmmSJLsSZUadVzX 63TxEzgQLQqKGViznl05suf5irOPubPTyW+ZopZ6x0gvjU4Z6v3J48nMP5OCwSAnFUJr/JM1dY8sh n8BjWcZMm3Kx+f7gjXmim4abeEL7/ylY1U+PA/ONntDaVwiEua5/JUmVqoo7k+M8bSdh88ihlkXKN 3agcxsU7sF8kzTponSHuUIkwSDpGCvB+gz2y/yCqM7ItAqFPT/Pzb2LgkWUBg62n2CvWKsp+kUFFP vXOlTrrSw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvg7-0006zq-V8; Tue, 20 Oct 2020 17:44:07 +0000 Received: from mail-wr1-x441.google.com ([2a00:1450:4864:20::441]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfB-0006UU-Qu for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:15 +0000 Received: by mail-wr1-x441.google.com with SMTP id y12so3219050wrp.6 for ; Tue, 20 Oct 2020 10:43:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=R7RXDOliptKA8bPe7jbK0aPa/iXk1YfLM7zpkeUY4r0=; b=CXwhUZUUNIu919TmdIJ3eCAeLP//5WPFJPZJ0UYmflMIlE2lGVpLMtGA8VqCH7r0MB rW3rrLcXrn0j7H/eM6ScuHXAfxmrmwI4gKQ2a8E/wQM1Iwhzl1LV8giXT7uRhuj58Hb1 68iWMSyi9qlM00AfKuJlyoBXRZktu95n7ZXLA6ZdDQYoFXkEtc2l+VfyYsdgB6zSV0RI kFMTxBNiOmOw+3RJ32r0sHyGmdp1UyHfBW5ZW+GVxqiTywFB8MVbwA1oEfhace7DQh3/ aQYT2I6wRD1mx/ZSWQMp3ZqhMFqJt0cRqOebBPVatwEBBl6TpkdlSQkYWYNRYluwJOLU qExA== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=R7RXDOliptKA8bPe7jbK0aPa/iXk1YfLM7zpkeUY4r0=; b=pFv4UClEohzB1BZlzvaGVVm6TuFMQSpebRVrp4n4Qt8gZhiz/tW86W33aF3qzxZ4NO T2joWPsq4fSF9dabZi9W7xxsfCMqzBqBTTJI+sPok5tC0D12ekGvP8RJNbnPRyK6o6ca Gr11Sb2DSrl2QyVsz14IzQlcvaWcWEzO2zEHUUr6SL1n9hYwiyEE8EIh21nHFWSGaJst a4oyRhAVKBIO0ukSDvLeWJQw/zc4jH+hMHsuyvBCx7lRgxJLlCMuCJAUAUHNIa4dpdY7 MRjoZahS+ihp0aRhaYcv0orG9OevCnC3YTjlRt208rHwVRclRhd40j8BNvDjnkswe950 dtpA== X-Gm-Message-State: AOAM531kRxkhjnrubj8683+tQUhZoZgc7dqUfksLSPjgRJSJ5om0FO12 jJwgVKmgUD3Yn7H5rMF4q+OZZ70Nu7r36g== X-Google-Smtp-Source: ABdhPJyBmc9IMC/NZiiAcSZYffBFsTH95Rfj5KqcMHO90F5XV49n9uEcwPTKapHZGWa/m5fl2bgSTA== X-Received: by 2002:adf:e443:: with SMTP id t3mr4787042wrm.14.1603215788573; Tue, 20 Oct 2020 10:43:08 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:07 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 7/8] drm/mediatek: add DDP support for MT8167 Date: Tue, 20 Oct 2020 19:42:52 +0200 Message-Id: <20201020174253.3757771-8-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134309_959721_2D0C9677 X-CRM114-Status: GOOD ( 12.61 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:441 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org Add DDP support for MT8167 SoC. Signed-off-by: Fabien Parent --- drivers/gpu/drm/mediatek/mtk_drm_ddp.c | 50 ++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_drm_ddp.c b/drivers/gpu/drm/mediatek/mtk_drm_ddp.c index 014c1bbe1df2..bb62fdcf3d71 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_ddp.c +++ b/drivers/gpu/drm/mediatek/mtk_drm_ddp.c @@ -25,6 +25,19 @@ #define INT_MUTEX BIT(1) +#define MT8167_MUTEX_MOD_DISP_PWM 1 +#define MT8167_MUTEX_MOD_DISP_OVL0 6 +#define MT8167_MUTEX_MOD_DISP_OVL1 7 +#define MT8167_MUTEX_MOD_DISP_RDMA0 8 +#define MT8167_MUTEX_MOD_DISP_RDMA1 9 +#define MT8167_MUTEX_MOD_DISP_WDMA0 10 +#define MT8167_MUTEX_MOD_DISP_CCORR 11 +#define MT8167_MUTEX_MOD_DISP_COLOR 12 +#define MT8167_MUTEX_MOD_DISP_AAL 13 +#define MT8167_MUTEX_MOD_DISP_GAMMA 14 +#define MT8167_MUTEX_MOD_DISP_DITHER 15 +#define MT8167_MUTEX_MOD_DISP_UFOE 16 + #define MT8173_MUTEX_MOD_DISP_OVL0 11 #define MT8173_MUTEX_MOD_DISP_OVL1 12 #define MT8173_MUTEX_MOD_DISP_RDMA0 13 @@ -73,6 +86,8 @@ #define MUTEX_SOF_DPI1 4 #define MUTEX_SOF_DSI2 5 #define MUTEX_SOF_DSI3 6 +#define MT8167_MUTEX_SOF_DPI0 2 +#define MT8167_MUTEX_SOF_DPI1 3 struct mtk_disp_mutex { @@ -135,6 +150,21 @@ static const unsigned int mt2712_mutex_mod[DDP_COMPONENT_ID_MAX] = { [DDP_COMPONENT_WDMA1] = MT2712_MUTEX_MOD_DISP_WDMA1, }; +static const unsigned int mt8167_mutex_mod[DDP_COMPONENT_ID_MAX] = { + [DDP_COMPONENT_AAL0] = MT8167_MUTEX_MOD_DISP_AAL, + [DDP_COMPONENT_CCORR] = MT8167_MUTEX_MOD_DISP_CCORR, + [DDP_COMPONENT_COLOR0] = MT8167_MUTEX_MOD_DISP_COLOR, + [DDP_COMPONENT_DITHER] = MT8167_MUTEX_MOD_DISP_DITHER, + [DDP_COMPONENT_GAMMA] = MT8167_MUTEX_MOD_DISP_GAMMA, + [DDP_COMPONENT_OVL0] = MT8167_MUTEX_MOD_DISP_OVL0, + [DDP_COMPONENT_OVL1] = MT8167_MUTEX_MOD_DISP_OVL1, + [DDP_COMPONENT_PWM0] = MT8167_MUTEX_MOD_DISP_PWM, + [DDP_COMPONENT_RDMA0] = MT8167_MUTEX_MOD_DISP_RDMA0, + [DDP_COMPONENT_RDMA1] = MT8167_MUTEX_MOD_DISP_RDMA1, + [DDP_COMPONENT_UFOE] = MT8167_MUTEX_MOD_DISP_UFOE, + [DDP_COMPONENT_WDMA0] = MT8167_MUTEX_MOD_DISP_WDMA0, +}; + static const unsigned int mt8173_mutex_mod[DDP_COMPONENT_ID_MAX] = { [DDP_COMPONENT_AAL0] = MT8173_MUTEX_MOD_DISP_AAL, [DDP_COMPONENT_COLOR0] = MT8173_MUTEX_MOD_DISP_COLOR0, @@ -163,6 +193,16 @@ static const unsigned int mt2712_mutex_sof[DDP_MUTEX_SOF_DSI3 + 1] = { [DDP_MUTEX_SOF_DSI3] = MUTEX_SOF_DSI3, }; +static const unsigned int mt8167_mutex_sof[DDP_MUTEX_SOF_DSI3 + 1] = { + [DDP_MUTEX_SOF_SINGLE_MODE] = MUTEX_SOF_SINGLE_MODE, + [DDP_MUTEX_SOF_DSI0] = MUTEX_SOF_DSI0, + [DDP_MUTEX_SOF_DSI1] = MUTEX_SOF_DSI1, + [DDP_MUTEX_SOF_DPI0] = MT8167_MUTEX_SOF_DPI0, + [DDP_MUTEX_SOF_DPI1] = MT8167_MUTEX_SOF_DPI1, + [DDP_MUTEX_SOF_DSI2] = MUTEX_SOF_DSI2, + [DDP_MUTEX_SOF_DSI3] = MUTEX_SOF_DSI3, +}; + static const struct mtk_ddp_data mt2701_ddp_driver_data = { .mutex_mod = mt2701_mutex_mod, .mutex_sof = mt2712_mutex_sof, @@ -177,6 +217,14 @@ static const struct mtk_ddp_data mt2712_ddp_driver_data = { .mutex_sof_reg = MT2701_DISP_MUTEX0_SOF0, }; +static const struct mtk_ddp_data mt8167_ddp_driver_data = { + .mutex_mod = mt8167_mutex_mod, + .mutex_sof = mt8167_mutex_sof, + .mutex_mod_reg = MT2701_DISP_MUTEX0_MOD0, + .mutex_sof_reg = MT2701_DISP_MUTEX0_SOF0, + .no_clk = true, +}; + static const struct mtk_ddp_data mt8173_ddp_driver_data = { .mutex_mod = mt8173_mutex_mod, .mutex_sof = mt2712_mutex_sof, @@ -400,6 +448,8 @@ static const struct of_device_id ddp_driver_dt_match[] = { .data = &mt2701_ddp_driver_data}, { .compatible = "mediatek,mt2712-disp-mutex", .data = &mt2712_ddp_driver_data}, + { .compatible = "mediatek,mt8167-disp-mutex", + .data = &mt8167_ddp_driver_data}, { .compatible = "mediatek,mt8173-disp-mutex", .data = &mt8173_ddp_driver_data}, {}, From patchwork Tue Oct 20 17:42:53 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847547 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 7506D1744 for ; Tue, 20 Oct 2020 17:44:20 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 16B792225B for ; Tue, 20 Oct 2020 17:44:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="w4SW7iI0"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="tKhGvZjH" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 16B792225B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version: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=cT4HMAOKIUuuMrtcXrQb7EuWGNqI39pDOzznGKwxeM4=; b=w4SW7iI07A8cf9RokWA9uaWsF LHylolvSEqmYdC+m4BgDMiD52rhc00EsS+ViILmBKyQwVuaFjU/x50coI/7AkAebXm6cXqWDQ+B8/ cQeHZbefaN3dwNp1PUsmhklQ1a3KeteTymbaCc4sVOw/Ya7/drHaNX9T+mYA2nA9I5OP0N9AOsD/2 YZJSOYClQJ9BLTXgdKWCRIpx2r+iuYmWQ78PAUxgEi6RluSYm+UQoHbxqOMiFfDdEY2S/v4SdxFjT 8XAoPMdHvU8CfPYnD4JjT/1G/N9+XawnRQcOIzYlrn1n2s1HGfJTugNWkrq7PwWyLS7mRdJnnjiVc qS6azJCfg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvgH-000766-4i; Tue, 20 Oct 2020 17:44:17 +0000 Received: from mail-wr1-x444.google.com ([2a00:1450:4864:20::444]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfD-0006VL-Ed for linux-mediatek@lists.infradead.org; Tue, 20 Oct 2020 17:43:15 +0000 Received: by mail-wr1-x444.google.com with SMTP id j7so3198415wrt.9 for ; Tue, 20 Oct 2020 10:43:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=1A8pfSek/oH+kI//UrZrfn2qlGAQqPoXd9JAju99Kjw=; b=tKhGvZjHxPeNh1BqRsnqoK5mk8FKDP8GpA+8AwZOq42jOphNgYUY5iBbwL2iwYh643 ilMXNPIoy1ITQRVR9VfbAvrhU4rIEuJJv6yHikwMBo07KK3uX4n5WqR5zSJ6x41578iY j3SAnl2D9opqS7C3H4iWZm1EV20bzt1Hh1n5APmPCznBedCN9vNxClJSDWtKygEqlGPk mS7ppoerv0bTUSu8loyCAvdl+3czi3yUA/xCIcunIHapYtBDEpQ0SBwR2gWtEcCt/eoK xk6W82bzd987JbfkGJrU8qZEb8urxe8+RejC+8Hilg247SVLbAEo5q566TEzSLAGlj1G j4tg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=1A8pfSek/oH+kI//UrZrfn2qlGAQqPoXd9JAju99Kjw=; b=XM0ijU9om1AoEJo48VrPvGu5KAm942dqylD01cPj/MR6yPsyy/wyPdQpNR/LJeW28X uQMur/NyNUzmZD4jSFtpqlE6o2niPJJlHpZvKPu7uqttDw2Uf0iZWdVzNIgv3wTRjOWd QLsAsle4Gndwe1E4D1/TNnN0pfwx8u0etyl5Rj0WGbU+YDHrAhwPOSXU17BMVZtJNAKN Blgbb6ZVtY38NQ4kDe0uwrKvQ0g3dztiIJmigDa8uArta04v0A1++4Juk+TyncO2YNMs ltl39X0FrT4g/e/30E2U7JTVIEOq68FEGQ2FOZgM0kAJH+EpKTOEfMhxRvXKlf0UDA4e 5Wig== X-Gm-Message-State: AOAM531qX8/6UoD+B08T3XsNyYturNjxvpHzdSmY38Tr1rhdPWRsZpPP jHJ1tDT+5sX82mQFYDqd3vpp0jtL1Jjo4A== X-Google-Smtp-Source: ABdhPJwqF5VYoBqPaVRJ2EDBqfvlSysBqq92CEHWViBWOriU59xWNrrDpDUp6DyvZcdF2kpfumUOMQ== X-Received: by 2002:adf:f104:: with SMTP id r4mr4824741wro.202.1603215790101; Tue, 20 Oct 2020 10:43:10 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:09 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 8/8] drm/mediatek: Add support for main DDP path on MT8167 Date: Tue, 20 Oct 2020 19:42:53 +0200 Message-Id: <20201020174253.3757771-9-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134311_681478_51F48947 X-CRM114-Status: GOOD ( 13.52 ) X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.4 on merlin.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:444 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org Add the main (DSI) drm display path for MT8167. Signed-off-by: Fabien Parent --- drivers/gpu/drm/mediatek/mtk_drm_drv.c | 38 ++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_drm_drv.c b/drivers/gpu/drm/mediatek/mtk_drm_drv.c index 59c85c63b7cc..3952435093fe 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_drv.c +++ b/drivers/gpu/drm/mediatek/mtk_drm_drv.c @@ -112,6 +112,17 @@ static const enum mtk_ddp_comp_id mt2712_mtk_ddp_third[] = { DDP_COMPONENT_PWM2, }; +static enum mtk_ddp_comp_id mt8167_mtk_ddp_main[] = { + DDP_COMPONENT_OVL0, + DDP_COMPONENT_COLOR0, + DDP_COMPONENT_CCORR, + DDP_COMPONENT_AAL0, + DDP_COMPONENT_GAMMA, + DDP_COMPONENT_DITHER, + DDP_COMPONENT_RDMA0, + DDP_COMPONENT_DSI0, +}; + static const enum mtk_ddp_comp_id mt8173_mtk_ddp_main[] = { DDP_COMPONENT_OVL0, DDP_COMPONENT_COLOR0, @@ -163,6 +174,11 @@ static const struct mtk_mmsys_driver_data mt8173_mmsys_driver_data = { .ext_len = ARRAY_SIZE(mt8173_mtk_ddp_ext), }; +static const struct mtk_mmsys_driver_data mt8167_mmsys_driver_data = { + .main_path = mt8167_mtk_ddp_main, + .main_len = ARRAY_SIZE(mt8167_mtk_ddp_main), +}; + static int mtk_drm_kms_init(struct drm_device *drm) { struct mtk_drm_private *private = drm->dev_private; @@ -401,26 +417,42 @@ static const struct component_master_ops mtk_drm_ops = { static const struct of_device_id mtk_ddp_comp_dt_ids[] = { { .compatible = "mediatek,mt2701-disp-ovl", .data = (void *)MTK_DISP_OVL }, + { .compatible = "mediatek,mt8167-disp-ovl", + .data = (void *)MTK_DISP_OVL }, { .compatible = "mediatek,mt8173-disp-ovl", .data = (void *)MTK_DISP_OVL }, { .compatible = "mediatek,mt2701-disp-rdma", .data = (void *)MTK_DISP_RDMA }, + { .compatible = "mediatek,mt8167-disp-rdma", + .data = (void *)MTK_DISP_RDMA }, { .compatible = "mediatek,mt8173-disp-rdma", .data = (void *)MTK_DISP_RDMA }, { .compatible = "mediatek,mt8173-disp-wdma", .data = (void *)MTK_DISP_WDMA }, + { .compatible = "mediatek,mt8167-disp-ccorr", + .data = (void *)MTK_DISP_CCORR }, { .compatible = "mediatek,mt2701-disp-color", .data = (void *)MTK_DISP_COLOR }, + { .compatible = "mediatek,mt8167-disp-color", + .data = (void *)MTK_DISP_COLOR }, { .compatible = "mediatek,mt8173-disp-color", .data = (void *)MTK_DISP_COLOR }, + { .compatible = "mediatek,mt8167-disp-aal", + .data = (void *)MTK_DISP_AAL}, { .compatible = "mediatek,mt8173-disp-aal", .data = (void *)MTK_DISP_AAL}, + { .compatible = "mediatek,mt8167-disp-gamma", + .data = (void *)MTK_DISP_GAMMA, }, { .compatible = "mediatek,mt8173-disp-gamma", .data = (void *)MTK_DISP_GAMMA, }, + { .compatible = "mediatek,mt8167-disp-dither", + .data = (void *)MTK_DISP_DITHER }, { .compatible = "mediatek,mt8173-disp-ufoe", .data = (void *)MTK_DISP_UFOE }, { .compatible = "mediatek,mt2701-dsi", .data = (void *)MTK_DSI }, + { .compatible = "mediatek,mt8167-dsi", + .data = (void *)MTK_DSI }, { .compatible = "mediatek,mt8173-dsi", .data = (void *)MTK_DSI }, { .compatible = "mediatek,mt2701-dpi", @@ -431,10 +463,14 @@ static const struct of_device_id mtk_ddp_comp_dt_ids[] = { .data = (void *)MTK_DISP_MUTEX }, { .compatible = "mediatek,mt2712-disp-mutex", .data = (void *)MTK_DISP_MUTEX }, + { .compatible = "mediatek,mt8167-disp-mutex", + .data = (void *)MTK_DISP_MUTEX }, { .compatible = "mediatek,mt8173-disp-mutex", .data = (void *)MTK_DISP_MUTEX }, { .compatible = "mediatek,mt2701-disp-pwm", .data = (void *)MTK_DISP_BLS }, + { .compatible = "mediatek,mt8167-disp-pwm", + .data = (void *)MTK_DISP_PWM }, { .compatible = "mediatek,mt8173-disp-pwm", .data = (void *)MTK_DISP_PWM }, { .compatible = "mediatek,mt8173-disp-od", @@ -449,6 +485,8 @@ static const struct of_device_id mtk_drm_of_ids[] = { .data = &mt7623_mmsys_driver_data}, { .compatible = "mediatek,mt2712-mmsys", .data = &mt2712_mmsys_driver_data}, + { .compatible = "mediatek,mt8167-mmsys", + .data = &mt8167_mmsys_driver_data}, { .compatible = "mediatek,mt8173-mmsys", .data = &mt8173_mmsys_driver_data}, { }