提交 36499e52 编写于 作者: S Sakari Ailus 提交者: Mauro Carvalho Chehab

V4L/DVB (9322): v4l2-int-if: Export more interfaces to modules

Export v4l2_int_device_try_attach_all. This allows initiating the
initialisation of int if device after the drivers have been registered.

Also allow drivers to call ioctls if v4l2-int-if was compiled as
module.
Signed-off-by: NSakari Ailus <sakari.ailus@nokia.com>
Signed-off-by: NHans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 84389910
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
static DEFINE_MUTEX(mutex); static DEFINE_MUTEX(mutex);
static LIST_HEAD(int_list); static LIST_HEAD(int_list);
static void v4l2_int_device_try_attach_all(void) void v4l2_int_device_try_attach_all(void)
{ {
struct v4l2_int_device *m, *s; struct v4l2_int_device *m, *s;
...@@ -66,6 +66,7 @@ static void v4l2_int_device_try_attach_all(void) ...@@ -66,6 +66,7 @@ static void v4l2_int_device_try_attach_all(void)
} }
} }
} }
EXPORT_SYMBOL_GPL(v4l2_int_device_try_attach_all);
static int ioctl_sort_cmp(const void *a, const void *b) static int ioctl_sort_cmp(const void *a, const void *b)
{ {
...@@ -144,6 +145,7 @@ int v4l2_int_ioctl_0(struct v4l2_int_device *d, int cmd) ...@@ -144,6 +145,7 @@ int v4l2_int_ioctl_0(struct v4l2_int_device *d, int cmd)
find_ioctl(d->u.slave, cmd, find_ioctl(d->u.slave, cmd,
(v4l2_int_ioctl_func *)no_such_ioctl_0))(d); (v4l2_int_ioctl_func *)no_such_ioctl_0))(d);
} }
EXPORT_SYMBOL_GPL(v4l2_int_ioctl_0);
static int no_such_ioctl_1(struct v4l2_int_device *d, void *arg) static int no_such_ioctl_1(struct v4l2_int_device *d, void *arg)
{ {
...@@ -156,5 +158,6 @@ int v4l2_int_ioctl_1(struct v4l2_int_device *d, int cmd, void *arg) ...@@ -156,5 +158,6 @@ int v4l2_int_ioctl_1(struct v4l2_int_device *d, int cmd, void *arg)
find_ioctl(d->u.slave, cmd, find_ioctl(d->u.slave, cmd,
(v4l2_int_ioctl_func *)no_such_ioctl_1))(d, arg); (v4l2_int_ioctl_func *)no_such_ioctl_1))(d, arg);
} }
EXPORT_SYMBOL_GPL(v4l2_int_ioctl_1);
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
...@@ -84,6 +84,8 @@ struct v4l2_int_device { ...@@ -84,6 +84,8 @@ struct v4l2_int_device {
void *priv; void *priv;
}; };
void v4l2_int_device_try_attach_all(void);
int v4l2_int_device_register(struct v4l2_int_device *d); int v4l2_int_device_register(struct v4l2_int_device *d);
void v4l2_int_device_unregister(struct v4l2_int_device *d); void v4l2_int_device_unregister(struct v4l2_int_device *d);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册