From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net [217.70.183.200]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A85D56FBAE; Thu, 1 Feb 2024 17:40:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.200 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706809253; cv=none; b=AzxvjP54/Q2zhUlbtcJhrvsj8el0jqOPX8bGan3UhLIMcDu/PaUe0c4/P7RHRlw5Rnm8LAPAwGy7G8yBF7MX+aU9p3afu5w1grJUYhHV5H9TECHBNvL0I1wO2if/o1+a0WnzDG9p0KMR5jROUsbfdlkpa0UGo61jfa9LNfEC6VI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706809253; c=relaxed/simple; bh=0Ou6/Og3XZcGnI/U9UmiJ6OSiKCaYvWug+ANvQ8E7TM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=mWAnK1nYK/VjF/5JundptWfN5AIk8jdGN3stcxUK9E/86NfT6IaYQsnhq4lcLAVh7nqtXd79AP+Gnrid0bRIImIZNM7YZtyUTr2N/3smuj2ipuT20+UTiZyaFtLhv6OjWyN07xCMEzrL/YcgeRjUaArX2EZs6CEpr0rv2hKFA88= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=iKljNWpX; arc=none smtp.client-ip=217.70.183.200 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="iKljNWpX" Received: by mail.gandi.net (Postfix) with ESMTPSA id 7559420004; Thu, 1 Feb 2024 17:40:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1706809243; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=4qKUDvTrHc7JZagKwFNOZaKz7EuhrsYkoyLzmNMMlbE=; b=iKljNWpXwgiLh/ADrBamXUPuhtvH13++yKdQhu28YYTh1hyhGjXKoOJ0wYuevonIrHj1Cv YV/zN2AJsoVnVmH7wTbyFZwo2QVQtsL/iO/Jb0qo3j8aSUSHTxWRSklYVkVG482pvdMec2 FvcFQYuRbwTErI5lTAudORH7VpC/1JpPws+qJIkAqw0yJn48mIc5uuEMX6odQIdtl5gENK ZbUQ1TBS09/rrM6HcFKu8gePBriBOfG5dMAuRWjZf4hk63JluoQ6pEwwj9scbpZ2JCo/H8 SnNB/IxJzeacullzfJm1caXPt/ZcwZZhgDJy299HWmjf5syYK0tAfasEn/nAhQ== Date: Thu, 1 Feb 2024 18:40:39 +0100 From: Louis Chauvet To: Arthur Grillo Cc: Daniel Vetter , David Airlie , Haneen Mohammed , Harry Wentland , Jonathan Corbet , Maarten Lankhorst , Maxime Ripard , =?iso-8859-1?Q?Ma=EDra?= Canal , Melissa Wen , Rodrigo Siqueira , Thomas Zimmermann , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-doc@vger.kernel.org, thomas.petazzoni@bootlin.com, miquel.raynal@bootlin.com, seanpaul@google.com, nicolejadeyee@google.com, marcheu@google.com Subject: Re: [PATCH v2 7/7] drm/vkms: Create KUnit tests for YUV conversions Message-ID: Mail-Followup-To: Arthur Grillo , Daniel Vetter , David Airlie , Haneen Mohammed , Harry Wentland , Jonathan Corbet , Maarten Lankhorst , Maxime Ripard , =?iso-8859-1?Q?Ma=EDra?= Canal , Melissa Wen , Rodrigo Siqueira , Thomas Zimmermann , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-doc@vger.kernel.org, thomas.petazzoni@bootlin.com, miquel.raynal@bootlin.com, seanpaul@google.com, nicolejadeyee@google.com, marcheu@google.com References: <20240110-vkms-yuv-v2-0-952fcaa5a193@riseup.net> <20240110-vkms-yuv-v2-7-952fcaa5a193@riseup.net> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240110-vkms-yuv-v2-7-952fcaa5a193@riseup.net> X-GND-Sasl: louis.chauvet@bootlin.com [...] > + { > + .encoding = DRM_COLOR_YCBCR_BT709, > + .range = DRM_COLOR_YCBCR_FULL_RANGE, > + .n_colors = 4, > + .colors = { > + {"white", {0xff, 0x80, 0x80}, {0x0000, 0xffff, 0xffff, 0xffff}}, > + {"gray", {0x80, 0x80, 0x80}, {0x0000, 0x8000, 0x8000, 0x8000}}, > + {"black", {0x00, 0x80, 0x80}, {0x0000, 0x0000, 0x0000, 0x0000}}, > + {"red", {0x35, 0x63, 0xff}, {0x0000, 0xffff, 0x0000, 0x0000}}, > + {"green", {0xb6, 0x1e, 0x0c}, {0x0000, 0x0000, 0xffff, 0x0000}}, > + {"blue", {0x12, 0xff, 0x74}, {0x0000, 0x0000, 0x0000, 0xffff}}, > + }, > + }, > + { > + .encoding = DRM_COLOR_YCBCR_BT709, > + .range = DRM_COLOR_YCBCR_LIMITED_RANGE, > + .n_colors = 4, I think there is a mistake in n_colors here, if I understand correctly it must be the size of .colors, so here it should probably be 6? > + .colors = { > + {"white", {0xeb, 0x80, 0x80}, {0x0000, 0xffff, 0xffff, 0xffff}}, > + {"gray", {0x7e, 0x80, 0x80}, {0x0000, 0x8000, 0x8000, 0x8000}}, > + {"black", {0x10, 0x80, 0x80}, {0x0000, 0x0000, 0x0000, 0x0000}}, > + {"red", {0x3f, 0x66, 0xf0}, {0x0000, 0xffff, 0x0000, 0x0000}}, > + {"green", {0xad, 0x2a, 0x1a}, {0x0000, 0x0000, 0xffff, 0x0000}}, > + {"blue", {0x20, 0xf0, 0x76}, {0x0000, 0x0000, 0x0000, 0xffff}}, > + }, > + }, > + { > + .encoding = DRM_COLOR_YCBCR_BT2020, > + .range = DRM_COLOR_YCBCR_FULL_RANGE, > + .n_colors = 4, Same here. > + .colors = { > + {"white", {0xff, 0x80, 0x80}, {0x0000, 0xffff, 0xffff, 0xffff}}, > + {"gray", {0x80, 0x80, 0x80}, {0x0000, 0x8000, 0x8000, 0x8000}}, > + {"black", {0x00, 0x80, 0x80}, {0x0000, 0x0000, 0x0000, 0x0000}}, > + {"red", {0x43, 0x5c, 0xff}, {0x0000, 0xffff, 0x0000, 0x0000}}, > + {"green", {0xad, 0x24, 0x0b}, {0x0000, 0x0000, 0xffff, 0x0000}}, > + {"blue", {0x0f, 0xff, 0x76}, {0x0000, 0x0000, 0x0000, 0xffff}}, > + }, > + }, > + { > + .encoding = DRM_COLOR_YCBCR_BT2020, > + .range = DRM_COLOR_YCBCR_LIMITED_RANGE, > + .n_colors = 4, Same here. > + .colors = { > + {"white", {0xeb, 0x80, 0x80}, {0x0000, 0xffff, 0xffff, 0xffff}}, > + {"gray", {0x7e, 0x80, 0x80}, {0x0000, 0x8000, 0x8000, 0x8000}}, > + {"black", {0x10, 0x80, 0x80}, {0x0000, 0x0000, 0x0000, 0x0000}}, > + {"red", {0x4a, 0x61, 0xf0}, {0x0000, 0xffff, 0x0000, 0x0000}}, > + {"green", {0xa4, 0x2f, 0x19}, {0x0000, 0x0000, 0xffff, 0x0000}}, > + {"blue", {0x1d, 0xf0, 0x77}, {0x0000, 0x0000, 0x0000, 0xffff}}, > + }, > + }, > +}; [...] -- Louis Chauvet, Bootlin Embedded Linux and Kernel engineering https://bootlin.com