All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brian Masney <bmasney@redhat.com>
To: Hans de Goede <johannes.goede@oss.qualcomm.com>
Cc: Michael Turquette <mturquette@baylibre.com>,
	Stephen Boyd <sboyd@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	Javier Martinez Canillas <javierm@redhat.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>, Helge Deller <deller@gmx.de>,
	Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konradybcio@kernel.org>,
	Dmitry Baryshkov <lumag@kernel.org>,
	Rob Clark <robin.clark@oss.qualcomm.com>,
	linux-clk@vger.kernel.org, dri-devel@lists.freedesktop.org,
	~postmarketos/upstreaming@lists.sr.ht
Subject: Re: [PATCH 0/3] clk: Add __clk_disable_unprepare_counts_only() and use this in simple[fb|drm]
Date: Wed, 27 May 2026 19:03:58 -0400	[thread overview]
Message-ID: <ahd4XgTo3KZqGS9M@redhat.com> (raw)
In-Reply-To: <20260527094811.116977-1-johannes.goede@oss.qualcomm.com>

Hi Hans,

On Wed, May 27, 2026 at 11:48:08AM +0200, Hans de Goede wrote:
> 2) One option considered was detaching the simple-framebuffer driver later,
>    after the real display driver has had a chance to claim the clocks. But
>    this won't work in cases where the real display driver picks different
>    parent clocks then the boot firmware did and needs to reparent clocks.

Why won't that work in the case where different parent clocks are selected?
I'll describe a scenario below.

> 
>    Basically the goal is for things to behave as if the simple-framebuffer
>    driver was not there at all, because that leaves the hw in the state
>    the real display driver expects.

I think the deferred unbinding could have some potential here where
there is some kind of notification mechanism between simple-framebuffer
and the real drm driver. So:

- simple-framebuffer driver takes reference(s) to the clk(s).

- real drm driver eventually loads, takes reference(s) to the necessary
  clk(s).

- real drm driver sends a notification to simple-framebuffer that it's
  done, and has control.

- simple-framebuffer can unbind and release its references to the clks.

No clks will be shutdown prematurely in this scenario.

If the real drm driver needs a different parent, then presumably things
should be setup correctly, and simple-framebuffer can have the clocks
shut down when it calls clk_disable_unprepare(). If the real drm driver
needed those clks, then it should hold a reference to them.

I'm intentionally not going through how to do the notification mechanism
here.

Brian


  parent reply	other threads:[~2026-05-27 23:04 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-27  9:48 [PATCH 0/3] clk: Add __clk_disable_unprepare_counts_only() and use this in simple[fb|drm] Hans de Goede
2026-05-27  9:48 ` [PATCH 1/3] clk: Add __clk_disable_unprepare_counts_only() helper Hans de Goede
2026-05-27  9:48 ` [PATCH 2/3] drm/sysfb: simpledrm: Use __clk_disable_unprepare_counts_only() Hans de Goede
2026-05-27  9:48 ` [PATCH 3/3] fbdev: simplefb: " Hans de Goede
2026-05-27 12:04 ` [PATCH 0/3] clk: Add __clk_disable_unprepare_counts_only() and use this in simple[fb|drm] Maxime Ripard
2026-05-27 12:21   ` Hans de Goede
2026-05-27 12:48     ` Maxime Ripard
2026-05-27 15:09       ` Hans de Goede
2026-05-28 12:01         ` Maxime Ripard
2026-05-27 23:03 ` Brian Masney [this message]
2026-05-28 10:12   ` Hans de Goede
2026-05-28 12:08     ` Maxime Ripard
2026-05-28 13:02       ` Hans de Goede

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=ahd4XgTo3KZqGS9M@redhat.com \
    --to=bmasney@redhat.com \
    --cc=andersson@kernel.org \
    --cc=deller@gmx.de \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=javierm@redhat.com \
    --cc=johannes.goede@oss.qualcomm.com \
    --cc=konradybcio@kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=lumag@kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=robin.clark@oss.qualcomm.com \
    --cc=sboyd@kernel.org \
    --cc=tzimmermann@suse.de \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.