Received: by 2002:a05:6358:700f:b0:131:369:b2a3 with SMTP id 15csp2058559rwo; Thu, 3 Aug 2023 04:13:19 -0700 (PDT) X-Google-Smtp-Source: APBJJlEuimBV+ctW0Rrytyluhusormhz5w31x+tESZqPvPUCVKpoZC0xfJT7/iSMbtGewn1FMy6n X-Received: by 2002:a17:907:2cd2:b0:99b:55e3:bbd with SMTP id hg18-20020a1709072cd200b0099b55e30bbdmr7500405ejc.34.1691061198552; Thu, 03 Aug 2023 04:13:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691061198; cv=none; d=google.com; s=arc-20160816; b=z47Y192ZuILUPWXhPXEg0vETcTV/o8aQ93lZb+b+99YU0z8Mk0UFPOdXCiOKyYycr/ 8FgofSaBLsA7edvJIaS+YPx2yf9/Cyq06SRr/F7xHGG0UAzUoQOCgDeuTJyqxFDAtosZ tlqnK0dt4/DeZyLk6j/IE259bUJHpx74f1gqBubXJweSVYfnzSXlfvwR6sh8z2sIvRie WVFhG7yPZav5seizTQXmLC+jYZ8kaj9FpUUh1DdFZq0NKje2+Lpjpmb33rI66LMG28Wc dB9UzQe/gjV5ZUCT2DEJo+jr8AltoPcXH+h4HCMzChlnyPorKvY3hSNJQonm68mF7F+p VBcw== 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:dkim-signature; bh=M7mKv7aFom4lStcfY4aW++sZ1R7wmmAzxjw85MUjNDU=; fh=62T1aMuPPcfAQYqFr23AsZU0MBzAs1ljOapr7kkmSJo=; b=qT5bgfiJ186dit52HGRhiFu9VOkvn0tSNl47XRSRl2PlgEIDwhqAi7axPKpUFgVNMM 9VbT1oHBEOuxYVj/vOipIWMNWUBFPzamHItPIdP+vWW1+MmDpnY5sO/kPu/Fzumphh7u E1GLPMC4hmZQqtVfSogJRoKIVpUkcwIwvT7V2F0itAUJvn4xLBHrDxzlX6Kvz5YPuzpD r4futAbZ3K1KuUjtlG9pmj2mycV5grfP+I7W2C3DL1rhfJWOxq0gjEe62n+N4x4ZF+16 EbPolyVb8dEnb0FTsUdqzOudJZd/X9uFBjXVKDZm0/sM0GlLb92I0pSNQje1Sg89IQ6s xo8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ILvlrqde; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e6-20020a1709067e0600b0099bcf2fbb11si1956998ejr.138.2023.08.03.04.12.54; Thu, 03 Aug 2023 04:13:18 -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=@kernel.org header.s=k20201202 header.b=ILvlrqde; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235061AbjHCJjp (ORCPT + 99 others); Thu, 3 Aug 2023 05:39:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33778 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233311AbjHCJj1 (ORCPT ); Thu, 3 Aug 2023 05:39:27 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2013D4694; Thu, 3 Aug 2023 02:38:32 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 99AD261D17; Thu, 3 Aug 2023 09:38:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 82A84C433C7; Thu, 3 Aug 2023 09:38:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1691055511; bh=M7mKv7aFom4lStcfY4aW++sZ1R7wmmAzxjw85MUjNDU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ILvlrqdelXLsQ94SKYibc+TpHrnegKXc1xtybeWaEJOYmGgq1eX4rzESkLuMcVuJ0 7nSBnBCt7wbbGd0S+wPwKV8XjX7ch+9opQSP3uKR3fUW1Z47OUtzMDHXNNMwNr/RuH uV8gUP7p327Gi/1faGdYXIPOY7lFPw/F+g5ETgci34A6FZ1IeNMvUHRrJQp0y+OWx5 NzdR6938SLhAu54kd4dRNxSvgOjqigi0YXAScsIKaAx224bGdjgLTN+/DACng+bguA hARqk/iCof8jz/I0zv/HXG0XBykPvPNN4ev/Ob1x6jkiPPc9WUrjsrQSIUWliTmOCr 4wqgBzNBDDJKA== Date: Thu, 3 Aug 2023 11:38:28 +0200 From: Maxime Ripard To: Neil Armstrong Cc: Michael Riesch , Sam Ravnborg , Sebastian Reichel , Gerald Loacker , David Airlie , Miquel Raynal , Conor Dooley , Krzysztof Kozlowski , Rob Herring , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: Re: [PATCH 0/4] drm/panel: sitronix-st7789v: add support for partial mode Message-ID: References: <20230718-feature-lcd-panel-v1-0-e9a85d5374fd@wolfvision.net> <292c3e7d-82ea-2631-bd4b-ef747f56287c@linaro.org> <9f0670a7-6ef6-7823-19c2-de10683f303f@linaro.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="iqykblsj6nj6m3cz" Content-Disposition: inline In-Reply-To: <9f0670a7-6ef6-7823-19c2-de10683f303f@linaro.org> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 --iqykblsj6nj6m3cz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Aug 03, 2023 at 11:30:52AM +0200, Neil Armstrong wrote: > On 03/08/2023 11:22, Maxime Ripard wrote: > > On Thu, Aug 03, 2023 at 10:51:57AM +0200, Daniel Vetter wrote: > > > On Thu, Aug 03, 2023 at 10:48:57AM +0200, Maxime Ripard wrote: > > > > On Thu, Aug 03, 2023 at 10:11:22AM +0200, Neil Armstrong wrote: > > > > > Hi, > > > > >=20 > > > > > On 18/07/2023 17:31, Michael Riesch wrote: > > > > > > Hi all, > > > > > >=20 > > > > > > This series adds support for the partial display mode to the Si= tronix > > > > > > ST7789V panel driver. This is useful for panels that are partia= lly > > > > > > occluded by design, such as the Jasonic JT240MHQS-HWT-EK-E3. Su= pport > > > > > > for this particular panel is added as well. > > > > > >=20 > > > > > > Note: This series is already based on > > > > > > https://lore.kernel.org/lkml/20230714013756.1546769-1-sre@kerne= l.org/ > > > > >=20 > > > > > I understand Maxime's arguments, but by looking closely at the co= de, > > > > > this doesn't look like an hack at all and uses capabilities of the > > > > > panel controller to expose a smaller area without depending on any > > > > > changes or hacks on the display controller side which is coherent. > > > > >=20 > > > > > Following's Daniel's summary we cannot compare it to TV overscan > > > > > because overscan is only on *some* displays, we can still get 100% > > > > > of the picture from the signal. > > > >=20 > > > > Still disagree on the fact that it only affects some display. But i= t's > > > > not really relevant for that series. > > >=20 > > > See my 2nd point, from a quick grep aside from i915 hdmi support, no = one > > > else sets all the required hdmi infoframes correctly. Which means on a > > > compliant hdmi tv, you _should_ get overscan. That's how that stuff is > > > speced. > > >=20 > > > Iirc you need to at least set both the VIC and the content type, maybe > > > even more stuff. > > >=20 > > > Unless all that stuff is set I'd say it's a kms driver bug if you get > > > overscan on a hdmi TV. > >=20 > > I have no doubt that i915 works there. The source of my disagreement is > > that if all drivers but one don't do that, then userspace will have to > > care. You kind of said it yourself, i915 is kind of the exception there. > >=20 > > The exception can be (and I'm sure it is) right, but still, it deviates > > from the norm. >=20 > HDMI spec is hidden behind a paywall, HDMI testing is a mess, HDMI real > implementation on TVs and Displays is mostly broken, and HDMI certificati= on > devices are too expensive... this is mainly why only i915 handles it corr= ectly. Sure, I know all that, it's why I was disagreeing with the fact that it's mostly old news and we shouldn't care anymore. And it could largely be fixed if i915 was using more helpers in general. But that's a separate discussion entirely. The point I was trying to make is that it's still very much the current situation for the vast majority of drivers, for whatever reason, so we can't really treat as if it isn't anymore. > > > > I think I'll still like to have something clarified before we merge= it: > > > > if userspace forces a mode, does it contain the margins or not? I d= on't > > > > have an opinion there, I just think it should be documented. > > >=20 > > > The mode comes with the margins, so if userspace does something really > > > funny then either it gets garbage (as in, part of it's crtc area isn't > > > visible, or maybe black bars on the screen), or the driver rejects it > > > (which I think is the case for panels, they only take their mode and > > > nothing else). > >=20 > > Panels can usually be quite flexible when it comes to the timings they > > accept, and we could actually use that to our advantage, but even if we > > assume that they have a single mode, I don't think we have anything that > > enforces that, either at the framework or documentation levels? >=20 > Yep, this is why we would need a better atomic based panel API that would > permit us handling dynamic timings for panel and get out of the single-mo= de > for modern panels. Again, I definitely agree on the new API, but that seems a bit out of scope :) My point was that we can't expect modes to be the one we provided in =2Eget_modes. And that's for all the drivers, even i915 doesn't do it (as far as I could see) Maxime --iqykblsj6nj6m3cz Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQRcEzekXsqa64kGDp7j7w1vZxhRxQUCZMt1lAAKCRDj7w1vZxhR xQMaAPwNXMv/pcq5vo5GVXn54SaI8sUtQ/LzmvdqFrXqkE3MNwEAvFr+U9cZYjDw s1xrtXXgBzW8oBHSoQuxtTTLKhFzYAs= =JLy4 -----END PGP SIGNATURE----- --iqykblsj6nj6m3cz--