forked from triochi/qusbmon
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtypes.h
45 lines (39 loc) · 1.08 KB
/
types.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/*
* types.h
*
* Created on: Feb 28, 2009
* Author: archivator
*/
#ifndef TYPES_H_
#define TYPES_H_
#include <QMetaType>
typedef signed int s32;
typedef unsigned int u32;
typedef signed long long s64;
typedef unsigned long long u64;
struct mon_bin_hdr {
u64 id; /* URB ID - from submission to callback */
unsigned char type; /* Same as in text API; extensible. */
unsigned char xfer_type; /* ISO, Intr, Control, Bulk */
unsigned char endpoint; /* Endpoint number and transfer direction */
unsigned char device; /* Device address */
unsigned short bus; /* Bus number */
char flag_setup;
char flag_data;
s64 ts_sec; /* gettimeofday */
s32 ts_usec; /* gettimeofday */
int status;
unsigned int lengthUrb; /* Length of data (submitted or actual) */
unsigned int lengthCaptured; /* Delivered length */
unsigned char setup[8]; /* Only for Control S-type */
};
struct mon_bin_get {
struct mon_bin_hdr *header; /* Only 48 bytes, not 64. */
void *data;
size_t length; /* Length of data (can be zero) */
};
struct mon_bin_stats {
u32 queued;
u32 dropped;
};
#endif /* TYPES_H_ */