Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp634227rwe; Thu, 25 Aug 2022 06:45:00 -0700 (PDT) X-Google-Smtp-Source: AA6agR67rsqAb8/kdL2WoVTQVkUADyOT1QV9DimoDLvhPQvY8fk7HI79noNuG5SgoU3Vm2/BkCSZ X-Received: by 2002:a05:6402:50cb:b0:440:8bac:1e02 with SMTP id h11-20020a05640250cb00b004408bac1e02mr3368808edb.336.1661435100425; Thu, 25 Aug 2022 06:45:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661435100; cv=none; d=google.com; s=arc-20160816; b=dMuTPqjmnk0QKQ2isyK4rWzb//arlu/+BkAgbw1JCLBbm+w7NU0iEEbaMqQbaRFl5f 9s4hCo4ZnoUc1SeZKrfoYVBhcbY4n8kGLqE0I9nUzY+8fNIzyg6UZb7jbVIRK9FnftGg jeHcRscL0BzqZpLqI0LqWN0RvsmsK25PQsRUuaEz1DQpHj2OmW+QdANcYjay68OIOasx zsSvwdhhoewL0pEAEpda+X0qkEiSIxmc5ICZkkEVxsAoDmPVCFLQQN0abJ539a65QfYh FV8c97fJj07EwNNyHxvcspUxqBO0cOa/KnIAOwV1FNtTFsOQ8JLrrBxlp7Dej9j3clTO Ysyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:feedback-id :dkim-signature:dkim-signature; bh=xufXNQfWsW5YMPwr77PxDXziEf7hBPLQzvXQIo3+2+Y=; b=JPvbF652sBPSzHCLCR4OF81gPmfh0FJUT4Jy+S/BtshdnfkPR646qMi9UvHtAcytdo ag2QXPPjFCali/hP1UmT8MD351qzC+D8JWONeteRGIXYgHyNcLftFipkC29To4f4QXMc K5XO0fymwzKUYZRt/9YjJxlRPNK5WMJhkIY7TcmauC+wY2j4KkYYFFAecTqVvBPuRIMw +RI5Fmp5Pp85x4INECQ70vUWzh0jQ0edc54kbtkrfihIEi3aym6cvMuS8IEvYJCNenMq IrLY6uHN30bw8zqDwYS8+/fzWu4XQq7pguk56M65IOT8IUEGuQ9GqrrKvdP0wAbfGQle kCWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cerno.tech header.s=fm3 header.b=KRY3ZJmL; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=RZH4Z4XZ; 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=cerno.tech Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ne33-20020a1709077ba100b007318692f59csi4729480ejc.935.2022.08.25.06.44.34; Thu, 25 Aug 2022 06:45:00 -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=@cerno.tech header.s=fm3 header.b=KRY3ZJmL; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=RZH4Z4XZ; 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=cerno.tech Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240803AbiHYNjx (ORCPT + 99 others); Thu, 25 Aug 2022 09:39:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54248 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240817AbiHYNjv (ORCPT ); Thu, 25 Aug 2022 09:39:51 -0400 Received: from new2-smtp.messagingengine.com (new2-smtp.messagingengine.com [66.111.4.224]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C8CC2124 for ; Thu, 25 Aug 2022 06:39:45 -0700 (PDT) Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailnew.nyi.internal (Postfix) with ESMTP id F18DC5802D2; Thu, 25 Aug 2022 09:39:41 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Thu, 25 Aug 2022 09:39:42 -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=1661434781; x=1661441981; bh=xufXNQfWsW 5YMPwr77PxDXziEf7hBPLQzvXQIo3+2+Y=; b=KRY3ZJmLUrz8S7afTCwjV+6oVP hTtlebvUk7hjY/8s8PwqdJ3R9Z0EwogT5IbBAVEgOBSZdEtrSbrxTFN7gEX61ztq cidK+o2bTLG8i+LOdAXUqS1tE4UryHbuz7CY1fbrzvsuPUUomb5r1A6txmAcTMpW dWs/kEzOME+WWG3iOdu/czo1E7VQBI0qFo5hTRu9UBxucz43OTruG8RdlfPshahK fsPYnLq/KywCkzc9uQgpaQxoFy5bDDDUOeTEipfnBiFLR4EXkGr2YTU4v/7UBKXG U6S9ryjKeoVFgO2SKJbMuuVo7c3bXNgvxwVvGAw5Ly9kTCz1DWnyeEycm7ag== 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=1661434781; x=1661441981; bh=xufXNQfWsW5YMPwr77PxDXziEf7h BPLQzvXQIo3+2+Y=; b=RZH4Z4XZhMW0HQ0yV+K9lv2Xk6n+odMvjRg4xiem1unP y44V2lmeJSbc3J3Yf/Z58mYGcwKGkz/x4S0mRomdYq+JMe0Klp6+OpSo0D5oWp2g yQBPMbNY+RMZRW1tyrMPJp4zn+JFk4xCfVCdZVQMLnj0zMjU881wkyt0XZbxtxoM Sord2tDZWNYw4fXxTms0I7824hrZwosPGAWDWMDy+CU6/PRuutKgEcAMD5yU+pwR gq41cv3QRCbf+fp64eaTAAk32G7yPKeAyTtApBqz5HJWboB/D/pnpALfx4V6lIz2 zItw1gBXht3MnRipo0H1OztZu77gosZPc9GL6fkmIA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrvdejfedgieehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkfhggtggujgesghdtreertddtvdenucfhrhhomhepofgrgihi mhgvucftihhprghrugcuoehmrgigihhmvgestggvrhhnohdrthgvtghhqeenucggtffrrg htthgvrhhnpedtleekjeeiudefvdfhieffteelhfeivdeliefgieeugffhvdelieffjeei geetjeenucffohhmrghinhepkhgvrhhnvghlrdhorhhgnecuvehluhhsthgvrhfuihiivg eptdenucfrrghrrghmpehmrghilhhfrhhomhepmhgrgihimhgvsegtvghrnhhordhtvggt hh X-ME-Proxy: Feedback-ID: i8771445c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 25 Aug 2022 09:39:39 -0400 (EDT) Date: Thu, 25 Aug 2022 15:39:36 +0200 From: Maxime Ripard To: Geert Uytterhoeven Cc: Jernej Skrabec , Martin Blumenstingl , Chen-Yu Tsai , Philipp Zabel , Jerome Brunet , Samuel Holland , Thomas Zimmermann , Daniel Vetter , Emma Anholt , David Airlie , Maarten Lankhorst , Noralf =?utf-8?Q?Tr=C3=B8nnes?= , Kevin Hilman , Neil Armstrong , linux-sunxi@lists.linux.dev, Linux Kernel Mailing List , Phil Elwell , Mateusz Kwiatkowski , Linux ARM , Dave Stevenson , "open list:ARM/Amlogic Meson..." , DRI Development , Dom Cobley Subject: Re: [PATCH v1 05/35] drm/connector: Add TV standard property Message-ID: <20220825133936.gnpgdtx4jedei5a6@houat> References: <20220817074710.w4c4xwj7edly2b5p@houat> <20220817111454.pn2iltvyo2drebq7@houat> <20220817131854.jwmhqvhfhp77bbr3@houat> <20220818145436.vqojnhmvhjxdzooe@houat> <20220818153442.u4knumkfbe7j6zj3@houat> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="abetw7tfzbu2b4iz" Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 --abetw7tfzbu2b4iz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi, On Fri, Aug 19, 2022 at 11:35:42AM +0200, Geert Uytterhoeven wrote: > On Thu, Aug 18, 2022 at 5:34 PM Maxime Ripard wrote: > > On Thu, Aug 18, 2022 at 05:20:42PM +0200, Geert Uytterhoeven wrote: > > > On Thu, Aug 18, 2022 at 4:54 PM Maxime Ripard wro= te: > > > > On Wed, Aug 17, 2022 at 04:04:24PM +0200, Geert Uytterhoeven wrote: > > > > > On Wed, Aug 17, 2022 at 3:19 PM Maxime Ripard = wrote: > > > > > > On Wed, Aug 17, 2022 at 03:05:52PM +0200, Geert Uytterhoeven wr= ote: > > > > > > > On Wed, Aug 17, 2022 at 1:15 PM Maxime Ripard wrote: > > > > > > > > On Wed, Aug 17, 2022 at 10:35:07AM +0200, Geert Uytterhoeve= n wrote: > > > > > > > > > On Wed, Aug 17, 2022 at 9:47 AM Maxime Ripard wrote: > > > > > > > > > > On Wed, Aug 17, 2022 at 09:31:18AM +0200, Geert Uytterh= oeven wrote: > > > > > > > > > > > On Tue, Aug 16, 2022 at 5:50 PM Maxime Ripard wrote: > > > > > > > > > > > > On Tue, Aug 16, 2022 at 04:43:44PM +0200, Geert Uyt= terhoeven wrote: > > > > > > > > > > > > > > > > > Either you have to add them here (e.g. "h= d720p50" and "hd720p60"), or > > > > > > > > > > > > > > > > > handle them through "@". The la= tter would impact "[PATCH v1 > > > > > > > > > > > > > > > > > 09/35] drm/modes: Move named modes parsin= g to a separate function", as > > > > > > > > > > > > > > > > > currently a named mode and a refresh rate= can't be specified both. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > I think the former would make more sense. I= t simplifies a bit the > > > > > > > > > > > > > > > > parser, and we're going to use a named mode= anyway. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > As "[PATCH v1 34/35] drm/modes: Introduce= the tv_mode property as a > > > > > > > > > > > > > > > > > command-line option" uses a separate "tv_= mode" option, and not the main > > > > > > > > > > > > > > > > > mode name, I think you want to add them h= ere. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > It's a separate story I think, we could hav= e a named mode hd720p50, > > > > > > > > > > > > > > > > which would be equivalent to 1280x720,tv_mo= de=3Dhd720p > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > So where's the field rate in "1280x720,tv_mod= e=3Dhd720p"? > > > > > > > > > > > > > > > > > > > > > > > > > > > > Yeah, sorry I meant 1280x720@50,tv_mode=3Dhd720p > > > > > > > > > > > > > > > > > > > > > > > > > > Above you said "I think the former would make mor= e sense", so that > > > > > > > > > > > > > should be "1280x720,tv_mode=3Dhd720p50"? > > > > > > > > > > > > > > > > > > > > > > > > No, 720p at 50Hz would be either hd720p50 or 1280x7= 20@50,tv_mode=3Dhd720p > > > > > > > > > > > > and 60Hz would be hd720p60 or 1280x720@60,tv_mode= =3Dhd720p > > > > > > > > > > > > > > > > > > > > > > I disagree: hd720p50 and hd720p60 are different TV mo= des. > > > > > > > > > > > > > > > > > > > > I agree, and I don't see how that command-line doesn't = express that? > > > > > > > > > > > > > > > > > > Oh, I see what you mean: yes, it expresses that. > > > > > > > > > But it is inconsistent with the NTSC/PAL/SECAM/hd{480,576= }[ip] modes, > > > > > > > > > where the TV mode specifies both number of lines and fram= e rate. > > > > > > > > > > > > > > > > Only if we're using a named mode, and naming is hard :) > > > > > > > > > > > > > > That's not true: "640x480,tv_mode=3DPAL-N" would give me a mo= de with > > > > > > > 625 lines and 25 frames/s, "640x480,tv_mode=3DPAL-M" would gi= ve me a > > > > > > > mode with 525 lines and 30 frames/s. > > > > > > > > > > > > In that series, "640x480,tv_mode=3DPAL-N" would be rejected as = invalid: > > > > > > > > > > > > https://lore.kernel.org/dri-devel/20220728-rpi-analog-tv-proper= ties-v1-14-3d53ae722097@cerno.tech/ > > > > > > > > > > It would become supported once the ideas from thread "[PATCH v1 0= 4/35] > > > > > drm/modes: Introduce 480i and 576i modes" are implemented... > > > > > > > > Indeed, but I'm still not sure what your concern is here. > > > > "640x480,tv_mode=3DPAL-N" and "640x480,tv_mode=3DPAL-M" are both fa= irly > > > > obvious. > > > > > > > > You were initially saying that you had concern over the inconsisten= cy of > > > > NTSC/PAL/SECAM where the TV mode would specify a number of lines and > > > > frame rate, but hd720p50 also specifies a number of line and frame = rate? > > > > > > My concern is that you want to call the TV mode "hd720p", which > > > does not dictate the frame rate. > > > I would like to have both "720p50" and "720p60", as they do dictate > > > the frame rate, like all the non-hd modes. > > > > But they don't? > > > > The refresh rate is part of the drm_display_mode, whereas that property > > is metadata and entirely separate from the display mode. > > > > You can even change it without changing the mode at all >=20 > Yes, the refresh rate is part of drm_display_mode. Vdisplay also > is, but that doesn't mean you can set it to e.g. 700 when using > "tv_mode=3DPAL-B". Some (combination of) parameters in drm_display_mode > are dictated by the tv_mode. But the opposite is also true: PAL-B and SECAM-B would be two different TV mode, but (could) have the same display mode. There's no equivalence or implication in that relationship, except for a smaller set of those parameters. But it's the entire display mode that we should compare. > Perhaps the meaning of "tv_mode" should be clarified? What does it > really mean, and what parameters does it (not) constrain? As far as I'm concerned, it's only about the encoding. We can check after the fact that, say, you don't try to use a mode line with than 525 lines and some NTSC variant, but the mode has precedence over the property. > For e.g. "PAL-B", I know it's a mode with 625 lines and 30 frames/s > (60 fields/s). > For "hd720p" I know it is an analog mode with 750 lines, but it's still > ambiguous, as I don't know if it is the variant with 60 or 50 frames/s. As far as the TV mode property is concerned, it doesn't encode neither whether it has 750 lines, nor the refresh rate. If you're talking about a named mode, then yeah, it's basically an alias for a mode + a property, so it does, but we can choose names that aren't ambiguous. Maxime --abetw7tfzbu2b4iz Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCYwd7mAAKCRDj7w1vZxhR xZkBAQDrEXnDTiQIDw7WVDdGrymHTzA68O6aoUE0nXlp+5E0EAEAzwBa5cUcNh9j iMwk3ETvnvqMbV5kyg5f+gPHMuMLswM= =NZmB -----END PGP SIGNATURE----- --abetw7tfzbu2b4iz--