Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3021593rwb; Mon, 15 Aug 2022 16:18:55 -0700 (PDT) X-Google-Smtp-Source: AA6agR7TN59S+mCeitF5HzYVwEIqISWneuthCYP0vMn7fNT7jGY3EoNEZumul8w5oiIV4i7hdz2F X-Received: by 2002:a05:6a00:8c8:b0:52c:887d:fa25 with SMTP id s8-20020a056a0008c800b0052c887dfa25mr18172133pfu.86.1660605535525; Mon, 15 Aug 2022 16:18:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660605535; cv=none; d=google.com; s=arc-20160816; b=A2qA2xgDfk9ZmGFWYedtdUm4n0EMa+VWCgmaM0QcAN8hB8PCsgqyMZA0XqIjKZdhxJ iL7O41NfRVLpTWPsrFB6wOi4Oo2Lh4158Y9uQTuK+G3mKEQ60sRNQq1uOr9pM1GPa/0f 4q9ZjIhGqq8lDyw6yAeGwMS46LmiElY/ozwHB0Ya1/zTgrMHM06LxAnqVTrQBXWsbi5l cZh+IRkqn2hXwBkEKGziaNqsrYDcc7CY4uKhUGWiW4k9nbiWgLLN/4VjM/reySziSOxz FcdoYK/iWTwlOOIF6XP6myu5n38Fom6M92fBW1I0TkuXB++yiGnOoNbCUHGS2d6dGgkV pEWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=d2zisPkD4S/kAkl6HRnw/q83Yopqwzg+ncL2D/k8Ur8=; b=M0XowmRPILG03GzQuZCuB9uXDNDhtFDJ+azUCXrRf+BLlPtRTlAQW3V/Nycs4BcDT6 MpLRVjx8hjGBlWJUd85Sprq1vBI24DAr/w7KvbmRYjOl11SBPnJtWEbsAHBANzXC4G0M O1Fi/wxZyyoH4wz0s8KYikReZe5cwPpWmBa2dteqSMqlOzhTxgK3VoeQ9aLY3HwvVGgb NKD3zFhBJFBAak+vUroX3fb9Mg+xNJL7iUQhhVslPH3JtMgxQ1VLRsxYqd+NPbr3hEDp NvoaRqpKSjaBb63C17wr2ZBKLHFFPwBuy53CqrFjnFqcPokMaUG093gnt7UT3+nSMiOn gx7Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=be7B401G; 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=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c7-20020a170903234700b0016ccf06c2aesi14459990plh.512.2022.08.15.16.18.44; Mon, 15 Aug 2022 16:18:55 -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=@linuxfoundation.org header.s=korg header.b=be7B401G; 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=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240271AbiHOVKb (ORCPT + 99 others); Mon, 15 Aug 2022 17:10:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46164 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344994AbiHOVGC (ORCPT ); Mon, 15 Aug 2022 17:06:02 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9D3C9D5DEA; Mon, 15 Aug 2022 12:15:13 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A14E86009B; Mon, 15 Aug 2022 19:15:12 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A8DEFC433B5; Mon, 15 Aug 2022 19:15:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660590912; bh=NDaqN0HN4Lw9xKA+GYcUn8lKUCBj57SDn6sS5RzJY98=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=be7B401GkXp190PFOa1w+1ldwmm0+7s8UmSIRRWIKrgiu8+RtddBTHLhBE55XDQJQ EFcrI3/G9x4IH2Npwwo+fXDhJ4Gk7MR6t83Kuu1Pcm4zKXM0X1cDMLy1v1Db39O38d 4Ewck4pQiyaJWzw3+H8M6cFQYTp2SDQ3YsENb0FA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Bo-Chen Chen , Chun-Kuang Hu , Sasha Levin Subject: [PATCH 5.18 0411/1095] drm/mediatek: dpi: Remove output format of YUV Date: Mon, 15 Aug 2022 19:56:50 +0200 Message-Id: <20220815180446.707640223@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180429.240518113@linuxfoundation.org> References: <20220815180429.240518113@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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: Bo-Chen Chen [ Upstream commit c9ed0713b3c35fc45677707ba47f432cad95da56 ] DPI is not support output format as YUV, but there is the setting of configuring output YUV. Therefore, remove them in this patch. Fixes: 9e629c17aa8d ("drm/mediatek: Add DPI sub driver") Signed-off-by: Bo-Chen Chen Link: https://patchwork.kernel.org/project/linux-mediatek/patch/20220701035845.16458-5-rex-bc.chen@mediatek.com/ Signed-off-by: Chun-Kuang Hu Signed-off-by: Sasha Levin --- drivers/gpu/drm/mediatek/mtk_dpi.c | 31 ++++++------------------------ 1 file changed, 6 insertions(+), 25 deletions(-) diff --git a/drivers/gpu/drm/mediatek/mtk_dpi.c b/drivers/gpu/drm/mediatek/mtk_dpi.c index e61cd67b978f..675e2e4072df 100644 --- a/drivers/gpu/drm/mediatek/mtk_dpi.c +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c @@ -54,13 +54,7 @@ enum mtk_dpi_out_channel_swap { }; enum mtk_dpi_out_color_format { - MTK_DPI_COLOR_FORMAT_RGB, - MTK_DPI_COLOR_FORMAT_RGB_FULL, - MTK_DPI_COLOR_FORMAT_YCBCR_444, - MTK_DPI_COLOR_FORMAT_YCBCR_422, - MTK_DPI_COLOR_FORMAT_XV_YCC, - MTK_DPI_COLOR_FORMAT_YCBCR_444_FULL, - MTK_DPI_COLOR_FORMAT_YCBCR_422_FULL + MTK_DPI_COLOR_FORMAT_RGB }; struct mtk_dpi { @@ -364,24 +358,11 @@ static void mtk_dpi_config_disable_edge(struct mtk_dpi *dpi) static void mtk_dpi_config_color_format(struct mtk_dpi *dpi, enum mtk_dpi_out_color_format format) { - if ((format == MTK_DPI_COLOR_FORMAT_YCBCR_444) || - (format == MTK_DPI_COLOR_FORMAT_YCBCR_444_FULL)) { - mtk_dpi_config_yuv422_enable(dpi, false); - mtk_dpi_config_csc_enable(dpi, true); - mtk_dpi_config_swap_input(dpi, false); - mtk_dpi_config_channel_swap(dpi, MTK_DPI_OUT_CHANNEL_SWAP_BGR); - } else if ((format == MTK_DPI_COLOR_FORMAT_YCBCR_422) || - (format == MTK_DPI_COLOR_FORMAT_YCBCR_422_FULL)) { - mtk_dpi_config_yuv422_enable(dpi, true); - mtk_dpi_config_csc_enable(dpi, true); - mtk_dpi_config_swap_input(dpi, true); - mtk_dpi_config_channel_swap(dpi, MTK_DPI_OUT_CHANNEL_SWAP_RGB); - } else { - mtk_dpi_config_yuv422_enable(dpi, false); - mtk_dpi_config_csc_enable(dpi, false); - mtk_dpi_config_swap_input(dpi, false); - mtk_dpi_config_channel_swap(dpi, MTK_DPI_OUT_CHANNEL_SWAP_RGB); - } + /* only support RGB888 */ + mtk_dpi_config_yuv422_enable(dpi, false); + mtk_dpi_config_csc_enable(dpi, false); + mtk_dpi_config_swap_input(dpi, false); + mtk_dpi_config_channel_swap(dpi, MTK_DPI_OUT_CHANNEL_SWAP_RGB); } static void mtk_dpi_dual_edge(struct mtk_dpi *dpi) -- 2.35.1