mirror of
https://github.com/torvalds/linux
synced 2024-11-05 18:23:50 +00:00
drm/exynos: replace request_threaded_irq with devm function
devm_request_threaded_irq is used instead of request_threaded_irq and free_irq is removed. Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
This commit is contained in:
parent
7a1b00e072
commit
dcb9a7c74a
4 changed files with 8 additions and 26 deletions
|
@ -1845,7 +1845,7 @@ static int fimc_probe(struct platform_device *pdev)
|
|||
}
|
||||
|
||||
ctx->irq = res->start;
|
||||
ret = request_threaded_irq(ctx->irq, NULL, fimc_irq_handler,
|
||||
ret = devm_request_threaded_irq(dev, ctx->irq, NULL, fimc_irq_handler,
|
||||
IRQF_ONESHOT, "drm_fimc", ctx);
|
||||
if (ret < 0) {
|
||||
dev_err(dev, "failed to request irq.\n");
|
||||
|
@ -1854,7 +1854,7 @@ static int fimc_probe(struct platform_device *pdev)
|
|||
|
||||
ret = fimc_setup_clocks(ctx);
|
||||
if (ret < 0)
|
||||
goto err_free_irq;
|
||||
return ret;
|
||||
|
||||
ippdrv = &ctx->ippdrv;
|
||||
ippdrv->ops[EXYNOS_DRM_OPS_SRC] = &fimc_src_ops;
|
||||
|
@ -1892,8 +1892,6 @@ static int fimc_probe(struct platform_device *pdev)
|
|||
pm_runtime_disable(dev);
|
||||
err_put_clk:
|
||||
fimc_put_clocks(ctx);
|
||||
err_free_irq:
|
||||
free_irq(ctx->irq, ctx);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
@ -1911,8 +1909,6 @@ static int fimc_remove(struct platform_device *pdev)
|
|||
pm_runtime_set_suspended(dev);
|
||||
pm_runtime_disable(dev);
|
||||
|
||||
free_irq(ctx->irq, ctx);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -1704,7 +1704,7 @@ static int gsc_probe(struct platform_device *pdev)
|
|||
}
|
||||
|
||||
ctx->irq = res->start;
|
||||
ret = request_threaded_irq(ctx->irq, NULL, gsc_irq_handler,
|
||||
ret = devm_request_threaded_irq(dev, ctx->irq, NULL, gsc_irq_handler,
|
||||
IRQF_ONESHOT, "drm_gsc", ctx);
|
||||
if (ret < 0) {
|
||||
dev_err(dev, "failed to request irq.\n");
|
||||
|
@ -1725,7 +1725,7 @@ static int gsc_probe(struct platform_device *pdev)
|
|||
ret = gsc_init_prop_list(ippdrv);
|
||||
if (ret < 0) {
|
||||
dev_err(dev, "failed to init property list.\n");
|
||||
goto err_get_irq;
|
||||
return ret;
|
||||
}
|
||||
|
||||
DRM_DEBUG_KMS("%s:id[%d]ippdrv[0x%x]\n", __func__, ctx->id,
|
||||
|
@ -1749,8 +1749,6 @@ static int gsc_probe(struct platform_device *pdev)
|
|||
|
||||
err_ippdrv_register:
|
||||
pm_runtime_disable(dev);
|
||||
err_get_irq:
|
||||
free_irq(ctx->irq, ctx);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -1766,8 +1764,6 @@ static int gsc_remove(struct platform_device *pdev)
|
|||
pm_runtime_set_suspended(dev);
|
||||
pm_runtime_disable(dev);
|
||||
|
||||
free_irq(ctx->irq, ctx);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -666,8 +666,8 @@ static int rotator_probe(struct platform_device *pdev)
|
|||
return rot->irq;
|
||||
}
|
||||
|
||||
ret = request_threaded_irq(rot->irq, NULL, rotator_irq_handler,
|
||||
IRQF_ONESHOT, "drm_rotator", rot);
|
||||
ret = devm_request_threaded_irq(dev, rot->irq, NULL,
|
||||
rotator_irq_handler, IRQF_ONESHOT, "drm_rotator", rot);
|
||||
if (ret < 0) {
|
||||
dev_err(dev, "failed to request irq\n");
|
||||
return ret;
|
||||
|
@ -676,8 +676,7 @@ static int rotator_probe(struct platform_device *pdev)
|
|||
rot->clock = devm_clk_get(dev, "rotator");
|
||||
if (IS_ERR(rot->clock)) {
|
||||
dev_err(dev, "failed to get clock\n");
|
||||
ret = PTR_ERR(rot->clock);
|
||||
goto err_clk_get;
|
||||
return PTR_ERR(rot->clock);
|
||||
}
|
||||
|
||||
pm_runtime_enable(dev);
|
||||
|
@ -710,8 +709,6 @@ static int rotator_probe(struct platform_device *pdev)
|
|||
|
||||
err_ippdrv_register:
|
||||
pm_runtime_disable(dev);
|
||||
err_clk_get:
|
||||
free_irq(rot->irq, rot);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -725,8 +722,6 @@ static int rotator_remove(struct platform_device *pdev)
|
|||
|
||||
pm_runtime_disable(dev);
|
||||
|
||||
free_irq(rot->irq, rot);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -2046,7 +2046,7 @@ static int hdmi_probe(struct platform_device *pdev)
|
|||
|
||||
hdata->hpd = gpio_get_value(hdata->hpd_gpio);
|
||||
|
||||
ret = request_threaded_irq(hdata->irq, NULL,
|
||||
ret = devm_request_threaded_irq(dev, hdata->irq, NULL,
|
||||
hdmi_irq_thread, IRQF_TRIGGER_RISING |
|
||||
IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
|
||||
"hdmi", drm_hdmi_ctx);
|
||||
|
@ -2075,16 +2075,11 @@ static int hdmi_probe(struct platform_device *pdev)
|
|||
static int hdmi_remove(struct platform_device *pdev)
|
||||
{
|
||||
struct device *dev = &pdev->dev;
|
||||
struct exynos_drm_hdmi_context *ctx = platform_get_drvdata(pdev);
|
||||
struct hdmi_context *hdata = ctx->ctx;
|
||||
|
||||
DRM_DEBUG_KMS("[%d] %s\n", __LINE__, __func__);
|
||||
|
||||
pm_runtime_disable(dev);
|
||||
|
||||
free_irq(hdata->irq, ctx);
|
||||
|
||||
|
||||
/* hdmiphy i2c driver */
|
||||
i2c_del_driver(&hdmiphy_driver);
|
||||
/* DDC i2c driver */
|
||||
|
|
Loading…
Reference in a new issue