[IPOIB] g_stat: added more fields: prev_port and halt thread.
[mirror/winof/.git] / ulp / ipoib_NDIS6_CM / kernel / ipoib_stat.h
1 /*++\r
2 \r
3 Copyright (c) 2005-2009 Mellanox Technologies. All rights reserved.\r
4 \r
5 Module Name:\r
6         ipoib_stat.h\r
7 \r
8 Abstract:\r
9         Statistics Collector header file\r
10 \r
11 Revision History:\r
12 \r
13 Notes:\r
14 \r
15 --*/\r
16 \r
17 #pragma once\r
18 \r
19 #include <ntddk.h>\r
20 \r
21 //\r
22 // restrictions\r
23 //\r
24 \r
25 #define IPOIB_ST_MAX_DEVICES                    8\r
26 \r
27 //\r
28 // enums\r
29 // \r
30 \r
31 //\r
32 // structures\r
33 //\r
34 \r
35 // device\r
36 typedef struct _ipoib_adapter ipoib_adapter_t;\r
37 typedef struct _ipoib_port ipoib_port_t;\r
38 \r
39 typedef struct _IPOIB_ST_DEVICE\r
40 {\r
41         boolean_t                       valid;\r
42         ipoib_adapter_t         *p_adapter;\r
43         ipoib_port_t            *p_prev_port;\r
44         PRKTHREAD                       *p_halt_thread;\r
45         int                                     n_power_irps;   // NdisDevicePnPEventPowerProfileChanged \r
46         int                                     n_pnp_irps;             // NdisDevicePnPEventSurpriseRemoved \r
47         \r
48 } IPOIB_ST_DEVICE, *PIPOIB_ST_DEVICE;\r
49 \r
50 // driver\r
51 typedef struct _IPOIB_ST_DRIVER\r
52 {\r
53         PDRIVER_OBJECT          obj;\r
54         \r
55 } IPOIB_ST_DRIVER, *PIPOIB_ST_DRIVER;\r
56 \r
57 // driver stack\r
58 \r
59 typedef struct _IPOIB_ST_STAT\r
60 {\r
61         IPOIB_ST_DRIVER         drv;\r
62         IPOIB_ST_DEVICE         dev[IPOIB_ST_MAX_DEVICES];\r
63         \r
64 } IPOIB_ST_STAT, *PIPOIB_ST_STAT;\r
65 \r
66 extern IPOIB_ST_STAT g_stat;\r
67 \r
68 //\r
69 // functions \r
70 //\r
71 \r
72 void ipoib_st_dev_rmv( PIPOIB_ST_DEVICE p_stat );\r
73 \r
74 PIPOIB_ST_DEVICE ipoib_st_dev_add();\r
75 \r
76 void ipoib_st_init();\r
77 \r
78 \r
79 \r