From: Sakari Ailus Date: Mon, 22 Feb 2016 20:47:04 +0000 (-0300) Subject: [media] media: Move media_get_uptr() macro out of the media.h user space header X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=0629e991a25a9b56a70f9f0c327aad8ae1471dbf;p=openwrt%2Fstaging%2Fblogic.git [media] media: Move media_get_uptr() macro out of the media.h user space header The media_get_uptr() macro is mostly useful only for the IOCTL handling code in media-device.c so move it there. Signed-off-by: Sakari Ailus Acked-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/media-device.c b/drivers/media/media-device.c index a2353ecab687..c89dfef0c4c5 100644 --- a/drivers/media/media-device.c +++ b/drivers/media/media-device.c @@ -40,6 +40,11 @@ * Userspace API */ +static inline void __user *media_get_uptr(__u64 arg) +{ + return (void __user *)(uintptr_t)arg; +} + static int media_device_open(struct file *filp) { return 0; diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h index 79960aefd356..71fb8e3dce06 100644 --- a/include/uapi/linux/media.h +++ b/include/uapi/linux/media.h @@ -375,11 +375,6 @@ struct media_v2_topology { __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)