PERFORCE change 120421 for review
Hans Petter Selasky
hselasky at FreeBSD.org
Sat May 26 10:43:20 UTC 2007
http://perforce.freebsd.org/chv.cgi?CH=120421
Change 120421 by hselasky at hselasky_mini_itx on 2007/05/26 10:43:11
Remove unused code and formatting nits.
Affected files ...
.. //depot/projects/usb/src/sys/sys/videodev.h#2 edit
Differences ...
==== //depot/projects/usb/src/sys/sys/videodev.h#2 (text+ko) ====
@@ -191,8 +191,7 @@
/*
* D R I V E R C A P A B I L I T I E S
*/
-struct v4l2_capability
-{
+struct v4l2_capability {
uint8_t driver[16]; /* i.e. "bttv" */
uint8_t card[32]; /* i.e. "Hauppauge WinTV" */
uint8_t bus_info[32]; /* "PCI:" + pci_name(pci_dev) */
@@ -218,8 +217,7 @@
/*
* V I D E O I M A G E F O R M A T
*/
-struct v4l2_pix_format
-{
+struct v4l2_pix_format {
uint32_t width;
uint32_t height;
uint32_t pixelformat;
@@ -280,8 +278,7 @@
/*
* F O R M A T E N U M E R A T I O N
*/
-struct v4l2_fmtdesc
-{
+struct v4l2_fmtdesc {
uint32_t index; /* Format number */
enum v4l2_buf_type type; /* buffer type */
uint32_t flags;
@@ -303,14 +300,12 @@
V4L2_FRMSIZE_TYPE_STEPWISE = 3,
};
-struct v4l2_frmsize_discrete
-{
+struct v4l2_frmsize_discrete {
uint32_t width; /* Frame width [pixel] */
uint32_t height; /* Frame height [pixel] */
};
-struct v4l2_frmsize_stepwise
-{
+struct v4l2_frmsize_stepwise {
uint32_t min_width; /* Minimum frame width [pixel] */
uint32_t max_width; /* Maximum frame width [pixel] */
uint32_t step_width; /* Frame width step size [pixel] */
@@ -319,8 +314,7 @@
uint32_t step_height; /* Frame height step size [pixel] */
};
-struct v4l2_frmsizeenum
-{
+struct v4l2_frmsizeenum {
uint32_t index; /* Frame size number */
uint32_t pixel_format; /* Pixel format */
uint32_t type; /* Frame size type the device
@@ -338,22 +332,19 @@
/*
* F R A M E R A T E E N U M E R A T I O N
*/
-enum v4l2_frmivaltypes
-{
+enum v4l2_frmivaltypes {
V4L2_FRMIVAL_TYPE_DISCRETE = 1,
V4L2_FRMIVAL_TYPE_CONTINUOUS = 2,
V4L2_FRMIVAL_TYPE_STEPWISE = 3,
};
-struct v4l2_frmival_stepwise
-{
+struct v4l2_frmival_stepwise {
struct v4l2_fract min; /* Minimum frame interval [s] */
struct v4l2_fract max; /* Maximum frame interval [s] */
struct v4l2_fract step; /* Frame interval step size [s] */
};
-struct v4l2_frmivalenum
-{
+struct v4l2_frmivalenum {
uint32_t index; /* Frame format index */
uint32_t pixel_format; /* Pixel format */
uint32_t width; /* Frame width */
@@ -376,8 +367,7 @@
/*
* T I M E C O D E
*/
-struct v4l2_timecode
-{
+struct v4l2_timecode {
uint32_t type;
#define V4L2_TC_TYPE_24FPS 1
#define V4L2_TC_TYPE_25FPS 2
@@ -398,8 +388,7 @@
uint8_t userbits[4];
};
-struct v4l2_jpegcompression
-{
+struct v4l2_jpegcompression {
uint32_t jpeg_markers;
/* Which markers should go into the JPEG
* output. Unless you exactly know what
@@ -434,16 +423,14 @@
/*
* M E M O R Y - M A P P I N G B U F F E R S
*/
-struct v4l2_requestbuffers
-{
+struct v4l2_requestbuffers {
uint32_t count;
enum v4l2_buf_type type;
enum v4l2_memory memory;
uint32_t reserved[2];
};
-struct v4l2_buffer
-{
+struct v4l2_buffer {
uint32_t index;
enum v4l2_buf_type type;
uint32_t bytesused;
@@ -475,8 +462,7 @@
/*
* O V E R L A Y P R E V I E W
*/
-struct v4l2_framebuffer
-{
+struct v4l2_framebuffer {
uint32_t capability; /* read only */
#define V4L2_FBUF_CAP_EXTERNOVERLAY 0x0001
#define V4L2_FBUF_CAP_CHROMAKEY 0x0002
@@ -492,14 +478,12 @@
struct v4l2_pix_format fmt;
};
-struct v4l2_clip
-{
+struct v4l2_clip {
struct v4l2_rect c;
struct v4l2_clip __user *next;
};
-struct v4l2_window
-{
+struct v4l2_window {
struct v4l2_rect w;
enum v4l2_field field;
uint32_t chromakey;
@@ -511,8 +495,7 @@
/*
* C A P T U R E P A R A M E T E R S
*/
-struct v4l2_captureparm
-{
+struct v4l2_captureparm {
uint32_t capability; /* Supported modes */
uint32_t capturemode; /* Current mode */
#define V4L2_MODE_HIGHQUALITY 0x0001 /* High quality imaging mode */
@@ -523,8 +506,7 @@
uint32_t reserved[4];
};
-struct v4l2_outputparm
-{
+struct v4l2_outputparm {
uint32_t capability; /* Supported modes */
uint32_t outputmode; /* Current mode */
struct v4l2_fract timeperframe; /* Time per frame in seconds */
@@ -632,8 +614,7 @@
#define V4L2_STD_ALL (V4L2_STD_525_60 | \
V4L2_STD_625_50)
-struct v4l2_standard
-{
+struct v4l2_standard {
uint32_t index;
v4l2_std_id id;
uint8_t name[24];
@@ -645,8 +626,7 @@
/*
* V I D E O I N P U T S
*/
-struct v4l2_input
-{
+struct v4l2_input {
uint32_t index; /* Which input */
uint8_t name[32]; /* Label */
uint32_t type; /* Type of input */
@@ -679,8 +659,7 @@
/*
* V I D E O O U T P U T S
*/
-struct v4l2_output
-{
+struct v4l2_output {
uint32_t index; /* Which output */
uint8_t name[32]; /* Label */
uint32_t type; /* Type of output */
@@ -698,14 +677,12 @@
/*
* C O N T R O L S
*/
-struct v4l2_control
-{
+struct v4l2_control {
uint32_t id;
int32_t value;
};
-struct v4l2_ext_control
-{
+struct v4l2_ext_control {
uint32_t id;
uint32_t reserved2[2];
union {
@@ -715,8 +692,7 @@
} u;
} __packed;
-struct v4l2_ext_controls
-{
+struct v4l2_ext_controls {
uint32_t ctrl_class;
#define V4L2_CTRL_CLASS_USER 0x00980000 /* Old-style 'user' controls */
#define V4L2_CTRL_CLASS_MPEG 0x00990000 /* MPEG-compression controls */
@@ -730,8 +706,7 @@
};
/* Used in the VIDIOC_QUERYCTRL ioctl for querying controls */
-struct v4l2_queryctrl
-{
+struct v4l2_queryctrl {
uint32_t id;
enum v4l2_ctrl_type type;
uint8_t name[32]; /* Whatever */
@@ -744,8 +719,7 @@
};
/* Used in the VIDIOC_QUERYMENU ioctl for querying menu items */
-struct v4l2_querymenu
-{
+struct v4l2_querymenu {
uint32_t id;
uint32_t index;
uint8_t name[32]; /* Whatever */
@@ -995,8 +969,7 @@
/*
* T U N I N G
*/
-struct v4l2_tuner
-{
+struct v4l2_tuner {
uint32_t index;
uint8_t name[32];
enum v4l2_tuner_type type;
@@ -1010,8 +983,7 @@
uint32_t reserved[4];
};
-struct v4l2_modulator
-{
+struct v4l2_modulator {
uint32_t index;
uint8_t name[32];
uint32_t capability;
@@ -1044,8 +1016,7 @@
#define V4L2_TUNER_MODE_LANG1 0x0003
#define V4L2_TUNER_MODE_LANG1_LANG2 0x0004
-struct v4l2_frequency
-{
+struct v4l2_frequency {
uint32_t tuner;
enum v4l2_tuner_type type;
uint32_t frequency;
@@ -1055,8 +1026,7 @@
/*
* A U D I O
*/
-struct v4l2_audio
-{
+struct v4l2_audio {
uint32_t index;
uint8_t name[32];
uint32_t capability;
@@ -1071,8 +1041,7 @@
/* Flags for the 'mode' field */
#define V4L2_AUDMODE_AVL 0x00001
-struct v4l2_audioout
-{
+struct v4l2_audioout {
uint32_t index;
uint8_t name[32];
uint32_t capability;
@@ -1136,8 +1105,7 @@
*/
/* Raw VBI */
-struct v4l2_vbi_format
-{
+struct v4l2_vbi_format {
uint32_t sampling_rate; /* in 1 Hz */
uint32_t offset;
uint32_t samples_per_line;
@@ -1159,8 +1127,7 @@
* notice in the definitive implementation.
*/
-struct v4l2_sliced_vbi_format
-{
+struct v4l2_sliced_vbi_format {
uint16_t service_set;
/* service_lines[0][...] specifies lines 0-23 (1-23 used)
* of the first field
@@ -1189,8 +1156,7 @@
V4L2_SLICED_VPS | \
V4L2_SLICED_WSS_625)
-struct v4l2_sliced_vbi_cap
-{
+struct v4l2_sliced_vbi_cap {
uint16_t service_set;
/* service_lines[0][...] specifies lines 0-23 (1-23 used)
* of the first field
@@ -1204,8 +1170,7 @@
uint32_t reserved[3]; /* must be 0 */
};
-struct v4l2_sliced_vbi_data
-{
+struct v4l2_sliced_vbi_data {
uint32_t id;
uint32_t field; /* 0: first field, 1: second field */
uint32_t line; /* 1-23 */
@@ -1219,11 +1184,9 @@
/* Stream data format
*/
-struct v4l2_format
-{
+struct v4l2_format {
enum v4l2_buf_type type;
- union
- {
+ union {
/* V4L2_BUF_TYPE_VIDEO_CAPTURE: */
struct v4l2_pix_format pix;
/* V4L2_BUF_TYPE_VIDEO_OVERLAY: */
@@ -1240,11 +1203,9 @@
/* Stream type-dependent parameters
*/
-struct v4l2_streamparm
-{
+struct v4l2_streamparm {
enum v4l2_buf_type type;
- union
- {
+ union {
struct v4l2_captureparm capture;
struct v4l2_outputparm output;
uint8_t raw_data[200]; /* user-defined */
@@ -1283,10 +1244,7 @@
#define VIDIOC_ENUM_FMT _IOWR ('V', 2, struct v4l2_fmtdesc)
#define VIDIOC_G_FMT _IOWR ('V', 4, struct v4l2_format)
#define VIDIOC_S_FMT _IOWR ('V', 5, struct v4l2_format)
-#ifdef __KERNEL__
-#define VIDIOC_G_MPEGCOMP _IOR ('V', 6, struct v4l2_mpeg_compression)
-#define VIDIOC_S_MPEGCOMP _IOW ('V', 7, struct v4l2_mpeg_compression)
-#endif
+
#define VIDIOC_REQBUFS _IOWR ('V', 8, struct v4l2_requestbuffers)
#define VIDIOC_QUERYBUF _IOWR ('V', 9, struct v4l2_buffer)
#define VIDIOC_G_FBUF _IOR ('V', 10, struct v4l2_framebuffer)
More information about the p4-projects
mailing list