diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2010-08-18 10:41:22 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-03-22 03:53:13 -0400 |
commit | 140d88165c25137e871f9559e67986ed89251105 (patch) | |
tree | c02891d72b0b85c03d4f493da4c5f37923c836c6 /include/linux/media.h | |
parent | 503c3d829eaf48837dd5bff5d97ad66369bb955a (diff) |
[media] media: Media device information query
Create the following ioctl and implement it at the media device level to
query device information.
- MEDIA_IOC_DEVICE_INFO: Query media device information
The ioctl and its data structure are defined in the new kernel header
linux/media.h available to userspace applications.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'include/linux/media.h')
-rw-r--r-- | include/linux/media.h | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/include/linux/media.h b/include/linux/media.h new file mode 100644 index 000000000000..64090db3c1fc --- /dev/null +++ b/include/linux/media.h | |||
@@ -0,0 +1,45 @@ | |||
1 | /* | ||
2 | * Multimedia device API | ||
3 | * | ||
4 | * Copyright (C) 2010 Nokia Corporation | ||
5 | * | ||
6 | * Contacts: Laurent Pinchart <laurent.pinchart@ideasonboard.com> | ||
7 | * Sakari Ailus <sakari.ailus@iki.fi> | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License version 2 as | ||
11 | * published by the Free Software Foundation. | ||
12 | * | ||
13 | * This program is distributed in the hope that it will be useful, | ||
14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | * GNU General Public License for more details. | ||
17 | * | ||
18 | * You should have received a copy of the GNU General Public License | ||
19 | * along with this program; if not, write to the Free Software | ||
20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
21 | */ | ||
22 | |||
23 | #ifndef __LINUX_MEDIA_H | ||
24 | #define __LINUX_MEDIA_H | ||
25 | |||
26 | #include <linux/ioctl.h> | ||
27 | #include <linux/types.h> | ||
28 | #include <linux/version.h> | ||
29 | |||
30 | #define MEDIA_API_VERSION KERNEL_VERSION(0, 1, 0) | ||
31 | |||
32 | struct media_device_info { | ||
33 | char driver[16]; | ||
34 | char model[32]; | ||
35 | char serial[40]; | ||
36 | char bus_info[32]; | ||
37 | __u32 media_version; | ||
38 | __u32 hw_revision; | ||
39 | __u32 driver_version; | ||
40 | __u32 reserved[31]; | ||
41 | }; | ||
42 | |||
43 | #define MEDIA_IOC_DEVICE_INFO _IOWR('M', 1, struct media_device_info) | ||
44 | |||
45 | #endif /* __LINUX_MEDIA_H */ | ||