Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp450630rwb; Mon, 26 Sep 2022 00:46:42 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6DrG2Pzhsi7bGvvFs0ajloKHClF4hQaPePpwmBQNjf4H+PqE0ylJ5hRQ8j0t1i8yoIYj8v X-Received: by 2002:a05:6a00:158f:b0:546:b777:af17 with SMTP id u15-20020a056a00158f00b00546b777af17mr22069120pfk.51.1664178401868; Mon, 26 Sep 2022 00:46:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664178401; cv=none; d=google.com; s=arc-20160816; b=ggRzubs6fVFdcDMZWbbyy5u0ZVmYK+qJo5Q4gP/sEKx1Dy8DM2bE4HXrH4wU6pEhCF t/MyL05QMQQAvfGTM3mgbd+cnNDa8C8y9SeWPduzl/D+YahrFkqwCHMmrzYw7AZsrzUH VtiYCUYViXbj68mEm/M13SjvRxlDSpH55Bw9tfzgXHIbFX6W4CAHngRSYM/1YLIXKzDz pmvkppM8Xmp+l+2tGZt/KoEbiVRvwo3TD63Y5HF7xuxttP8a7z+FVvY4nPlbUUY9b9Hp Lgsj4BzUU8UAMXAaolobQkQ1Rz69bz4zDztUVfthy2NIUGRCrsP6sedMIzqayKKrUkyE mFcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=PRn0qWsxaXW+28p/aNbKk48GsaA1Uw9zH6yZFYoTelI=; b=aACPlXJ9i9wZl6MDblKgr0+fMmDbYnRQGdbZvyf8W1iiCZ0KcxOPWJA1t58cf4v6LH eihPbkBcgVjNaSLNfsJtFrm0ktBriS9cM2HNgxEweiWumxjcZKqo4Jc9V2uB0e1/JOzL neQ87piCPjfmc9p0RiGpdfw/I3rD1d2/oLIRxwcG7gvLeUQ2BcDN3Hhpa7IYoY1dFfCc qZSNcIlL9xp0AaVEJn20EoNY5j+BNK0d+Crv7/hbQa+x6S9bfka0KBOC5RLG3ZkyxTGc TAGfXkHc75nGCLgavVjAtpHbIpwleTikMX6DiS8rgZNfj7Ml9VnYqoCPBMOPQbRsuKC0 0ooA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=q7ZFtTvI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j13-20020a170903024d00b001749dafb822si12491362plh.507.2022.09.26.00.46.30; Mon, 26 Sep 2022 00:46:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=q7ZFtTvI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234122AbiIZHnk (ORCPT + 99 others); Mon, 26 Sep 2022 03:43:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234104AbiIZHne (ORCPT ); Mon, 26 Sep 2022 03:43:34 -0400 Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 447B62A713 for ; Mon, 26 Sep 2022 00:43:29 -0700 (PDT) X-UUID: 33e24605102f48a28f4a1002badaaf97-20220926 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=PRn0qWsxaXW+28p/aNbKk48GsaA1Uw9zH6yZFYoTelI=; b=q7ZFtTvIdSrS+fwoX95+30nMOabj+Pz9wbufD4fvnFP2lL6J+9r2RwxQAQJPMHruWVLvqhHsYiErBbJcFZHjTZWO6eutbw1KAGRijrsgZhXSAkNhggG21UOZt2p2RrFmWnhRts23nJEJIWaqxjCnJHczrH+dj/QapJbBCx0I8bY=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.11,REQID:0eecdcb8-e534-4328-a15c-04e5ba157e97,IP:0,U RL:0,TC:0,Content:-25,EDM:0,RT:0,SF:95,FILE:0,BULK:0,RULE:Release_Ham,ACTI ON:release,TS:70 X-CID-INFO: VERSION:1.1.11,REQID:0eecdcb8-e534-4328-a15c-04e5ba157e97,IP:0,URL :0,TC:0,Content:-25,EDM:0,RT:0,SF:95,FILE:0,BULK:0,RULE:Spam_GS981B3D,ACTI ON:quarantine,TS:70 X-CID-META: VersionHash:39a5ff1,CLOUDID:db0a0407-1cee-4c38-b21b-a45f9682fdc0,B ulkID:22092615432422YO2E1Z,BulkQuantity:0,Recheck:0,SF:38|28|17|19|48|823| 824,TC:nil,Content:0,EDM:-3,IP:nil,URL:11|1,File:nil,Bulk:nil,QS:nil,BEC:n il,COL:0 X-UUID: 33e24605102f48a28f4a1002badaaf97-20220926 Received: from mtkmbs10n1.mediatek.inc [(172.21.101.34)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 168583402; Mon, 26 Sep 2022 15:43:22 +0800 Received: from mtkcas11.mediatek.inc (172.21.101.40) by mtkmbs11n1.mediatek.inc (172.21.101.185) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.15; Mon, 26 Sep 2022 15:43:20 +0800 Received: from mszsdaap41.gcn.mediatek.inc (10.16.6.141) by mtkcas11.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Mon, 26 Sep 2022 15:43:20 +0800 From: To: , , , , , , , CC: , , , , , , Xinlei Lee Subject: [PATCH v11,3/3] drm: mediatek: Add mt8186 dpi compatibles and platform data Date: Mon, 26 Sep 2022 15:43:11 +0800 Message-ID: <1664178191-27964-4-git-send-email-xinlei.lee@mediatek.com> X-Mailer: git-send-email 2.6.4 In-Reply-To: <1664178191-27964-1-git-send-email-xinlei.lee@mediatek.com> References: <1664178191-27964-1-git-send-email-xinlei.lee@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, SPF_PASS,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Xinlei Lee Add the compatible because use edge_cfg_in_mmsys in mt8186. Signed-off-by: Xinlei Lee Reviewed-by: CK Hu Reviewed-by: AngeloGioacchino Del Regno --- drivers/gpu/drm/mediatek/mtk_dpi.c | 21 +++++++++++++++++++++ drivers/gpu/drm/mediatek/mtk_drm_drv.c | 2 ++ 2 files changed, 23 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_dpi.c b/drivers/gpu/drm/mediatek/mtk_dpi.c index ad87ecddf58d..325032fd5343 100644 --- a/drivers/gpu/drm/mediatek/mtk_dpi.c +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c @@ -941,6 +941,24 @@ static const struct mtk_dpi_conf mt8183_conf = { .csc_enable_bit = CSC_ENABLE, }; +static const struct mtk_dpi_conf mt8186_conf = { + .cal_factor = mt8183_calculate_factor, + .reg_h_fre_con = 0xe0, + .max_clock_khz = 150000, + .output_fmts = mt8183_output_fmts, + .num_output_fmts = ARRAY_SIZE(mt8183_output_fmts), + .edge_cfg_in_mmsys = true, + .pixels_per_iter = 1, + .is_ck_de_pol = true, + .swap_input_support = true, + .support_direct_pin = true, + .dimension_mask = HPW_MASK, + .hvsize_mask = HSIZE_MASK, + .channel_swap_shift = CH_SWAP, + .yuv422_en_bit = YUV422_EN, + .csc_enable_bit = CSC_ENABLE, +}; + static const struct mtk_dpi_conf mt8192_conf = { .cal_factor = mt8183_calculate_factor, .reg_h_fre_con = 0xe0, @@ -1091,6 +1109,9 @@ static const struct of_device_id mtk_dpi_of_ids[] = { { .compatible = "mediatek,mt8183-dpi", .data = &mt8183_conf, }, + { .compatible = "mediatek,mt8186-dpi", + .data = &mt8186_conf, + }, { .compatible = "mediatek,mt8192-dpi", .data = &mt8192_conf, }, diff --git a/drivers/gpu/drm/mediatek/mtk_drm_drv.c b/drivers/gpu/drm/mediatek/mtk_drm_drv.c index 546b79412815..3d32fbc66ac1 100644 --- a/drivers/gpu/drm/mediatek/mtk_drm_drv.c +++ b/drivers/gpu/drm/mediatek/mtk_drm_drv.c @@ -646,6 +646,8 @@ static const struct of_device_id mtk_ddp_comp_dt_ids[] = { .data = (void *)MTK_DPI }, { .compatible = "mediatek,mt8183-dpi", .data = (void *)MTK_DPI }, + { .compatible = "mediatek,mt8186-dpi", + .data = (void *)MTK_DPI }, { .compatible = "mediatek,mt8192-dpi", .data = (void *)MTK_DPI }, { .compatible = "mediatek,mt8195-dp-intf", -- 2.18.0