You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by pk...@apache.org on 2022/11/05 05:51:59 UTC
[incubator-nuttx] branch master updated: video: Move _VIDIOCBASE and _VIDIOC to include/nuttx/fs/ioctl.h
This is an automated email from the ASF dual-hosted git repository.
pkarashchenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
The following commit(s) were added to refs/heads/master by this push:
new e292200f61 video: Move _VIDIOCBASE and _VIDIOC to include/nuttx/fs/ioctl.h
e292200f61 is described below
commit e292200f615ab5de17b0cb8593c460a5c06d2f0a
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Thu Nov 3 09:45:30 2022 +0800
video: Move _VIDIOCBASE and _VIDIOC to include/nuttx/fs/ioctl.h
to align with other drivers
Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
---
include/nuttx/fs/ioctl.h | 6 ++++++
include/nuttx/video/video.h | 8 ++------
2 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/include/nuttx/fs/ioctl.h b/include/nuttx/fs/ioctl.h
index ef654c47c9..ffe67bddfa 100644
--- a/include/nuttx/fs/ioctl.h
+++ b/include/nuttx/fs/ioctl.h
@@ -92,6 +92,7 @@
#define _BLUETOOTHBASE (0x3400) /* Bluetooth ioctl commands */
#define _PKTRADIOBASE (0x3500) /* Packet radio ioctl commands */
#define _LTEBASE (0x3600) /* LTE device ioctl commands */
+#define _VIDIOCBASE (0x3700) /* Video device ioctl commands */
#define _WLIOCBASE (0x8b00) /* Wireless modules ioctl network commands */
/* boardctl() commands share the same number space */
@@ -599,6 +600,11 @@
#define _LTEIOCVALID(c) (_IOC_TYPE(c)==_LTEBASE)
#define _LTEIOC(nr) _IOC(_LTEBASE,nr)
+/* Video device ioctl definitions *******************************************/
+
+#define _VIDIOCVALID(c) (_IOC_TYPE(c)==_VIDIOCBASE)
+#define _VIDIOC(nr) _IOC(_VIDIOCBASE,nr)
+
/* Wireless driver network ioctl definitions ********************************/
/* (see nuttx/include/wireless/wireless.h */
diff --git a/include/nuttx/video/video.h b/include/nuttx/video/video.h
index b7703e7749..dfe843d7a0 100644
--- a/include/nuttx/video/video.h
+++ b/include/nuttx/video/video.h
@@ -26,8 +26,8 @@
****************************************************************************/
#include <stdint.h>
-#include <sys/ioctl.h>
-#include "video_controls.h"
+#include <nuttx/fs/ioctl.h>
+#include <nuttx/video/video_controls.h>
#ifdef __cplusplus
extern "C"
@@ -38,10 +38,6 @@ extern "C"
* Pre-processor Definitions
****************************************************************************/
-#define _VIDIOCBASE (0x1000)
-
-#define _VIDIOC(nr) _IOC(_VIDIOCBASE,nr)
-
/* Enumerate the formats supported by device */
#define VIDIOC_ENUM_FMT _VIDIOC(0x0001)