Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bd0f2e6d authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Mauro Carvalho Chehab
Browse files

[media] omap3isp: ccdc: Fix crash in HS/VS interrupt handler



The HS/VS interrupt handler needs to access the pipeline object. It
erronously tries to get it from the CCDC output video node, which isn't
necessarily included in the pipeline. This leads to a NULL pointer
dereference.

Fix the bug by getting the pipeline object from the CCDC subdev entity.

Reported-by: default avatarGary Thomas <gary@mlbassoc.com>
Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: default avatarSakari Ailus <sakari.ailus@iki.fi>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent ec0cae7a
Loading
Loading
Loading
Loading
+1 −2
Original line number Original line Diff line number Diff line
@@ -1406,8 +1406,7 @@ static int __ccdc_handle_stopping(struct isp_ccdc_device *ccdc, u32 event)


static void ccdc_hs_vs_isr(struct isp_ccdc_device *ccdc)
static void ccdc_hs_vs_isr(struct isp_ccdc_device *ccdc)
{
{
	struct isp_pipeline *pipe =
	struct isp_pipeline *pipe = to_isp_pipeline(&ccdc->subdev.entity);
		to_isp_pipeline(&ccdc->video_out.video.entity);
	struct video_device *vdev = &ccdc->subdev.devnode;
	struct video_device *vdev = &ccdc->subdev.devnode;
	struct v4l2_event event;
	struct v4l2_event event;