OSDN Git Service

media: mc: delete redundant code in __media_device_unregister_entity
authorHangyu Hua <hbh25y@gmail.com>
Thu, 24 Mar 2022 10:27:52 +0000 (10:27 +0000)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Sun, 24 Apr 2022 07:14:19 +0000 (08:14 +0100)
media_gobj_destroy has already set graph_obj.mdev to NULL. There is no
need to set it again.

[Sakari Ailus: Remove extra newline, rewrap commit msg]

Signed-off-by: Hangyu Hua <hbh25y@gmail.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/media/mc/mc-device.c

index 824d89b..b8176a3 100644 (file)
@@ -604,8 +604,6 @@ static void __media_device_unregister_entity(struct media_entity *entity)
        media_gobj_destroy(&entity->graph_obj);
 
        /* invoke entity_notify callbacks to handle entity removal?? */
-
-       entity->graph_obj.mdev = NULL;
 }
 
 int __must_check media_device_register_entity(struct media_device *mdev,