]> git.baikalelectronics.ru Git - kernel.git/commit
[media] v4l: vsp1: Cleanup video nodes at removal time
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Wed, 28 May 2014 15:49:13 +0000 (12:49 -0300)
committerMauro Carvalho Chehab <m.chehab@samsung.com>
Thu, 17 Jul 2014 15:44:52 +0000 (12:44 -0300)
commit424ea4cd6554ea471ed64d87543f70bf92bdeaae
tree29bd2282d712ca560ed01dd6202f7e9b4caebf3c
parent5114275a54217e07f129b5d33d85f6bfb8b07e82
[media] v4l: vsp1: Cleanup video nodes at removal time

Video nodes created and initialized in the RPF and WPF init code paths
are never unregistered, and the related resources (videobuf alloc
context and media entity) never released.

Fix this by storing a pointer to the vsp1_video object in vsp1_entity
and calling vsp1_video_cleanup() from vsp1_entity_destroy(). This also
allows simplifying the init error code paths.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/platform/vsp1/vsp1_entity.c
drivers/media/platform/vsp1/vsp1_entity.h
drivers/media/platform/vsp1/vsp1_rpf.c
drivers/media/platform/vsp1/vsp1_wpf.c