linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Platform: Exynos4-is: Clean up file handle in open() error path.
@ 2016-12-01  4:40 Shailendra Verma
  0 siblings, 0 replies; only message in thread
From: Shailendra Verma @ 2016-12-01  4:40 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Kukjin Kim, Krzysztof Kozlowski,
	Javier Martinez Canillas, Kyungmin Park, Sylwester Nawrocki,
	linux-media, linux-arm-kernel, linux-samsung-soc, linux-kernel,
	Shailendra Verma, Shailendra Verma
  Cc: vidushi.koul

The File handle is not yet added in the vfd list.So no need to call 
v4l2_fh_del(&ctx->fh) if it fails to create control.

Signed-off-by: Shailendra Verma <shailendra.v@samsung.com>
---
 drivers/media/platform/exynos4-is/fimc-m2m.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/platform/exynos4-is/fimc-m2m.c b/drivers/media/platform/exynos4-is/fimc-m2m.c
index 6028e4f..d8724fe 100644
--- a/drivers/media/platform/exynos4-is/fimc-m2m.c
+++ b/drivers/media/platform/exynos4-is/fimc-m2m.c
@@ -663,8 +663,8 @@ static int fimc_m2m_open(struct file *file)
 	v4l2_m2m_ctx_release(ctx->fh.m2m_ctx);
 error_c:
 	fimc_ctrls_delete(ctx);
-error_fh:
 	v4l2_fh_del(&ctx->fh);
+error_fh:
 	v4l2_fh_exit(&ctx->fh);
 	kfree(ctx);
 unlock:
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2016-12-01  4:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-01  4:40 [PATCH] Platform: Exynos4-is: Clean up file handle in open() error path Shailendra Verma

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).