mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
To: Alexey Minnekhanov <alexeymin@minlexx.ru>,
	Paul Sajna <sajattack@postmarketos.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konradybcio@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	David Heidelberg <david@ixit.cz>
Cc: linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, phone-devel@vger.kernel.org,
	Amir Dahan <system64fumo@protonmail.com>,
	Christopher Brown <crispybrown@gmail.com>
Subject: Re: [PATCH v2 09/13] arm64: dts: qcom: sdm845-lg-judyln: Add fb_panel dimensions
Date: Tue, 7 Oct 2025 15:55:35 +0200	[thread overview]
Message-ID: <e58978d6-dc6a-468f-91d5-29d7b0755e79@oss.qualcomm.com> (raw)
In-Reply-To: <ac2d419d-a1b4-4b3f-a07a-4f5d047901aa@minlexx.ru>

On 9/17/25 4:54 PM, Alexey Minnekhanov wrote:
> On 17.09.2025 16:59, Konrad Dybcio wrote:
>> On 9/17/25 3:09 AM, Paul Sajna wrote:
>>> Add display dimensions for proper scaling
>>>
>>> Signed-off-by: Paul Sajna <sajattack@postmarketos.org>
>>> ---
>>>   arch/arm64/boot/dts/qcom/sdm845-lg-judyln.dts | 7 +++++++
>>>   1 file changed, 7 insertions(+)
>>>
>>> diff --git a/arch/arm64/boot/dts/qcom/sdm845-lg-judyln.dts b/arch/arm64/boot/dts/qcom/sdm845-lg-judyln.dts
>>> index e84b45ed82fd13850ea7ec1f34ddac5b59fc1434..8c1692f86e6ceea7b718361965e78f95d39373bb 100644
>>> --- a/arch/arm64/boot/dts/qcom/sdm845-lg-judyln.dts
>>> +++ b/arch/arm64/boot/dts/qcom/sdm845-lg-judyln.dts
>>> @@ -23,6 +23,13 @@ framebuffer@9d400000 {
>>>               format = "a8r8g8b8";
>>>               lab-supply = <&lab>;
>>>               ibb-supply = <&ibb>;
>>> +
>>> +            panel = <&fb_panel>;
>>> +
>>> +            fb_panel: fb-panel {
>>> +                width-mm = <65>;
>>> +                height-mm = <140>;
>>
>> It'd be nicer if you moved these properties to the actual panel
>> node (the DSI one) and referenced that one instead (I think that
>> should work)
>>
>> Konrad
>>
> 
> Hi!
> 
> First of all this code doesn't work well for upstream, because it causes
> errors with dtbs checks like:
> 
>   framebuffer@9d400000 (simple-framebuffer): 'fb-panel' does not match any of the regexes: '^[a-zA-Z0-9-]+-supply$', '^pinctrl-[0-9]+$'
> 
> ^^ The subnode is not allowed by bindings.
> 
> The whole reasoning for this little hack is that the upstream
> recommended approach to solve the "unknown DPI" for framebuffer issue
> is to put width-mm, height-mm into real panel node and and reference it
> in simple-fb node - sonds very nice in theory, but also doesn't work
> well in practice, and explanation why will take a bit longer, please
> bear with me for a minute.
> 
> If we do as recommended, device tree structure will look like this:
> 
>  framebuffer@9d400000 {
>      ...
>      panel = <&display_panel>;
>  };
> 
>  soc@0 {
>      ....
> 
>      mdss {
>          ...
>          dsi0 {
>              ...
>              display_panel: panel@0 {
>                  reg = <0>;
>                  compatible = "lg,sw49410";
>                  ...
>                  width-mm = <65>;
>                  height-mm = <140>;
>              };
>          ...
> 
> Then, to my understanding, due to how fw-devlink works, the panel=<&..>
> link from simplefb node to display_panel node creates a probe-time
> dependency, so that the whole display stack probes first: MDSS, DSI
> controller, maybe even Adreno GPU, *AND* panel all probe first, thus
> making the mere existence of simple-framebuffer pointless.
> 
> Additionally, simple-framebuffer probes succesfully after that,
> creating "second GPU" entry in as /dev/dri/card1 making it look like
> system has 2 GPUS, which confuses almost every window manager in
> userspace later. Normally, if simplefb probes first, it gets unloaded
> and replaced by MDSS and does not cause any chaos. In the end the whole
> situation looks even more silly than the fake panel subnode hack.
> 
> Therefore for upstream I'd recommend to just drop any fb-panel hacks and
> to not use panel=<&...> with reference to real panel either.
> 
> It would all be much much easier if we could just specify width-mm/
> height-mm directly in simplefb node, but DT maintainers rejected that idea.

Would adding post-init-providers = <&real_panel> help?

Konrad

  reply	other threads:[~2025-10-07 13:55 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-17  1:09 [PATCH v2 00/13] arm64: dts: qcom: sdm845-lg-{common, judyln}: Improve HW support in dts Paul Sajna
2025-09-17  1:09 ` [PATCH v2 01/13] arm64: dts: qcom: sdm845-lg-common: Sort nodes and properties Paul Sajna
2025-09-17 13:38   ` Konrad Dybcio
2025-09-18  3:13   ` Dmitry Baryshkov
2025-09-17  1:09 ` [PATCH v2 02/13] arm64: dts: qcom: sdm845-lg-common: Add uarts and Bluetooth Paul Sajna
2025-09-17 13:40   ` Konrad Dybcio
2025-09-18  2:17     ` Paul Sajna
2025-09-17  1:09 ` [PATCH v2 03/13] arm64: dts: qcom: sdm845-lg-judyln: Add battery and charger Paul Sajna
2025-09-17 13:47   ` Konrad Dybcio
2025-09-18  1:44     ` Chris Brown
     [not found]     ` <CABN5=wFgARbrhqyNbgQ_iMKPt8M7ixZPEhvXVd6AY+Jv+7=YWw@mail.gmail.com>
2025-10-07 13:52       ` Konrad Dybcio
2025-10-23  9:12     ` Pavel Machek
2025-09-17  1:09 ` [PATCH v2 04/13] arm64: dts: qcom: sdm845-lg-common: Add leds Paul Sajna
2025-09-17 13:42   ` Konrad Dybcio
2025-10-23  9:10   ` Pavel Machek
2025-09-17  1:09 ` [PATCH v2 05/13] arm64: dts: qcom: sdm845-lg-judyln: Add display panel Paul Sajna
2025-09-17 13:50   ` Konrad Dybcio
2025-09-18  1:51     ` Paul Sajna
     [not found]     ` <da2f17a144374f326de9e0c5bec638829a31cd1e@postmarketos.org>
2025-10-07 13:53       ` Konrad Dybcio
2025-09-17  1:09 ` [PATCH v2 06/13] arm64: dts: qcom: sdm845-lg-judyln: Add firmware nodes Paul Sajna
2025-09-17 13:51   ` Konrad Dybcio
2025-09-18  1:52     ` Paul Sajna
2025-09-17  1:09 ` [PATCH v2 07/13] arm64: dts: qcom: sdm845-lg-{common, judyln}: Add wifi node Paul Sajna
2025-09-17 13:44   ` Konrad Dybcio
2025-09-17  1:09 ` [PATCH v2 08/13] arm64: dts: qcom: sdm845-lg-common: Add chassis-type Paul Sajna
2025-09-17 13:44   ` Konrad Dybcio
2025-09-17  1:09 ` [PATCH v2 09/13] arm64: dts: qcom: sdm845-lg-judyln: Add fb_panel dimensions Paul Sajna
2025-09-17 13:59   ` Konrad Dybcio
2025-09-17 14:54     ` Alexey Minnekhanov
2025-10-07 13:55       ` Konrad Dybcio [this message]
2025-10-09 18:02         ` Alexey Minnekhanov
2025-09-17  1:09 ` [PATCH v2 10/13] arm64: dts: qcom: sdm845-lg-common: Add camera flash Paul Sajna
2025-09-17 13:45   ` Konrad Dybcio
2025-09-17  1:09 ` [PATCH v2 11/13] arm64: dts: qcom: sdm845-lg-common: Add bootloader-compatible board and MSM IDs Paul Sajna
2025-09-17 13:55   ` Konrad Dybcio
2025-09-17 14:02     ` Stephan Gerhold
2025-09-17  1:09 ` [PATCH v2 12/13] arm64: dts: qcom: sdm845-judyln-common: Remove framebuffer reserved-mem Paul Sajna
2025-09-17 13:58   ` Konrad Dybcio
2025-09-17  1:09 ` [PATCH v2 13/13] arm64: dts: qcom: sdm845-lg-judyln: Add lab/ibb Paul Sajna
2025-09-17 13:46   ` Konrad Dybcio
2025-09-17 15:00 ` [PATCH v2 00/13] arm64: dts: qcom: sdm845-lg-{common, judyln}: Improve HW support in dts Rob Herring (Arm)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e58978d6-dc6a-468f-91d5-29d7b0755e79@oss.qualcomm.com \
    --to=konrad.dybcio@oss.qualcomm.com \
    --cc=alexeymin@minlexx.ru \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=crispybrown@gmail.com \
    --cc=david@ixit.cz \
    --cc=devicetree@vger.kernel.org \
    --cc=konradybcio@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=phone-devel@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=sajattack@postmarketos.org \
    --cc=system64fumo@protonmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®