Commit 1a4ede65 authored by Hans de Goede's avatar Hans de Goede Committed by Mauro Carvalho Chehab

[media] pwc: Fix non CodingStyle compliant 3 space indent in pwc.h

Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 885fe18f
...@@ -77,9 +77,9 @@ ...@@ -77,9 +77,9 @@
#define PWC_DEBUG_LEVEL (PWC_DEBUG_LEVEL_MODULE) #define PWC_DEBUG_LEVEL (PWC_DEBUG_LEVEL_MODULE)
#define PWC_DEBUG(level, fmt, args...) do {\ #define PWC_DEBUG(level, fmt, args...) do {\
if ((PWC_DEBUG_LEVEL_ ##level) & pwc_trace) \ if ((PWC_DEBUG_LEVEL_ ##level) & pwc_trace) \
printk(KERN_DEBUG PFX fmt, ##args); \ printk(KERN_DEBUG PFX fmt, ##args); \
} while(0) } while (0)
#define PWC_ERROR(fmt, args...) printk(KERN_ERR PFX fmt, ##args) #define PWC_ERROR(fmt, args...) printk(KERN_ERR PFX fmt, ##args)
#define PWC_WARNING(fmt, args...) printk(KERN_WARNING PFX fmt, ##args) #define PWC_WARNING(fmt, args...) printk(KERN_WARNING PFX fmt, ##args)
...@@ -152,40 +152,41 @@ struct pwc_frame_buf ...@@ -152,40 +152,41 @@ struct pwc_frame_buf
struct pwc_device struct pwc_device
{ {
struct video_device vdev; struct video_device vdev;
struct mutex modlock;
/* Pointer to our usb_device, may be NULL after unplug */
struct usb_device *udev; /* Pointer to our usb_device, may be NULL after unplug */
struct usb_device *udev;
int type; /* type of cam (645, 646, 675, 680, 690, 720, 730, 740, 750) */ /* type of cam (645, 646, 675, 680, 690, 720, 730, 740, 750) */
int release; /* release number */ int type;
int features; /* feature bits */ int release; /* release number */
char serial[30]; /* serial number (string) */ int features; /* feature bits */
int error_status; /* set when something goes wrong with the cam (unplugged, USB errors) */ char serial[30]; /* serial number (string) */
int usb_init; /* set when the cam has been initialized over USB */ int error_status; /* set when something goes wrong */
int usb_init; /* set when the cam has been initialized */
/*** Video data ***/
int vopen; /* flag */ /*** Video data ***/
int vendpoint; /* video isoc endpoint */ int vopen; /* flag */
int vcinterface; /* video control interface */ int vendpoint; /* video isoc endpoint */
int valternate; /* alternate interface needed */ int vcinterface; /* video control interface */
int vframes, vsize; /* frames-per-second & size (see PSZ_*) */ int valternate; /* alternate interface needed */
int pixfmt; /* pixelformat: V4L2_PIX_FMT_YUV420 or raw: _PWC1, _PWC2 */ int vframes, vsize; /* frames-per-second & size (see PSZ_*) */
int vframe_count; /* received frames */ int pixfmt; /* pixelformat: V4L2_PIX_FMT_YUV420 or _PWCX */
int vmax_packet_size; /* USB maxpacket size */ int vframe_count; /* received frames */
int vlast_packet_size; /* for frame synchronisation */ int vmax_packet_size; /* USB maxpacket size */
int visoc_errors; /* number of contiguous ISOC errors */ int vlast_packet_size; /* for frame synchronisation */
int vcompression; /* desired compression factor */ int visoc_errors; /* number of contiguous ISOC errors */
int vbandlength; /* compressed band length; 0 is uncompressed */ int vcompression; /* desired compression factor */
char vsnapshot; /* snapshot mode */ int vbandlength; /* compressed band length; 0 is uncompressed */
char vsync; /* used by isoc handler */ char vsnapshot; /* snapshot mode */
char vmirror; /* for ToUCaM series */ char vsync; /* used by isoc handler */
char vmirror; /* for ToUCaM series */
char unplugged; char unplugged;
int cmd_len; int cmd_len;
unsigned char cmd_buf[13]; unsigned char cmd_buf[13];
struct pwc_iso_buf sbuf[MAX_ISO_BUFS]; struct pwc_iso_buf sbuf[MAX_ISO_BUFS];
char iso_init; char iso_init;
/* videobuf2 queue and queued buffers list */ /* videobuf2 queue and queued buffers list */
struct vb2_queue vb_queue; struct vb2_queue vb_queue;
...@@ -200,39 +201,43 @@ struct pwc_device ...@@ -200,39 +201,43 @@ struct pwc_device
*/ */
struct pwc_frame_buf *fill_buf; struct pwc_frame_buf *fill_buf;
int frame_header_size, frame_trailer_size; int frame_header_size, frame_trailer_size;
int frame_size; int frame_size;
int frame_total_size; /* including header & trailer */ int frame_total_size; /* including header & trailer */
int drop_frames; int drop_frames;
void *decompress_data; /* private data for decompression engine */ void *decompress_data; /* private data for decompression engine */
/* We have an 'image' and a 'view', where 'image' is the fixed-size image /*
as delivered by the camera, and 'view' is the size requested by the * We have an 'image' and a 'view', where 'image' is the fixed-size img
program. The camera image is centered in this viewport, laced with * as delivered by the camera, and 'view' is the size requested by the
a gray or black border. view_min <= image <= view <= view_max; * program. The camera image is centered in this viewport, laced with
*/ * a gray or black border. view_min <= image <= view <= view_max;
int image_mask; /* bitmask of supported sizes */ */
struct pwc_coord view_min, view_max; /* minimum and maximum viewable sizes */ int image_mask; /* supported sizes */
struct pwc_coord abs_max; /* maximum supported size with compression */ struct pwc_coord view_min, view_max; /* minimum and maximum view */
struct pwc_coord image, view; /* image and viewport size */ struct pwc_coord abs_max; /* maximum supported size */
struct pwc_coord offset; /* offset within the viewport */ struct pwc_coord image, view; /* image and viewport size */
struct pwc_coord offset; /* offset of the viewport */
struct mutex modlock; /* to prevent races in video_open(), etc */
/*** motorized pan/tilt feature */
/*** motorized pan/tilt feature */ struct pwc_mpt_range angle_range;
struct pwc_mpt_range angle_range; int pan_angle; /* in degrees * 100 */
int pan_angle; /* in degrees * 100 */ int tilt_angle; /* absolute angle; 0,0 is home */
int tilt_angle; /* absolute angle; 0,0 is home position */
int snapshot_button_status; /* set to 1 when the user push the button, reset to 0 when this value is read */ /*
* Set to 1 when the user push the button, reset to 0
* when this value is read from sysfs.
*/
int snapshot_button_status;
#ifdef CONFIG_USB_PWC_INPUT_EVDEV #ifdef CONFIG_USB_PWC_INPUT_EVDEV
struct input_dev *button_dev; /* webcam snapshot button input */ struct input_dev *button_dev; /* webcam snapshot button input */
char button_phys[64]; char button_phys[64];
#endif #endif
/*** Misc. data ***/ /*** Misc. data ***/
#if PWC_INT_PIPE #if PWC_INT_PIPE
void *usb_int_handler; /* for the interrupt endpoint */ void *usb_int_handler; /* for the interrupt endpoint */
#endif #endif
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment