OSDN Git Service

media: rcar-vin: Fix lockdep warning at stream on
authorNiklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Wed, 13 Feb 2019 22:07:54 +0000 (17:07 -0500)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Tue, 19 Mar 2019 17:37:23 +0000 (13:37 -0400)
commitd950fd992ef89f39ff8908f389ed6cbd2fdc0513
treefb02acd1b1a2c7d5063a493918ebd6a636c9587c
parent2b177f2849d23061508bb13594cc1bff1ccb46c9
media: rcar-vin: Fix lockdep warning at stream on

Changes to v4l2-fwnode in commit [1] triggered a lockdep warning in
rcar-vin. The first attempt to solve this warning in the rcar-vin driver
was incomplete and only pushed the warning to happen at stream on time
instead of at probe time.

This change reverts the incomplete fix and properly fixes the warning by
removing the need to hold the rcar-vin specific group lock when calling
v4l2_async_notifier_parse_fwnode_endpoints_by_port(). And instead takes
it in the callback where it's really needed.

[1] commit eae2aed1eab9bf08 ("media: v4l2-fwnode: Switch to
v4l2_async_notifier_add_subdev")

Fixes: 6458afc8c49148f0 ("media: rcar-vin: remove unneeded locking in async callbacks")

Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/platform/rcar-vin/rcar-core.c