[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250819120138.6f656ae6@booty>
Date: Tue, 19 Aug 2025 12:01:38 +0200
From: Luca Ceresoli <luca.ceresoli@...tlin.com>
To: Maxime Ripard <mripard@...nel.org>
Cc: Inki Dae <inki.dae@...sung.com>, Jagan Teki
<jagan@...rulasolutions.com>, Marek Szyprowski <m.szyprowski@...sung.com>,
Andrzej Hajda <andrzej.hajda@...el.com>, Neil Armstrong
<neil.armstrong@...aro.org>, Robert Foss <rfoss@...nel.org>, Laurent
Pinchart <Laurent.pinchart@...asonboard.com>, Jonas Karlman
<jonas@...boo.se>, Jernej Skrabec <jernej.skrabec@...il.com>, Maarten
Lankhorst <maarten.lankhorst@...ux.intel.com>, Thomas Zimmermann
<tzimmermann@...e.de>, David Airlie <airlied@...il.com>, Simona Vetter
<simona@...ll.ch>, Hui Pu <Hui.Pu@...ealthcare.com>, Thomas Petazzoni
<thomas.petazzoni@...tlin.com>, dri-devel@...ts.freedesktop.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] samsung-dsim: move drm_bridge_add() call to probe
Hi Maxime,
On Fri, 8 Aug 2025 15:20:01 +0200
Luca Ceresoli <luca.ceresoli@...tlin.com> wrote:
> > > Some drawbacks of current code are because at every DSI attach/detach,
> > > the samsung-dsim does drm_bridge_add/remove() itself:
> > >
> > > * To me this looks like a bad design, the samsung-dsim is always
> > > present and not hotpluggable, so why should it add/remove itself?
> > >
> > > * I have a debugfs patch to show in $BUDUGFS/dri/bridges_removed all
> > > the removes bridges: bridges after drm_bridge_remove() but not yet
> > > freed because refcount still > 0. But it causes crashes due to the
> > > samsung-dsim going backwards from "removed" to "added", and further
> > > hacks are needed to avoid this crash.
I went back to my old debugfs series, updated it and sent a new
iteration:
https://lore.kernel.org/r/20250819-drm-bridge-debugfs-removed-v7-0-970702579978@bootlin.com
There you can see the lines added to drm_bridge_add() for handing
"un-removed" bridges.
It's a few lines of code only, but I don't feel very happy with them. I
look forward to knowing your opinion about those few lines.
So there were 3 issues I mentioned as reasons for this patch to
samsung-dsim (only purely technical ones, not counting the "looks like
a bad design" reason):
1. debugfs needs special care for un-removed bridges: see this e-mail
2. interferes with .gone flag: ruled out, N/A
3. needs a horrible hack in hotplug-bridge
No news about issue 3. I'm going to experiment with removing the
hotplug-bridge but that will take time (as a prerequisite I most likely
need to remove the "always connected" DSI connector first). Stay
tuned...
Best regards,
Luca
--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
Powered by blists - more mailing lists