From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BAC1BECAAD5 for ; Mon, 5 Sep 2022 14:28:56 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BCF6310E3F3; Mon, 5 Sep 2022 14:28:52 +0000 (UTC) Received: from new4-smtp.messagingengine.com (new4-smtp.messagingengine.com [66.111.4.230]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9988710E3F3; Mon, 5 Sep 2022 14:28:49 +0000 (UTC) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailnew.nyi.internal (Postfix) with ESMTP id BD5585801E7; Mon, 5 Sep 2022 10:28:48 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Mon, 05 Sep 2022 10:28:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cerno.tech; h=cc :cc:content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to; s=fm3; t=1662388128; x=1662395328; bh=vefUy4dRsZ VWF0YIrw3msOYzL5sGqxLnWRwOjKgBDrQ=; b=K2XS8PGlr2rLCbhGAhNKVV1mKa oE5a/DxS0PxYT09GHAoeKfQb2EbQCJ9mu4w58MqnAKA1v9KKxxsiYAxH7YOsy1BN 33JRgsa8h4OHegIECgAC9cSpyUMc/Lo2C5mNrEChFfPna0d7iS4gIrwUted9CHx7 qbnimRJOdwi2we5OgCLd/60A+k3wyzn4j3TdiHlGFcBFcI08cKnqIx93lEL+bLCT CqAKbzWub2maQ+RaEAZeMK1h2/Od9syCt1Oc4Z5nD1+HayHeRoUYskPKsrsmSzCh e3N7WD2rFsuM/GYBLynULlDETMkMlutJu524iww9KxGAYCF5MtrBhwWigXQg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:date:date:feedback-id :feedback-id:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1662388128; x=1662395328; bh=vefUy4dRsZVWF0YIrw3msOYzL5sG qxLnWRwOjKgBDrQ=; b=YSGrRmXY76fbUtPERuSV+9e6lsEx56hA5vrGlNt2Qpgs zOPKczGZQJsxK88Md2RogOECuW5zwHOeJnPTijXakF/dmAlb5LGVud5m+mQe5Sl7 Nx+dNIsVXROz/pUj6cCxv3K2uWryMWKWKGA87vjkcV2kZd3PrAyjrivRHG//4Cy0 8npyhIOZIK0GH7J2zQzX6NbvhdhETzfHNoxutJTlJzbT/hn62C0tzHeBHUXEmf+L nIWXmDFc1kwRBghV8udUcYftvhHn+v2vzmUQ7nlzQb7ok4/4d57hANxyRbucnqdL hJAerM1Ql35aS0OaCNwHAOYgRUdk2HE+fkLZivJ7tw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrvdeliedgjeelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkfhggtggujgesghdtreertddtudenucfhrhhomhepofgrgihi mhgvucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucggtffrrg htthgvrhhnpeejveefheefkeeiffegveelveetgffffeektdefuefhtedtgeejhefggedu ffffudenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe hmrgigihhmvgestggvrhhnohdrthgvtghh X-ME-Proxy: Feedback-ID: i8771445c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 5 Sep 2022 10:28:46 -0400 (EDT) Date: Mon, 5 Sep 2022 16:28:42 +0200 From: Maxime Ripard To: Mateusz Kwiatkowski Subject: Re: [PATCH v2 19/41] drm/modes: Introduce the tv_mode property as a command-line option Message-ID: <20220905142842.c3rvtupggdmavq7z@houat> References: <20220728-rpi-analog-tv-properties-v2-0-459522d653a7@cerno.tech> <20220728-rpi-analog-tv-properties-v2-19-459522d653a7@cerno.tech> <2f607c7d-6da1-c8df-1c02-8dd344a92343@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="a666jub4kxs6fn4h" Content-Disposition: inline In-Reply-To: <2f607c7d-6da1-c8df-1c02-8dd344a92343@gmail.com> X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Karol Herbst , David Airlie , nouveau@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Phil Elwell , Emma Anholt , Samuel Holland , Jernej Skrabec , Chen-Yu Tsai , Geert Uytterhoeven , Ben Skeggs , linux-sunxi@lists.linux.dev, Thomas Zimmermann , intel-gfx@lists.freedesktop.org, Hans de Goede , Rodrigo Vivi , linux-arm-kernel@lists.infradead.org, Tvrtko Ursulin , Dom Cobley , Dave Stevenson , linux-kernel@vger.kernel.org, Noralf =?utf-8?Q?Tr=C3=B8nnes?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" --a666jub4kxs6fn4h Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Sep 02, 2022 at 12:46:29AM +0200, Mateusz Kwiatkowski wrote: > > @@ -2212,20 +2239,22 @@ struct drm_named_mode { > > =A0=A0=A0 =A0unsigned int xres; > > =A0=A0=A0 =A0unsigned int yres; > > =A0=A0=A0 =A0unsigned int flags; > > +=A0=A0 =A0unsigned int tv_mode; > >=A0 }; >=20 > Are _all_ named modes supposed to be about analog TV? > > If so, then probably this structure should be renamed drm_named_analog_tv= _mode > or something. I don't think they need to, but it's the only use case we've had so far. We could also imagine using UHD for 3840x2160 for example, so I wouldn't say it's limited to analog tv. > If not, then including tv_mode in all of them sounds almost dangrous. 0 i= s a > valid value for enum drm_connector_tv_mode, corresponding to > DRM_MODE_TV_MODE_NTSC_443. This is a very weird default (maybe it shouldn= 't be > the one that has a numeric value of 0?) and if there ever is a named mode= that > is not related to analog TV, it looks that it will refer to NTSC-443. >=20 > Not sure where could that actually propagate, and maybe what I'm saying c= an't > happen, but I'm imagining weird scenarios where a GPU that has both a > VGA/HDMI/whatever output, and a composite output, switches to NTSC-443 on= the > composite output by default because a named mode for the modern output is > selected. So, named modes are per-connector so the fact that there's another output doesn't really matter. Then, the answer is quite simple actually, the HDMI driver wouldn't register and use the TV mode property at all, so it would completely ignore it, no matter what value it has. So it's not really a concern. > Maybe something like DRM_MODE_TV_MODE_NONE =3D 0 would make sense? But I guess we can add it still. Maxime --a666jub4kxs6fn4h Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCYxYHmgAKCRDj7w1vZxhR xTGUAP9bRX6FEHBUM7XR2y0SEv7Im5MOyJ9Xu+nxahCL5Zr27gEAtUuO35mNsB/a iZZfvcVDyPB/1iJJ1p/8F2uKg1G0pQI= =y2zk -----END PGP SIGNATURE----- --a666jub4kxs6fn4h--