From: Niklas Söderlund Date: Fri, 30 Nov 2018 02:11:07 +0000 (-0500) Subject: media: v4l2: async: remove locking when initializing async notifier X-Git-Tag: v5.15~7385^2~51 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=da2c94c8f9739e4099ea3cfefc208fc721b22a9c;p=platform%2Fkernel%2Flinux-starfive.git media: v4l2: async: remove locking when initializing async notifier There is no need to hold the list_lock when initializing the local asd_list of a notifier. Remove the lock handling to simplify the code and remove a potential LOCKDEP warning. Signed-off-by: Niklas Söderlund Reported-by: Jacopo Mondi Signed-off-by: Sakari Ailus Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/v4l2-core/v4l2-async.c b/drivers/media/v4l2-core/v4l2-async.c index a6d9137..15b0c44a 100644 --- a/drivers/media/v4l2-core/v4l2-async.c +++ b/drivers/media/v4l2-core/v4l2-async.c @@ -424,11 +424,7 @@ static int v4l2_async_notifier_asd_valid(struct v4l2_async_notifier *notifier, void v4l2_async_notifier_init(struct v4l2_async_notifier *notifier) { - mutex_lock(&list_lock); - INIT_LIST_HEAD(¬ifier->asd_list); - - mutex_unlock(&list_lock); } EXPORT_SYMBOL(v4l2_async_notifier_init);