#include <linux/kref.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <linux/usb.h>
#include <media/media-device.h>
#include <media/media-dev-allocator.h>
static LIST_HEAD(media_device_list);
static DEFINE_MUTEX(media_device_lock);
struct media_device_instance { … };
static inline struct media_device_instance *
to_media_device_instance(struct media_device *mdev)
{ … }
static void media_device_instance_release(struct kref *kref)
{ … }
static struct media_device *__media_device_get(struct device *dev,
const char *module_name,
struct module *owner)
{ … }
struct media_device *media_device_usb_allocate(struct usb_device *udev,
const char *module_name,
struct module *owner)
{ … }
EXPORT_SYMBOL_GPL(…);
void media_device_delete(struct media_device *mdev, const char *module_name,
struct module *owner)
{ … }
EXPORT_SYMBOL_GPL(…);