Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1791687pxb; Wed, 9 Feb 2022 04:43:14 -0800 (PST) X-Google-Smtp-Source: ABdhPJxvjUWx1Ae5kmhfp+TkgkFkWqiPnZlCg0U7NduGD1/qkxMXuHNC4q8iQ+mqiNjSkeOyRVnL X-Received: by 2002:a63:8548:: with SMTP id u69mr1729152pgd.419.1644410594696; Wed, 09 Feb 2022 04:43:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644410594; cv=none; d=google.com; s=arc-20160816; b=oCD5rFX3k8Og81UPO2N1wIx2vUw/VO58ucn0KC2MZj6zbYER7i/bmEOdJHZLdj+AKj LCHVW9oxul6g3zEJ8KPUWWasPOshULywoOilf13VSebLNZzMjxS4qDIBMnlweIjEzPB3 WWxslxGFn3Wj0+U6t7eF2LGLWqv6BndEPt6m0SNubUIIFoRzBl8+bJokob9PGKQg3qN1 mvE5vhZ6X2qRuNNKS/eXf53N3nQX5j8EJnFoyTbOy75O7UFZyqGS7Wd/TwXlzJc5MVPy wcefsmPi2uOCJcP7x7Mw4UAE23FSTz/Ng8jNivQ4XrlAATN/vRmkr7+dp+pkqTl2L9QL PSEA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from:cc :references:to:content-language:subject:user-agent:mime-version:date :message-id; bh=V/pKgAo6OQyQUrkM+GQCaaTNk3vweHmhrKjFbqo3iq0=; b=WXsDXGPj4OsAdKKs+e0mx9mcNt6wa2bP+55ymOyOY3wc5vC2FchWq84qppP3o9l5Vu PsLrHRpQlv44MGAAPuOzSD/NeZ1mQFnAuCQuNx561534l9gnqxF7KZHgivBNOxwwZqU6 D+L8KdDmXhKmPrDDKeK9vXvZVIaXCyWfpBJG1eJ4ZBKOVyihmfXFX5mLSgbVb8Z0aMdB bbs1F7tBHb68CanFX0GE/8hzhW5pfFpELluM0OI9Cw2ssSdZq/3lnIjbjtAwihpJMrf1 UFsxfg5XwMO6MngZkzjMW9V6qhi6DLcv+8thBN78+HHrz81cWbxA/ZiQasyQ3gqWCqJk nz3A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id o3si14014861pll.580.2022.02.09.04.43.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Feb 2022 04:43:14 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 20E61E051178; Wed, 9 Feb 2022 02:26:59 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233774AbiBIGYp (ORCPT + 99 others); Wed, 9 Feb 2022 01:24:45 -0500 Received: from gmail-smtp-in.l.google.com ([23.128.96.19]:44980 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234200AbiBIGXX (ORCPT ); Wed, 9 Feb 2022 01:23:23 -0500 Received: from mx1.molgen.mpg.de (mx3.molgen.mpg.de [141.14.17.11]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3375EE00FEF0; Tue, 8 Feb 2022 22:23:24 -0800 (PST) Received: from [192.168.0.2] (ip5f5aee30.dynamic.kabel-deutschland.de [95.90.238.48]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: pmenzel) by mx.molgen.mpg.de (Postfix) with ESMTPSA id A85D361E64846; Wed, 9 Feb 2022 07:23:21 +0100 (CET) Message-ID: <554448a9-bc65-7c0b-9878-fb2c0fe9bfe4@molgen.mpg.de> Date: Wed, 9 Feb 2022 07:23:21 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: [PATCH v1] media: aspeed: Fix incorrect color Content-Language: en-US To: Jammy Huang References: <20220209024312.2218-1-jammy_huang@aspeedtech.com> Cc: eajames@linux.ibm.com, mchehab@kernel.org, joel@jms.id.au, andrew@aj.id.au, linux-media@vger.kernel.org, openbmc@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, linux-kernel@vger.kernel.org From: Paul Menzel In-Reply-To: <20220209024312.2218-1-jammy_huang@aspeedtech.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Dear Jammy, Am 09.02.22 um 03:43 schrieb Jammy Huang: > Current settings for rgb-2-yuv is BT.601(studio swing), but JFIF > uses BT.601(full swing). Could you please describe the problem in a little more detail? On an attached monitor to the BMC (which one) what incorrect colors are seen? Maybe use: > media: aspeed: Use full swing for JFIF to fix incorrect color > Signed-off-by: Jammy Huang > --- > drivers/media/platform/aspeed-video.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/media/platform/aspeed-video.c b/drivers/media/platform/aspeed-video.c > index eb9c17ac0e14..08b63b8297f0 100644 > --- a/drivers/media/platform/aspeed-video.c > +++ b/drivers/media/platform/aspeed-video.c > @@ -1089,7 +1089,7 @@ static void aspeed_video_init_regs(struct aspeed_video *video) > u32 comp_ctrl = VE_COMP_CTRL_RSVD | > FIELD_PREP(VE_COMP_CTRL_DCT_LUM, video->jpeg_quality) | > FIELD_PREP(VE_COMP_CTRL_DCT_CHR, video->jpeg_quality | 0x10); > - u32 ctrl = VE_CTRL_AUTO_OR_CURSOR; > + u32 ctrl = VE_CTRL_AUTO_OR_CURSOR | VE_CTRL_YUV; Excuse my ignorance, but reading [1][2] YUV can be represented by studio and full swing. How is the register/bit described in the datasheet, and can the macro name be improved? > u32 seq_ctrl = video->jpeg_mode; > > if (video->frame_rate) Kind regards, Paul [1]: https://mymusing.co/bt601-yuv-to-rgb-conversion-color/ [2]: https://www.hisour.com/yuv-color-system-25916/