aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi/linux/media.h
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>2015-12-11 16:07:57 -0200
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2016-01-11 12:19:07 -0200
commitb3b7a9f138b7539c25e036d398616f6737b08ff7 (patch)
tree710cdd2e8b21ef4471baf424c0ef6261d30f26df /include/uapi/linux/media.h
parent[media] media-device.h: Let clearer that entity function must be initialized (diff)
downloadlinux-dev-b3b7a9f138b7539c25e036d398616f6737b08ff7.tar.xz
linux-dev-b3b7a9f138b7539c25e036d398616f6737b08ff7.zip
[media] media-device: Use u64 ints for pointers
By using u64 integers and pointers, we can get rid of compat32 logic. So, let's do it! Suggested-by: Arnd Bergmann <arnd@arndb.de> Suggested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'include/uapi/linux/media.h')
-rw-r--r--include/uapi/linux/media.h32
1 files changed, 17 insertions, 15 deletions
diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h
index 8d8e1a3e6e1a..86f9753e5c03 100644
--- a/include/uapi/linux/media.h
+++ b/include/uapi/linux/media.h
@@ -23,6 +23,9 @@
#ifndef __LINUX_MEDIA_H
#define __LINUX_MEDIA_H
+#ifndef __KERNEL__
+#include <stdint.h>
+#endif
#include <linux/ioctl.h>
#include <linux/types.h>
#include <linux/version.h>
@@ -320,27 +323,26 @@ struct media_v2_link {
};
struct media_v2_topology {
- __u32 topology_version;
+ __u64 topology_version;
- __u32 num_entities;
- struct media_v2_entity *entities;
+ __u64 num_entities;
+ __u64 ptr_entities;
- __u32 num_interfaces;
- struct media_v2_interface *interfaces;
+ __u64 num_interfaces;
+ __u64 ptr_interfaces;
- __u32 num_pads;
- struct media_v2_pad *pads;
+ __u64 num_pads;
+ __u64 ptr_pads;
- __u32 num_links;
- struct media_v2_link *links;
-
- struct {
- __u32 reserved_num;
- void *reserved_ptr;
- } reserved_types[16];
- __u32 reserved[8];
+ __u64 num_links;
+ __u64 ptr_links;
};
+static inline void __user *media_get_uptr(__u64 arg)
+{
+ return (void __user *)(uintptr_t)arg;
+}
+
/* ioctls */
#define MEDIA_IOC_DEVICE_INFO _IOWR('|', 0x00, struct media_device_info)