summaryrefslogtreecommitdiff
path: root/include/media/media-device.h
diff options
context:
space:
mode:
authorSakari Ailus <sakari.ailus@linux.intel.com>2022-01-22 11:31:37 +0000
committerMauro Carvalho Chehab <mchehab@kernel.org>2022-04-24 08:05:53 +0100
commitcef699749f3789add5ecaf0a2f73a659cae1c7ae (patch)
treecf4c68f42642659a7ab906af3202440acd555ff0 /include/media/media-device.h
parent78a171e58717685ea0eb082a24bc75bd9e20518f (diff)
media: mc: Set bus_info in media_device_init()
Set bus_info field based on struct device in media_device_init() and remove corresponding code from drivers. Also update media_device_init() documentation: the dev field must be now initialised before calling it. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'include/media/media-device.h')
-rw-r--r--include/media/media-device.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/media/media-device.h b/include/media/media-device.h
index f0baee6771ef..a10b30507524 100644
--- a/include/media/media-device.h
+++ b/include/media/media-device.h
@@ -225,6 +225,9 @@ static inline __must_check int media_entity_enum_init(
*
* - dev must point to the parent device
* - model must be filled with the device model name
+ *
+ * The bus_info field is set by media_device_init() for PCI and platform devices
+ * if the field begins with '\0'.
*/
void media_device_init(struct media_device *mdev);
@@ -249,9 +252,6 @@ void media_device_cleanup(struct media_device *mdev);
* The caller is responsible for initializing the &media_device structure
* before registration. The following fields of &media_device must be set:
*
- * - &media_device.dev must point to the parent device (usually a &pci_dev,
- * &usb_interface or &platform_device instance).
- *
* - &media_device.model must be filled with the device model name as a
* NUL-terminated UTF-8 string. The device/model revision must not be
* stored in this field.