diff options
author | Julia Lawall <Julia.Lawall@lip6.fr> | 2014-11-23 08:11:15 -0500 |
---|---|---|
committer | Inki Dae <inki.dae@samsung.com> | 2014-11-24 09:52:04 -0500 |
commit | be19d9336995241f5c98d0abebff440fef03455e (patch) | |
tree | b8897bfb1e90077b7d81566a2c7641f6a99c810a | |
parent | 4846e452084945891a770809f94b23f33eebcd8c (diff) |
drm/exynos/ipp: fix error return code
Propagate the returned error code on failure.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
identifier ret; expression e1,e2;
@@
(
if (\(ret < 0\|ret != 0\))
{ ... return ret; }
|
ret = 0
)
... when != ret = e1
when != &ret
*if(...)
{
... when != ret = e2
when forall
return ret;
}
// </smpl>
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_ipp.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_ipp.c b/drivers/gpu/drm/exynos/exynos_drm_ipp.c index 00d74b18f7cb..d5ad17dfc24d 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_ipp.c +++ b/drivers/gpu/drm/exynos/exynos_drm_ipp.c | |||
@@ -426,18 +426,21 @@ int exynos_drm_ipp_set_property(struct drm_device *drm_dev, void *data, | |||
426 | c_node->start_work = ipp_create_cmd_work(); | 426 | c_node->start_work = ipp_create_cmd_work(); |
427 | if (IS_ERR(c_node->start_work)) { | 427 | if (IS_ERR(c_node->start_work)) { |
428 | DRM_ERROR("failed to create start work.\n"); | 428 | DRM_ERROR("failed to create start work.\n"); |
429 | ret = PTR_ERR(c_node->start_work); | ||
429 | goto err_remove_id; | 430 | goto err_remove_id; |
430 | } | 431 | } |
431 | 432 | ||
432 | c_node->stop_work = ipp_create_cmd_work(); | 433 | c_node->stop_work = ipp_create_cmd_work(); |
433 | if (IS_ERR(c_node->stop_work)) { | 434 | if (IS_ERR(c_node->stop_work)) { |
434 | DRM_ERROR("failed to create stop work.\n"); | 435 | DRM_ERROR("failed to create stop work.\n"); |
436 | ret = PTR_ERR(c_node->stop_work); | ||
435 | goto err_free_start; | 437 | goto err_free_start; |
436 | } | 438 | } |
437 | 439 | ||
438 | c_node->event_work = ipp_create_event_work(); | 440 | c_node->event_work = ipp_create_event_work(); |
439 | if (IS_ERR(c_node->event_work)) { | 441 | if (IS_ERR(c_node->event_work)) { |
440 | DRM_ERROR("failed to create event work.\n"); | 442 | DRM_ERROR("failed to create event work.\n"); |
443 | ret = PTR_ERR(c_node->event_work); | ||
441 | goto err_free_stop; | 444 | goto err_free_stop; |
442 | } | 445 | } |
443 | 446 | ||