Hi, thanks for taking a look!
> However allocating an encoder using a bridge alloc function (while we > used to call an encoder allocation function) looks counter-intuitive. > > We had discussed on IRC a different idea, adding a wrapper structure > around the bridge. Quoting your proposal: > > struct tidss_encoder_bridge { > struct drm_bridge bridge; > struct tidss_encoder *encoder > } > > and then in the bridge funcs go from drm_bridge to tidss_encoder_brigde > and use the pointer to get the original private struct. I was doing that until I've realized that meson/meson_encoder_* is doing it the way this patch does it. > That would be cleaner and more intuitive, but use a bit more memory and > have an additional pointer deref, thus I think we can live with the > patch you just sent, at least for now. I'm fine with changing it to the wrapper struct. It's your/the maintainers call :) -michael > In the long term it may be that more and more components of the DRM > subsystem become dynamically allocated like bridges and panels [0] have > recently become. So at some point it may make sense to add the bridge > wrapper struct and then go back to drmm_simple_encoder_alloc() for > allocation. > > [0] > https://lore.kernel.org/all/20250331-b4-panel-refcounting-v4-1-dad50c60c...@redhat.com/ > > Luca
signature.asc
Description: PGP signature