Commit 52cb0bf2 authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab

[media] usbvision: convert // to /* */

Signed-off-by: default avatarHans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 5490a7cb
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
static int i2c_debug; static int i2c_debug;
module_param (i2c_debug, int, 0644); // debug_i2c_usb mode of the device driver module_param (i2c_debug, int, 0644); /* debug_i2c_usb mode of the device driver */
MODULE_PARM_DESC(i2c_debug, "enable debug messages [i2c]"); MODULE_PARM_DESC(i2c_debug, "enable debug messages [i2c]");
#define PDEBUG(level, fmt, args...) { \ #define PDEBUG(level, fmt, args...) { \
......
...@@ -103,7 +103,7 @@ USBVISION_DRIVER_VERSION_PATCHLEVEL) ...@@ -103,7 +103,7 @@ USBVISION_DRIVER_VERSION_PATCHLEVEL)
#define DBG_PROBE 1<<2 #define DBG_PROBE 1<<2
#define DBG_MMAP 1<<3 #define DBG_MMAP 1<<3
//String operations /* String operations */
#define rmspace(str) while(*str==' ') str++; #define rmspace(str) while(*str==' ') str++;
#define goto2next(str) while(*str!=' ') str++; while(*str==' ') str++; #define goto2next(str) while(*str!=' ') str++; while(*str==' ') str++;
...@@ -118,7 +118,7 @@ static struct usbvision_v4l2_format_st usbvision_v4l2_format[] = { ...@@ -118,7 +118,7 @@ static struct usbvision_v4l2_format_st usbvision_v4l2_format[] = {
{ 1, 4, 32, V4L2_PIX_FMT_RGB32 , "RGB32" }, { 1, 4, 32, V4L2_PIX_FMT_RGB32 , "RGB32" },
{ 1, 2, 16, V4L2_PIX_FMT_RGB555 , "RGB555" }, { 1, 2, 16, V4L2_PIX_FMT_RGB555 , "RGB555" },
{ 1, 2, 16, V4L2_PIX_FMT_YUYV , "YUV422" }, { 1, 2, 16, V4L2_PIX_FMT_YUYV , "YUV422" },
{ 1, 2, 12, V4L2_PIX_FMT_YVU420 , "YUV420P" }, // 1.5 ! { 1, 2, 12, V4L2_PIX_FMT_YVU420 , "YUV420P" }, /* 1.5 ! */
{ 1, 2, 16, V4L2_PIX_FMT_YUV422P , "YUV422P" } { 1, 2, 16, V4L2_PIX_FMT_YUV422P , "YUV422P" }
}; };
...@@ -153,7 +153,7 @@ MODULE_PARM_DESC(video_nr, "Set video device number (/dev/videoX). Default: -1 ...@@ -153,7 +153,7 @@ MODULE_PARM_DESC(video_nr, "Set video device number (/dev/videoX). Default: -1
MODULE_PARM_DESC(radio_nr, "Set radio device number (/dev/radioX). Default: -1 (autodetect)"); MODULE_PARM_DESC(radio_nr, "Set radio device number (/dev/radioX). Default: -1 (autodetect)");
// Misc stuff /* Misc stuff */
MODULE_AUTHOR(DRIVER_AUTHOR); MODULE_AUTHOR(DRIVER_AUTHOR);
MODULE_DESCRIPTION(DRIVER_DESC); MODULE_DESCRIPTION(DRIVER_DESC);
MODULE_LICENSE(DRIVER_LICENSE); MODULE_LICENSE(DRIVER_LICENSE);
...@@ -534,7 +534,7 @@ static int vidioc_enum_input (struct file *file, void *priv, ...@@ -534,7 +534,7 @@ static int vidioc_enum_input (struct file *file, void *priv,
if (usbvision->have_tuner) { if (usbvision->have_tuner) {
chan = vi->index; chan = vi->index;
} else { } else {
chan = vi->index + 1; /*skip Television string*/ chan = vi->index + 1; /* skip Television string*/
} }
/* Determine the requested input characteristics /* Determine the requested input characteristics
specific for each usbvision card model */ specific for each usbvision card model */
...@@ -618,7 +618,7 @@ static int vidioc_g_tuner (struct file *file, void *priv, ...@@ -618,7 +618,7 @@ static int vidioc_g_tuner (struct file *file, void *priv,
{ {
struct usb_usbvision *usbvision = video_drvdata(file); struct usb_usbvision *usbvision = video_drvdata(file);
if (!usbvision->have_tuner || vt->index) // Only tuner 0 if (!usbvision->have_tuner || vt->index) /* Only tuner 0 */
return -EINVAL; return -EINVAL;
if(usbvision->radio) { if(usbvision->radio) {
strcpy(vt->name, "Radio"); strcpy(vt->name, "Radio");
...@@ -637,7 +637,7 @@ static int vidioc_s_tuner (struct file *file, void *priv, ...@@ -637,7 +637,7 @@ static int vidioc_s_tuner (struct file *file, void *priv,
{ {
struct usb_usbvision *usbvision = video_drvdata(file); struct usb_usbvision *usbvision = video_drvdata(file);
// Only no or one tuner for now /* Only no or one tuner for now */
if (!usbvision->have_tuner || vt->index) if (!usbvision->have_tuner || vt->index)
return -EINVAL; return -EINVAL;
/* let clients handle this */ /* let clients handle this */
...@@ -651,7 +651,7 @@ static int vidioc_g_frequency (struct file *file, void *priv, ...@@ -651,7 +651,7 @@ static int vidioc_g_frequency (struct file *file, void *priv,
{ {
struct usb_usbvision *usbvision = video_drvdata(file); struct usb_usbvision *usbvision = video_drvdata(file);
freq->tuner = 0; // Only one tuner freq->tuner = 0; /* Only one tuner */
if(usbvision->radio) { if(usbvision->radio) {
freq->type = V4L2_TUNER_RADIO; freq->type = V4L2_TUNER_RADIO;
} else { } else {
...@@ -667,7 +667,7 @@ static int vidioc_s_frequency (struct file *file, void *priv, ...@@ -667,7 +667,7 @@ static int vidioc_s_frequency (struct file *file, void *priv,
{ {
struct usb_usbvision *usbvision = video_drvdata(file); struct usb_usbvision *usbvision = video_drvdata(file);
// Only no or one tuner for now /* Only no or one tuner for now */
if (!usbvision->have_tuner || freq->tuner) if (!usbvision->have_tuner || freq->tuner)
return -EINVAL; return -EINVAL;
...@@ -1069,7 +1069,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf, ...@@ -1069,7 +1069,7 @@ static ssize_t usbvision_v4l2_read(struct file *file, char __user *buf,
(unsigned long)count, frame->bytes_read); (unsigned long)count, frame->bytes_read);
/* For now, forget the frame if it has not been read in one shot. */ /* For now, forget the frame if it has not been read in one shot. */
/* if (frame->bytes_read >= frame->scanlength) {// All data has been read */ /* if (frame->bytes_read >= frame->scanlength) {*/ /* All data has been read */
frame->bytes_read = 0; frame->bytes_read = 0;
/* Mark it as available to be used again. */ /* Mark it as available to be used again. */
...@@ -1163,7 +1163,7 @@ static int usbvision_radio_open(struct file *file) ...@@ -1163,7 +1163,7 @@ static int usbvision_radio_open(struct file *file)
goto out; goto out;
} }
// If so far no errors then we shall start the radio /* If so far no errors then we shall start the radio */
usbvision->radio = 1; usbvision->radio = 1;
call_all(usbvision, tuner, s_radio); call_all(usbvision, tuner, s_radio);
usbvision_set_audio(usbvision, USBVISION_AUDIO_RADIO); usbvision_set_audio(usbvision, USBVISION_AUDIO_RADIO);
...@@ -1212,11 +1212,9 @@ static int usbvision_radio_close(struct file *file) ...@@ -1212,11 +1212,9 @@ static int usbvision_radio_close(struct file *file)
return err_code; return err_code;
} }
// /* Video registration stuff */
// Video registration stuff
//
// Video template /* Video template */
static const struct v4l2_file_operations usbvision_fops = { static const struct v4l2_file_operations usbvision_fops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.open = usbvision_v4l2_open, .open = usbvision_v4l2_open,
...@@ -1268,7 +1266,7 @@ static struct video_device usbvision_video_template = { ...@@ -1268,7 +1266,7 @@ static struct video_device usbvision_video_template = {
}; };
// Radio template /* Radio template */
static const struct v4l2_file_operations usbvision_radio_fops = { static const struct v4l2_file_operations usbvision_radio_fops = {
.owner = THIS_MODULE, .owner = THIS_MODULE,
.open = usbvision_radio_open, .open = usbvision_radio_open,
...@@ -1328,10 +1326,10 @@ static struct video_device *usbvision_vdev_init(struct usb_usbvision *usbvision, ...@@ -1328,10 +1326,10 @@ static struct video_device *usbvision_vdev_init(struct usb_usbvision *usbvision,
return vdev; return vdev;
} }
// unregister video4linux devices /* unregister video4linux devices */
static void usbvision_unregister_video(struct usb_usbvision *usbvision) static void usbvision_unregister_video(struct usb_usbvision *usbvision)
{ {
// Radio Device: /* Radio Device: */
if (usbvision->rdev) { if (usbvision->rdev) {
PDEBUG(DBG_PROBE, "unregister %s [v4l2]", PDEBUG(DBG_PROBE, "unregister %s [v4l2]",
video_device_node_name(usbvision->rdev)); video_device_node_name(usbvision->rdev));
...@@ -1343,7 +1341,7 @@ static void usbvision_unregister_video(struct usb_usbvision *usbvision) ...@@ -1343,7 +1341,7 @@ static void usbvision_unregister_video(struct usb_usbvision *usbvision)
usbvision->rdev = NULL; usbvision->rdev = NULL;
} }
// Video Device: /* Video Device: */
if (usbvision->vdev) { if (usbvision->vdev) {
PDEBUG(DBG_PROBE, "unregister %s [v4l2]", PDEBUG(DBG_PROBE, "unregister %s [v4l2]",
video_device_node_name(usbvision->vdev)); video_device_node_name(usbvision->vdev));
...@@ -1356,10 +1354,10 @@ static void usbvision_unregister_video(struct usb_usbvision *usbvision) ...@@ -1356,10 +1354,10 @@ static void usbvision_unregister_video(struct usb_usbvision *usbvision)
} }
} }
// register video4linux devices /* register video4linux devices */
static int __devinit usbvision_register_video(struct usb_usbvision *usbvision) static int __devinit usbvision_register_video(struct usb_usbvision *usbvision)
{ {
// Video Device: /* Video Device: */
usbvision->vdev = usbvision_vdev_init(usbvision, usbvision->vdev = usbvision_vdev_init(usbvision,
&usbvision_video_template, &usbvision_video_template,
"USBVision Video"); "USBVision Video");
...@@ -1374,9 +1372,9 @@ static int __devinit usbvision_register_video(struct usb_usbvision *usbvision) ...@@ -1374,9 +1372,9 @@ static int __devinit usbvision_register_video(struct usb_usbvision *usbvision)
printk(KERN_INFO "USBVision[%d]: registered USBVision Video device %s [v4l2]\n", printk(KERN_INFO "USBVision[%d]: registered USBVision Video device %s [v4l2]\n",
usbvision->nr, video_device_node_name(usbvision->vdev)); usbvision->nr, video_device_node_name(usbvision->vdev));
// Radio Device: /* Radio Device: */
if (usbvision_device_data[usbvision->dev_model].radio) { if (usbvision_device_data[usbvision->dev_model].radio) {
// usbvision has radio /* usbvision has radio */
usbvision->rdev = usbvision_vdev_init(usbvision, usbvision->rdev = usbvision_vdev_init(usbvision,
&usbvision_radio_template, &usbvision_radio_template,
"USBVision Radio"); "USBVision Radio");
...@@ -1391,7 +1389,7 @@ static int __devinit usbvision_register_video(struct usb_usbvision *usbvision) ...@@ -1391,7 +1389,7 @@ static int __devinit usbvision_register_video(struct usb_usbvision *usbvision)
printk(KERN_INFO "USBVision[%d]: registered USBVision Radio device %s [v4l2]\n", printk(KERN_INFO "USBVision[%d]: registered USBVision Radio device %s [v4l2]\n",
usbvision->nr, video_device_node_name(usbvision->rdev)); usbvision->nr, video_device_node_name(usbvision->rdev));
} }
// all done /* all done */
return 0; return 0;
err_exit: err_exit:
...@@ -1426,7 +1424,7 @@ static struct usb_usbvision *usbvision_alloc(struct usb_device *dev, ...@@ -1426,7 +1424,7 @@ static struct usb_usbvision *usbvision_alloc(struct usb_device *dev,
mutex_init(&usbvision->v4l2_lock); mutex_init(&usbvision->v4l2_lock);
// prepare control urb for control messages during interrupts /* prepare control urb for control messages during interrupts */
usbvision->ctrl_urb = usb_alloc_urb(USBVISION_URB_FRAMES, GFP_KERNEL); usbvision->ctrl_urb = usb_alloc_urb(USBVISION_URB_FRAMES, GFP_KERNEL);
if (usbvision->ctrl_urb == NULL) if (usbvision->ctrl_urb == NULL)
goto err_unreg; goto err_unreg;
...@@ -1482,7 +1480,7 @@ static void usbvision_configure_video(struct usb_usbvision *usbvision) ...@@ -1482,7 +1480,7 @@ static void usbvision_configure_video(struct usb_usbvision *usbvision)
return; return;
model = usbvision->dev_model; model = usbvision->dev_model;
usbvision->palette = usbvision_v4l2_format[2]; // V4L2_PIX_FMT_RGB24; usbvision->palette = usbvision_v4l2_format[2]; /* V4L2_PIX_FMT_RGB24; */
if (usbvision_device_data[usbvision->dev_model].vin_reg2_override) { if (usbvision_device_data[usbvision->dev_model].vin_reg2_override) {
usbvision->vin_reg2_preset = usbvision->vin_reg2_preset =
...@@ -1639,7 +1637,7 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf) ...@@ -1639,7 +1637,7 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf)
mutex_lock(&usbvision->v4l2_lock); mutex_lock(&usbvision->v4l2_lock);
// At this time we ask to cancel outstanding URBs /* At this time we ask to cancel outstanding URBs */
usbvision_stop_isoc(usbvision); usbvision_stop_isoc(usbvision);
v4l2_device_disconnect(&usbvision->v4l2_dev); v4l2_device_disconnect(&usbvision->v4l2_dev);
...@@ -1648,10 +1646,10 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf) ...@@ -1648,10 +1646,10 @@ static void __devexit usbvision_disconnect(struct usb_interface *intf)
usbvision_i2c_unregister(usbvision); usbvision_i2c_unregister(usbvision);
usbvision_power_off(usbvision); usbvision_power_off(usbvision);
} }
usbvision->remove_pending = 1; // Now all ISO data will be ignored usbvision->remove_pending = 1; /* Now all ISO data will be ignored */
usb_put_dev(usbvision->dev); usb_put_dev(usbvision->dev);
usbvision->dev = NULL; // USB device is no more usbvision->dev = NULL; /* USB device is no more */
mutex_unlock(&usbvision->v4l2_lock); mutex_unlock(&usbvision->v4l2_lock);
...@@ -1692,9 +1690,9 @@ static int __init usbvision_init(void) ...@@ -1692,9 +1690,9 @@ static int __init usbvision_init(void)
/* disable planar mode support unless compression enabled */ /* disable planar mode support unless compression enabled */
if (isoc_mode != ISOC_MODE_COMPRESS ) { if (isoc_mode != ISOC_MODE_COMPRESS ) {
// FIXME : not the right way to set supported flag /* FIXME : not the right way to set supported flag */
usbvision_v4l2_format[6].supported = 0; // V4L2_PIX_FMT_YVU420 usbvision_v4l2_format[6].supported = 0; /* V4L2_PIX_FMT_YVU420 */
usbvision_v4l2_format[7].supported = 0; // V4L2_PIX_FMT_YUV422P usbvision_v4l2_format[7].supported = 0; /* V4L2_PIX_FMT_YUV422P */
} }
err_code = usb_register(&usbvision_driver); err_code = usb_register(&usbvision_driver);
......
...@@ -132,15 +132,15 @@ ...@@ -132,15 +132,15 @@
#define MAX_BYTES_PER_PIXEL 4 #define MAX_BYTES_PER_PIXEL 4
#define MIN_FRAME_WIDTH 64 #define MIN_FRAME_WIDTH 64
#define MAX_USB_WIDTH 320 //384 #define MAX_USB_WIDTH 320 /* 384 */
#define MAX_FRAME_WIDTH 320 //384 /*streching sometimes causes crashes*/ #define MAX_FRAME_WIDTH 320 /* 384 */ /* streching sometimes causes crashes*/
#define MIN_FRAME_HEIGHT 48 #define MIN_FRAME_HEIGHT 48
#define MAX_USB_HEIGHT 240 //288 #define MAX_USB_HEIGHT 240 /* 288 */
#define MAX_FRAME_HEIGHT 240 //288 /*Streching sometimes causes crashes*/ #define MAX_FRAME_HEIGHT 240 /* 288 */ /* Streching sometimes causes crashes*/
#define MAX_FRAME_SIZE (MAX_FRAME_WIDTH * MAX_FRAME_HEIGHT * MAX_BYTES_PER_PIXEL) #define MAX_FRAME_SIZE (MAX_FRAME_WIDTH * MAX_FRAME_HEIGHT * MAX_BYTES_PER_PIXEL)
#define USBVISION_CLIPMASK_SIZE (MAX_FRAME_WIDTH * MAX_FRAME_HEIGHT / 8) //bytesize of clipmask #define USBVISION_CLIPMASK_SIZE (MAX_FRAME_WIDTH * MAX_FRAME_HEIGHT / 8) /* bytesize of clipmask */
#define USBVISION_URB_FRAMES 32 #define USBVISION_URB_FRAMES 32
...@@ -148,7 +148,7 @@ ...@@ -148,7 +148,7 @@
#define USBVISION_NUMFRAMES 3 /* Maximum number of frames an application can get */ #define USBVISION_NUMFRAMES 3 /* Maximum number of frames an application can get */
#define USBVISION_NUMSBUF 2 /* Dimensioning the USB S buffering */ #define USBVISION_NUMSBUF 2 /* Dimensioning the USB S buffering */
#define USBVISION_POWEROFF_TIME 3 * (HZ) // 3 seconds #define USBVISION_POWEROFF_TIME 3 * (HZ) /* 3 seconds */
#define FRAMERATE_MIN 0 #define FRAMERATE_MIN 0
...@@ -287,7 +287,7 @@ struct usbvision_frame_header { ...@@ -287,7 +287,7 @@ struct usbvision_frame_header {
unsigned char magic_1; /* 0 magic */ unsigned char magic_1; /* 0 magic */
unsigned char magic_2; /* 1 magic */ unsigned char magic_2; /* 1 magic */
unsigned char header_length; /* 2 */ unsigned char header_length; /* 2 */
unsigned char frame_num; /* 3 */ unsigned char frame_num; /* 3 */
unsigned char frame_phase; /* 4 */ unsigned char frame_phase; /* 4 */
unsigned char frame_latency; /* 5 */ unsigned char frame_latency; /* 5 */
unsigned char data_format; /* 6 */ unsigned char data_format; /* 6 */
...@@ -322,7 +322,7 @@ struct usbvision_frame { ...@@ -322,7 +322,7 @@ struct usbvision_frame {
struct usbvision_v4l2_format_st v4l2_format; /* format the user needs*/ struct usbvision_v4l2_format_st v4l2_format; /* format the user needs*/
int v4l2_linesize; /* bytes for one videoline*/ int v4l2_linesize; /* bytes for one videoline*/
struct timeval timestamp; struct timeval timestamp;
int sequence; // How many video frames we send to user int sequence; /* How many video frames we send to user */
}; };
#define CODEC_SAA7113 7113 #define CODEC_SAA7113 7113
...@@ -369,19 +369,19 @@ struct usb_usbvision { ...@@ -369,19 +369,19 @@ struct usb_usbvision {
unsigned char ctrl_urb_buffer[8]; unsigned char ctrl_urb_buffer[8];
int ctrl_urb_busy; int ctrl_urb_busy;
struct usb_ctrlrequest ctrl_urb_setup; struct usb_ctrlrequest ctrl_urb_setup;
wait_queue_head_t ctrl_urb_wq; // Processes waiting wait_queue_head_t ctrl_urb_wq; /* Processes waiting */
/* configuration part */ /* configuration part */
int have_tuner; int have_tuner;
int tuner_type; int tuner_type;
int bridge_type; // NT1003, NT1004, NT1005 int bridge_type; /* NT1003, NT1004, NT1005 */
int radio; int radio;
int video_inputs; // # of inputs int video_inputs; /* # of inputs */
unsigned long freq; unsigned long freq;
int audio_mute; int audio_mute;
int audio_channel; int audio_channel;
int isoc_mode; // format of video data for the usb isoc-transfer int isoc_mode; /* format of video data for the usb isoc-transfer */
unsigned int nr; // Number of the device unsigned int nr; /* Number of the device */
/* Device structure */ /* Device structure */
struct usb_device *dev; struct usb_device *dev;
...@@ -389,7 +389,7 @@ struct usb_usbvision { ...@@ -389,7 +389,7 @@ struct usb_usbvision {
int num_alt; /* Number of alternative settings */ int num_alt; /* Number of alternative settings */
unsigned int *alt_max_pkt_size; /* array of max_packet_size */ unsigned int *alt_max_pkt_size; /* array of max_packet_size */
unsigned char iface; /* Video interface number */ unsigned char iface; /* Video interface number */
unsigned char iface_alt; /* Alt settings */ unsigned char iface_alt; /* Alt settings */
unsigned char vin_reg2_preset; unsigned char vin_reg2_preset;
struct mutex v4l2_lock; struct mutex v4l2_lock;
struct timer_list power_off_timer; struct timer_list power_off_timer;
...@@ -411,10 +411,10 @@ struct usb_usbvision { ...@@ -411,10 +411,10 @@ struct usb_usbvision {
struct list_head inqueue, outqueue; /* queued frame list and ready to dequeue frame list */ struct list_head inqueue, outqueue; /* queued frame list and ready to dequeue frame list */
wait_queue_head_t wait_frame; /* Processes waiting */ wait_queue_head_t wait_frame; /* Processes waiting */
wait_queue_head_t wait_stream; /* Processes waiting */ wait_queue_head_t wait_stream; /* Processes waiting */
struct usbvision_frame *cur_frame; // pointer to current frame, set by usbvision_find_header struct usbvision_frame *cur_frame; /* pointer to current frame, set by usbvision_find_header */
struct usbvision_frame frame[USBVISION_NUMFRAMES]; // frame buffer struct usbvision_frame frame[USBVISION_NUMFRAMES]; /* frame buffer */
int num_frames; // number of frames allocated int num_frames; /* number of frames allocated */
struct usbvision_sbuf sbuf[USBVISION_NUMSBUF]; // S buffering struct usbvision_sbuf sbuf[USBVISION_NUMSBUF]; /* S buffering */
volatile int remove_pending; /* If set then about to exit */ volatile int remove_pending; /* If set then about to exit */
/* Scratch space from the Isochronous Pipe.*/ /* Scratch space from the Isochronous Pipe.*/
...@@ -432,32 +432,32 @@ struct usb_usbvision { ...@@ -432,32 +432,32 @@ struct usb_usbvision {
v4l2_std_id tvnorm_id; /* selected tv norm */ v4l2_std_id tvnorm_id; /* selected tv norm */
unsigned char video_endp; /* 0x82 for USBVISION devices based */ unsigned char video_endp; /* 0x82 for USBVISION devices based */
// Decompression stuff: /* Decompression stuff: */
unsigned char *intra_frame_buffer; /* Buffer for reference frame */ unsigned char *intra_frame_buffer; /* Buffer for reference frame */
int block_pos; //for test only int block_pos; /* for test only */
int request_intra; // 0 = normal; 1 = intra frame is requested; int request_intra; /* 0 = normal; 1 = intra frame is requested; */
int last_isoc_frame_num; // check for lost isoc frames int last_isoc_frame_num; /* check for lost isoc frames */
int isoc_packet_size; // need to calculate used_bandwidth int isoc_packet_size; /* need to calculate used_bandwidth */
int used_bandwidth; // used bandwidth 0-100%, need to set compr_level int used_bandwidth; /* used bandwidth 0-100%, need to set compr_level */
int compr_level; // How strong (100) or weak (0) is compression int compr_level; /* How strong (100) or weak (0) is compression */
int last_compr_level; // How strong (100) or weak (0) was compression int last_compr_level; /* How strong (100) or weak (0) was compression */
int usb_bandwidth; /* Mbit/s */ int usb_bandwidth; /* Mbit/s */
/* Statistics that can be overlayed on the screen */ /* Statistics that can be overlayed on the screen */
unsigned long isoc_urb_count; // How many URBs we received so far unsigned long isoc_urb_count; /* How many URBs we received so far */
unsigned long urb_length; /* Length of last URB */ unsigned long urb_length; /* Length of last URB */
unsigned long isoc_data_count; /* How many bytes we received */ unsigned long isoc_data_count; /* How many bytes we received */
unsigned long header_count; /* How many frame headers we found */ unsigned long header_count; /* How many frame headers we found */
unsigned long scratch_ovf_count; /* How many times we overflowed scratch */ unsigned long scratch_ovf_count; /* How many times we overflowed scratch */
unsigned long isoc_skip_count; /* How many empty ISO packets received */ unsigned long isoc_skip_count; /* How many empty ISO packets received */
unsigned long isoc_err_count; /* How many bad ISO packets received */ unsigned long isoc_err_count; /* How many bad ISO packets received */
unsigned long isoc_packet_count; // How many packets we totally got unsigned long isoc_packet_count; /* How many packets we totally got */
unsigned long time_in_irq; // How long do we need for interrupt unsigned long time_in_irq; /* How long do we need for interrupt */
int isoc_measure_bandwidth_count; int isoc_measure_bandwidth_count;
int frame_num; // How many video frames we send to user int frame_num; /* How many video frames we send to user */
int max_strip_len; // How big is the biggest strip int max_strip_len; /* How big is the biggest strip */
int comprblock_pos; int comprblock_pos;
int strip_len_errors; // How many times was block_pos greater than strip_len int strip_len_errors; /* How many times was block_pos greater than strip_len */
int strip_magic_errors; int strip_magic_errors;
int strip_line_number_errors; int strip_line_number_errors;
int compr_block_types[4]; int compr_block_types[4];
......
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