Received: by 2002:a05:7412:e794:b0:fa:551:50a7 with SMTP id o20csp640139rdd; Tue, 9 Jan 2024 15:22:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IFQ3aDS2rbLNS0ehmBhVqIr0XQCjg8NDYeIlQCBV0lwAy5EY3EFIbYueOYdv1+kRSRAaxcl X-Received: by 2002:a05:6871:a9cc:b0:204:316:5eeb with SMTP id wp12-20020a056871a9cc00b0020403165eebmr316704oab.62.1704842543734; Tue, 09 Jan 2024 15:22:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704842543; cv=none; d=google.com; s=arc-20160816; b=SnLuMDNVFiIe/F+pm+KZq7TKjE+bvhW/n1+Xd1ZRuWja0jBjPojTQoSfbBuWBqDkn2 HCHt8id34JI1yMMoHia1WQC+WL8qqWyVzaZvvO1/EDJQpFlirvVJeEPvILuGKB9KVCPo JwnA4R4UZI2gR5V94olRo/R8LcsN5zqiSUfvbGrsoCzFJ0jsW5z8c7CRhC1h7vVM+Lqc Eua4vJsY2anGYFEDabo3Z8Y/TmR8DB5hpu4ZC4j9uF6wv4jq5rwQCTuc5AXifEOHEaGB cMWaMzYsIg+bhXAl3eusGwQJsPT8y317IuoeKCEQkAsOduzXBApIZKchlOOOCfGFDu9s QkjQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=ebXuRtZ+jV+LA1Jw2fSqPglODs+5bJfr1352MU2Bcvc=; fh=JtP9UVhdvQoIQuss/awlMipG8ZItL7IeH5ohgk4u0k0=; b=tDLQSavFnUOCJkcidWFhwriLItikcByrhyyZiXgPE3OLFuHIaF/V0aXQrdnZnlINbV 7VcjZIxZagZb3dd/6e0P01TBBzK5PWnPYGv8en1XENZBKGrzDrzzvaCYfN5oeF33veWk WE17paz34+Z6e6I54fQsZ6uErICEXDZGUpd7WsrQCLKiAWmlAmNYsDHi+9/DpyPW/whr 6IeS/28gDAQZCUSleNB9h2zbR4cXjRSjvWF4rgvosJypyVHvmijV0Msstj/tQ8CjRkem L8bpe5qls05UyZqEWv3EDCHgzoKLWmp6HP7zPKblWZ1BhMzecJlMzEfMWM6eEj+xIHIr UwRA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@yngvason.is header.s=google header.b=IHr+JpU4; spf=pass (google.com: domain of linux-kernel+bounces-21527-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-21527-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=yngvason.is Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id d70-20020a633649000000b005cdfef90ea6si2342650pga.336.2024.01.09.15.22.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jan 2024 15:22:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-21527-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@yngvason.is header.s=google header.b=IHr+JpU4; spf=pass (google.com: domain of linux-kernel+bounces-21527-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-21527-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=yngvason.is Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 61467287C65 for ; Tue, 9 Jan 2024 23:22:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 87EA13E479; Tue, 9 Jan 2024 23:22:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=yngvason.is header.i=@yngvason.is header.b="IHr+JpU4" Received: from mail-yw1-f178.google.com (mail-yw1-f178.google.com [209.85.128.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 003893BB20 for ; Tue, 9 Jan 2024 23:22:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=yngvason.is Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=yngvason.is Received: by mail-yw1-f178.google.com with SMTP id 00721157ae682-5f8cf76ef5bso22099457b3.0 for ; Tue, 09 Jan 2024 15:22:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yngvason.is; s=google; t=1704842534; x=1705447334; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=ebXuRtZ+jV+LA1Jw2fSqPglODs+5bJfr1352MU2Bcvc=; b=IHr+JpU4D9WgsuCfEhOl4L4y6MIEnOKIkBOaH8gYN/MXBjgge3LmhtbYsy9C9j8EcR xC9pF57oBeen/JYZItNFHxPen3Xm1rAgq8egHPyEpJ6bQmPyh9JdyrnoEhAI2V9FtTGu U6xV16tBWoIRz/ToTbMZ0Eu18netQ69R7Fvd4= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704842534; x=1705447334; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ebXuRtZ+jV+LA1Jw2fSqPglODs+5bJfr1352MU2Bcvc=; b=OKdedrHEz6qOA+XLuqAwaSfhU+LOQwTYTduWBW/UfPFHa95mnQC89rZujyo6Z6lign xGm4Ht1UtyUbS02iYLGFtjY2mP6EMJch2tlKu9zmoqKiuSqD1zK84J4P5aMIY+fHIQs+ pF1VDkaU0V17cnzexLH4Y9H1TxWDCq669WfSUeXBNCvYwKpPcBIL6wTYuY1f37Cswv8m oeYayN9C9R2lRTWwnfMpx9F4tU/ocVHfS5yWDTFswfvwBbvdBvR6xeL5t8rRfgXUgkcO GBQvDCR1QfiwUUmeFZ87Lml3SnG0TWQEdeAqnX9JLX/FFL7/ZrrSheNdCD30W8XqfiX1 XnTA== X-Gm-Message-State: AOJu0Yy+mGhk+sxRnfXUgnOSXf+ouVAs/KpNmDo5lL0lE9DFaZm/nPjZ WoW2/aZaGBDhqwKIsgPB10oi/qYVROaiyhbLk8d+ig7Bu0AiOQ== X-Received: by 2002:a81:4857:0:b0:5ee:1ca0:b7ef with SMTP id v84-20020a814857000000b005ee1ca0b7efmr258078ywa.42.1704842533828; Tue, 09 Jan 2024 15:22:13 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240109181104.1670304-1-andri@yngvason.is> <20240109181104.1670304-3-andri@yngvason.is> In-Reply-To: From: Andri Yngvason Date: Tue, 9 Jan 2024 23:21:38 +0000 Message-ID: Subject: Re: [PATCH 2/7] drm/uAPI: Add "active color format" drm property as feedback for userspace To: Daniel Stone Cc: Harry Wentland , Leo Li , Rodrigo Siqueira , Alex Deucher , =?UTF-8?Q?Christian_K=C3=B6nig?= , "Pan, Xinhui" , David Airlie , Daniel Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Tvrtko Ursulin , amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, intel-gfx@lists.freedesktop.org, Simon Ser , Werner Sembach Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Daniel, Please excuse my misconfigured email client. HTML was accidentally enabled in my previous messages, so I'll re-send it for the benefit of mailing lists. =C3=BEri., 9. jan. 2024 kl. 22:32 skrifa=C3=B0i Daniel Stone : > > On Tue, 9 Jan 2024 at 18:12, Andri Yngvason wrote: > > + * active color format: > > + * This read-only property tells userspace the color format actual= ly used > > + * by the hardware display engine "on the cable" on a connector. T= he chosen > > + * value depends on hardware capabilities, both display engine and > > + * connected monitor. Drivers shall use > > + * drm_connector_attach_active_color_format_property() to install = this > > + * property. Possible values are "not applicable", "rgb", "ycbcr44= 4", > > + * "ycbcr422", and "ycbcr420". > > How does userspace determine what's happened without polling? Will it > only change after an `ALLOW_MODESET` commit, and be guaranteed to be > updated after the commit has completed and the event being sent? > Should it send a HOTPLUG event? Other? Userspace does not determine what's happened without polling. The purpose of this property is not for programmatic verification that the preferred property was applied. It is my understanding that it's mostly intended for debugging purposes. It should only change as a consequence of modesetting, although I didn't actually look into what happens if you set the "preferred color format" outside of a modeset. The way I've implemented things in sway, calling the "preferred_signal_format" command triggers a modeset with the "preferred color format" set and calling "get_outputs", immediately queries the "actual color format" and displays it. Regards, Andri