On Fri, May 9, 2025 at 9:57 AM Luca Ceresoli <luca.ceres...@bootlin.com> wrote:
> This is the new API for allocating DRM bridges. > > Signed-off-by: Luca Ceresoli <luca.ceres...@bootlin.com> > > --- > > Cc: Alexandre Torgue <alexandre.tor...@foss.st.com> > Cc: Maxime Coquelin <mcoquelin.st...@gmail.com> > Cc: Philippe Cornu <philippe.co...@foss.st.com> > Cc: Raphael Gallais-Pou <raphael.gallais-...@foss.st.com> > Cc: Yannick Fertre <yannick.fer...@foss.st.com> > --- > drivers/gpu/drm/stm/lvds.c | 7 +++---- > 1 file changed, 3 insertions(+), 4 deletions(-) > > diff --git a/drivers/gpu/drm/stm/lvds.c b/drivers/gpu/drm/stm/lvds.c > index > a3ae9a93ce6670eb2c4dd36b3e572fcbca791a1c..07788e8d3d8302a3951e97d64736b721033998d3 > 100644 > --- a/drivers/gpu/drm/stm/lvds.c > +++ b/drivers/gpu/drm/stm/lvds.c > @@ -1049,9 +1049,9 @@ static int lvds_probe(struct platform_device *pdev) > > dev_dbg(dev, "Probing LVDS driver...\n"); > > - lvds = devm_kzalloc(dev, sizeof(*lvds), GFP_KERNEL); > - if (!lvds) > - return -ENOMEM; > + lvds = devm_drm_bridge_alloc(dev, struct stm_lvds, lvds_bridge, > &lvds_bridge_funcs); > + if (IS_ERR(lvds)) > + return PTR_ERR(lvds); > > lvds->dev = dev; > > @@ -1164,7 +1164,6 @@ static int lvds_probe(struct platform_device *pdev) > goto err_lvds_probe; > } > > - lvds->lvds_bridge.funcs = &lvds_bridge_funcs; > lvds->lvds_bridge.of_node = dev->of_node; > lvds->hw_version = lvds_read(lvds, LVDS_VERR); > > > Reviewed-by: Anusha Srivatsa <asriv...@redhat.com> Thanks, Anusha > -- > 2.49.0 > >