Hi All, This small patch set adds a function for removing all links at a media entity. I found out such a function is needed when media entites that belong to a single media device have drivers in different kernel modules. This means virtually all camera drivers, since sensors are separate modules from the host interface drivers. More details can be found at each patch's description. The links removal from a media entity is rather strightforward, but when and where links should be created/removed is not immediately clear to me. I assumed that links should normally be created/removed when an entity is registered to its media device, with the graph mutex held. I'm open to opinions whether it's good or not and possibly suggestions on how those issues could be handled differently. The changes since original version are listed in patch 1/2, in patch 2/2 only the commit description has changed slightly. Thanks, Sylwester Sylwester Nawrocki (2): media: Add a function removing all links of a media entity V4L: Remove all links of a media entity when unregistering subdev drivers/media/media-entity.c | 48 +++++++++++++++++++++++++++++++++ drivers/media/v4l2-core/v4l2-device.c | 4 ++- include/media/media-entity.h | 3 ++ 3 files changed, 54 insertions(+), 1 deletions(-) -- 1.7.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html