Re: [PATCH 3/9] drm: replace "drm_dev_unref" function with "drm_dev_put"

From: Lucas Stach
Date: Fri Nov 16 2018 - 05:15:49 EST


Am Donnerstag, den 15.11.2018, 23:16 +0100 schrieb Fernando Ramos:
> This patch unifies the naming of DRM functions for reference counting as
> requested on Documentation/gpu/todo.rst
>
> > Signed-off-by: Fernando Ramos <greenfoo@xxxxxxxxxxxxxx>
> ---
> Âdrivers/gpu/drm/arc/arcpgu_drv.cÂÂÂÂÂÂÂÂÂÂÂÂÂ| 4 ++--
> Âdrivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c | 4 ++--
> Âdrivers/gpu/drm/etnaviv/etnaviv_drv.cÂÂÂÂÂÂÂÂ| 4 ++--

At least the etnaviv part of the patch is already fixed in linux-next.

Regards,
Lucas

> Âdrivers/gpu/drm/mxsfb/mxsfb_drv.cÂÂÂÂÂÂÂÂÂÂÂÂ| 4 ++--
> Âdrivers/gpu/drm/rcar-du/rcar_du_drv.cÂÂÂÂÂÂÂÂ| 2 +-
> Âdrivers/gpu/drm/shmobile/shmob_drm_drv.cÂÂÂÂÂ| 4 ++--
> Âdrivers/gpu/drm/tve200/tve200_drv.cÂÂÂÂÂÂÂÂÂÂ| 4 ++--
> Âdrivers/gpu/drm/zte/zx_drm_drv.cÂÂÂÂÂÂÂÂÂÂÂÂÂ| 4 ++--
> Â8 files changed, 15 insertions(+), 15 deletions(-)
>
> diff --git a/drivers/gpu/drm/arc/arcpgu_drv.c b/drivers/gpu/drm/arc/arcpgu_drv.c
> index f067de4e1e82..dcb06d4e9135 100644
> --- a/drivers/gpu/drm/arc/arcpgu_drv.c
> +++ b/drivers/gpu/drm/arc/arcpgu_drv.c
> @@ -216,7 +216,7 @@ static int arcpgu_probe(struct platform_device *pdev)
> > Â arcpgu_unload(drm);
> Â
> Âerr_unref:
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â
> > Â return ret;
> Â}
> @@ -227,7 +227,7 @@ static int arcpgu_remove(struct platform_device *pdev)
> Â
> > Â drm_dev_unregister(drm);
> > Â arcpgu_unload(drm);
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â
> > Â return 0;
> Â}
> diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c
> index 843cac222e60..f8da51a63e2f 100644
> --- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c
> +++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_dc.c
> @@ -775,7 +775,7 @@ static int atmel_hlcdc_dc_drm_probe(struct platform_device *pdev)
> > Â atmel_hlcdc_dc_unload(ddev);
> Â
> Âerr_unref:
> > - drm_dev_unref(ddev);
> > + drm_dev_put(ddev);
> Â
> > Â return ret;
> Â}
> @@ -786,7 +786,7 @@ static int atmel_hlcdc_dc_drm_remove(struct platform_device *pdev)
> Â
> > Â drm_dev_unregister(ddev);
> > Â atmel_hlcdc_dc_unload(ddev);
> > - drm_dev_unref(ddev);
> > + drm_dev_put(ddev);
> Â
> > Â return 0;
> Â}
> diff --git a/drivers/gpu/drm/etnaviv/etnaviv_drv.c b/drivers/gpu/drm/etnaviv/etnaviv_drv.c
> index 83c1f46670bf..52802e6049e0 100644
> --- a/drivers/gpu/drm/etnaviv/etnaviv_drv.c
> +++ b/drivers/gpu/drm/etnaviv/etnaviv_drv.c
> @@ -550,7 +550,7 @@ static int etnaviv_bind(struct device *dev)
> Âout_bind:
> > Â kfree(priv);
> Âout_unref:
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â
> > Â return ret;
> Â}
> @@ -567,7 +567,7 @@ static void etnaviv_unbind(struct device *dev)
> > Â drm->dev_private = NULL;
> > Â kfree(priv);
> Â
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â}
> Â
> Âstatic const struct component_master_ops etnaviv_master_ops = {
> diff --git a/drivers/gpu/drm/mxsfb/mxsfb_drv.c b/drivers/gpu/drm/mxsfb/mxsfb_drv.c
> index 2393e6d16ffd..88ba003979e6 100644
> --- a/drivers/gpu/drm/mxsfb/mxsfb_drv.c
> +++ b/drivers/gpu/drm/mxsfb/mxsfb_drv.c
> @@ -417,7 +417,7 @@ static int mxsfb_probe(struct platform_device *pdev)
> Âerr_unload:
> > Â mxsfb_unload(drm);
> Âerr_free:
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â
> > Â return ret;
> Â}
> @@ -428,7 +428,7 @@ static int mxsfb_remove(struct platform_device *pdev)
> Â
> > Â drm_dev_unregister(drm);
> > Â mxsfb_unload(drm);
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â
> > Â return 0;
> Â}
> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_drv.c b/drivers/gpu/drm/rcar-du/rcar_du_drv.c
> index 084f58df4a8c..c7fe2433ab9e 100644
> --- a/drivers/gpu/drm/rcar-du/rcar_du_drv.c
> +++ b/drivers/gpu/drm/rcar-du/rcar_du_drv.c
> @@ -454,7 +454,7 @@ static int rcar_du_remove(struct platform_device *pdev)
> > Â drm_kms_helper_poll_fini(ddev);
> > Â drm_mode_config_cleanup(ddev);
> Â
> > - drm_dev_unref(ddev);
> > + drm_dev_put(ddev);
> Â
> > Â return 0;
> Â}
> diff --git a/drivers/gpu/drm/shmobile/shmob_drm_drv.c b/drivers/gpu/drm/shmobile/shmob_drm_drv.c
> index 6ececad6f845..8554102a6ead 100644
> --- a/drivers/gpu/drm/shmobile/shmob_drm_drv.c
> +++ b/drivers/gpu/drm/shmobile/shmob_drm_drv.c
> @@ -194,7 +194,7 @@ static int shmob_drm_remove(struct platform_device *pdev)
> > Â drm_kms_helper_poll_fini(ddev);
> > Â drm_mode_config_cleanup(ddev);
> > Â drm_irq_uninstall(ddev);
> > - drm_dev_unref(ddev);
> > + drm_dev_put(ddev);
> Â
> > Â return 0;
> Â}
> @@ -290,7 +290,7 @@ static int shmob_drm_probe(struct platform_device *pdev)
> > Â drm_kms_helper_poll_fini(ddev);
> > Â drm_mode_config_cleanup(ddev);
> Âerr_free_drm_dev:
> > - drm_dev_unref(ddev);
> > + drm_dev_put(ddev);
> Â
> > Â return ret;
> Â}
> diff --git a/drivers/gpu/drm/tve200/tve200_drv.c b/drivers/gpu/drm/tve200/tve200_drv.c
> index 72efcecb44f7..28e2d03c0ccf 100644
> --- a/drivers/gpu/drm/tve200/tve200_drv.c
> +++ b/drivers/gpu/drm/tve200/tve200_drv.c
> @@ -249,7 +249,7 @@ static int tve200_probe(struct platform_device *pdev)
> Âclk_disable:
> > Â clk_disable_unprepare(priv->pclk);
> Âdev_unref:
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> > Â return ret;
> Â}
> Â
> @@ -263,7 +263,7 @@ static int tve200_remove(struct platform_device *pdev)
> > Â drm_panel_bridge_remove(priv->bridge);
> > Â drm_mode_config_cleanup(drm);
> > Â clk_disable_unprepare(priv->pclk);
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â
> > Â return 0;
> Â}
> diff --git a/drivers/gpu/drm/zte/zx_drm_drv.c b/drivers/gpu/drm/zte/zx_drm_drv.c
> index 11ef17c2d1c1..5b6f1eda52e0 100644
> --- a/drivers/gpu/drm/zte/zx_drm_drv.c
> +++ b/drivers/gpu/drm/zte/zx_drm_drv.c
> @@ -114,7 +114,7 @@ static int zx_drm_bind(struct device *dev)
> > Â component_unbind_all(dev, drm);
> Âout_unregister:
> > Â dev_set_drvdata(dev, NULL);
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> > Â return ret;
> Â}
> Â
> @@ -127,7 +127,7 @@ static void zx_drm_unbind(struct device *dev)
> > Â drm_mode_config_cleanup(drm);
> > Â component_unbind_all(dev, drm);
> > Â dev_set_drvdata(dev, NULL);
> > - drm_dev_unref(drm);
> > + drm_dev_put(drm);
> Â}
> Â
> Âstatic const struct component_master_ops zx_drm_master_ops = {