Received: by 2002:a05:6358:5282:b0:b5:90e7:25cb with SMTP id g2csp3412012rwa; Tue, 23 Aug 2022 04:28:10 -0700 (PDT) X-Google-Smtp-Source: AA6agR6hOVdWYrj3NMlX8MjRGwC23mt4rDOCgwRNU3ToemBZxgs5bILnZUEGJX49l2kXIycMJw5f X-Received: by 2002:a62:3884:0:b0:52b:ead1:7bc8 with SMTP id f126-20020a623884000000b0052bead17bc8mr24917003pfa.78.1661254090050; Tue, 23 Aug 2022 04:28:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661254090; cv=none; d=google.com; s=arc-20160816; b=Eyn4j6jUAcoP/DfXnCh9Xvtxf9Q4rg6y8hH6NYDNKJkCQHpM52n6urrMpfJuR+j7Lx R0oC+Wv45igQMM5L0KODnS+nPm4+e9CTCIhtwTUHkY5ZF+7cK8ixiJXrNV+IRN+3muGl +DFug2fGWMzS/GaQlhbN3T7EPaQy04BFZ41JF8+Kir1bdJMzoOTy6K98RTlJcXd34qXY KyKvOunjGuoEF7gEWAthOZ5/qzqcG8CuVoWdF4nnOMS8nm0GUA2+E813IdDLyBr+n25M CIk970n5CaUtVF2H6f/b5YAypVDUnfD6Epc7CIoxhz1Y71VXJJsbIaUWFFpMce6d6tBm lPjA== 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=D3nSDtUo7t022pn5yuhIPB/0y3jd6S9n/SinvJRNHIQ=; b=ITG1Iq7hPtjBerB26ads6i4Npy92CSTgeGJ2xKDU8Efs0VRSAYNDwnSFoQef0570ot WAmMo93R/rzo+o+Mp8M5sxK3X9BzHp3HJJn+DvmD8CZhwITQj+ZR/6pQKvaDIX9UQKnf LEjJiTBjr7siyBIrdsvHOBRmdpwF19fg8AGh/++oUvw3pvNdewFjEZIs4WS88KQckezR bWR09lJwgt1SpCvSqX7NaK0KNS41VQgZG35e4Kk8QdJ8+MoFWRKDVw+bhsJxOIYXxpg3 fh4yknENsht/u1C5JRoizM9RUb09X59UDs2Oy/de1PAsvYx3OKfj/Zt4ChuIqQ9Obd+M wgpg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=aCN8aBNN; 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 o16-20020a170902d4d000b00170a752cae8si13189374plg.115.2022.08.23.04.27.57; Tue, 23 Aug 2022 04:28:10 -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=aCN8aBNN; 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 S1355154AbiHWKh5 (ORCPT + 99 others); Tue, 23 Aug 2022 06:37:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40952 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1355102AbiHWKWw (ORCPT ); Tue, 23 Aug 2022 06:22:52 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E339782D22; Tue, 23 Aug 2022 02:04:03 -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 9C00861579; Tue, 23 Aug 2022 09:04:02 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 92166C433C1; Tue, 23 Aug 2022 09:04:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1661245442; bh=uFkwEnwYdM2knsy3Y3aTW+IQSNPBA1I+FmHWrWPgufA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=aCN8aBNNJTAITmmpLJzd7joGAEnWQOkKfVfziy+dTnPfw3r+wSDTMVyuVv9hHpB84 +vNtSn6IiLjjTgKTBINMP8kJfp/stkUlT1/ZeQz1YJFXN3oASXYk1WjI3khvbVqnGY AcPAXn4ZyVuZS3kW1I+/kJtEycYOSNDZjnT/GF34= 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 4.19 080/287] drm/mediatek: dpi: Remove output format of YUV Date: Tue, 23 Aug 2022 10:24:09 +0200 Message-Id: <20220823080102.961692222@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220823080100.268827165@linuxfoundation.org> References: <20220823080100.268827165@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 6c0ea39d5739..a263ac4aaab2 100644 --- a/drivers/gpu/drm/mediatek/mtk_dpi.c +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c @@ -52,13 +52,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 { @@ -347,24 +341,11 @@ static void mtk_dpi_config_2n_h_fre(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_power_off(struct mtk_dpi *dpi, enum mtk_dpi_power_ctl pctl) -- 2.35.1