linux/drivers/media/platform/rcar-vin
Laurent Pinchart 2cac7cbfb4 media: rcar-csi2: Allocate v4l2_async_subdev dynamically
v4l2_async_notifier_add_subdev() requires the asd to be allocated
dynamically, but the rcar-csi2 driver embeds it in the rcar_csi2
structure. This causes memory corruption when the notifier is destroyed
at remove time with v4l2_async_notifier_cleanup().

Fix this issue by registering the asd with
v4l2_async_notifier_add_fwnode_subdev(), which allocates it dynamically
internally.

Fixes: 769afd212b ("media: rcar-csi2: add Renesas R-Car MIPI CSI-2 receiver driver")
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
2020-09-10 14:27:26 +02:00
..
Kconfig media: Kconfig files: use select for V4L2 subdevs and MC 2020-04-14 10:29:05 +02:00
Makefile media: rcar-vin: convert to SPDX identifiers 2018-08-03 16:03:45 -04:00
rcar-core.c media: rcar-vin: Register media device when all sub-devices bound 2020-08-29 08:16:58 +02:00
rcar-csi2.c media: rcar-csi2: Allocate v4l2_async_subdev dynamically 2020-09-10 14:27:26 +02:00
rcar-dma.c media: rcar-vin: Add support for MEDIA_BUS_FMT_SRGGB8_1X8 format 2020-07-04 12:29:07 +02:00
rcar-v4l2.c media: rcar-vin: Add support for MEDIA_BUS_FMT_SRGGB8_1X8 format 2020-07-04 12:29:07 +02:00
rcar-vin.h media: rcar-vin: Add support for V4L2_FIELD_SEQ_{TB,BT} 2020-02-24 16:18:45 +01:00