2 * Copyright (c) 2008 Intel Corporation. All rights reserved.
\r
4 * This software is available to you under the OpenIB.org BSD license
\r
7 * Redistribution and use in source and binary forms, with or
\r
8 * without modification, are permitted provided that the following
\r
9 * conditions are met:
\r
11 * - Redistributions of source code must retain the above
\r
12 * copyright notice, this list of conditions and the following
\r
15 * - Redistributions in binary form must reproduce the above
\r
16 * copyright notice, this list of conditions and the following
\r
17 * disclaimer in the documentation and/or other materials
\r
18 * provided with the distribution.
\r
20 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
\r
21 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
\r
22 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AWV
\r
23 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
\r
24 * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
\r
25 * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
\r
26 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
\r
32 #ifndef _WM_IOCTL_H_
\r
33 #define _WM_IOCTL_H_
\r
35 typedef UINT16 NET16;
\r
36 typedef UINT32 NET32;
\r
37 typedef UINT64 NET64;
\r
39 #define WM_IOCTL(f) CTL_CODE(FILE_DEVICE_INFINIBAND, f, METHOD_BUFFERED,\
\r
40 FILE_READ_DATA | FILE_WRITE_DATA)
\r
42 // input parameter / output parameter
\r
44 #define WM_IO_FUNCTION_BASE 0x800
\r
48 WM_IO_FUNCTION_REGISTER,
\r
49 WM_IO_FUNCTION_DEREGISTER,
\r
50 WM_IO_FUNCTION_CANCEL,
\r
54 // WM_IO_REGISTER / UINT64 Id
\r
55 #define WM_IOCTL_REGISTER WM_IOCTL(WM_IO_FUNCTION_BASE + \
\r
56 WM_IO_FUNCTION_REGISTER)
\r
59 #define WM_IOCTL_DEREGISTER WM_IOCTL(WM_IO_FUNCTION_BASE + \
\r
60 WM_IO_FUNCTION_DEREGISTER)
\r
63 #define WM_IOCTL_CANCEL WM_IOCTL(WM_IO_FUNCTION_BASE + \
\r
64 WM_IO_FUNCTION_CANCEL)
\r
66 #define WM_IOCTL_MIN WM_IO_FUNCTION_BASE + WM_IO_FUNCTION_MIN
\r
67 #define WM_IOCTL_MAX WM_IO_FUNCTION_BASE + WM_IO_FUNCTION_MAX
\r
69 typedef struct _WM_IO_REGISTER
\r
82 typedef struct _WM_IO_MAD_AV
\r
86 NET32 VersionClassFlow;
\r
101 #pragma warning(push)
\r
102 #pragma warning(disable: 4200)
\r
103 typedef struct _WM_IO_MAD
\r
106 WM_IO_MAD_AV Address;
\r
116 #pragma warning(pop)
\r
118 #endif // _WM_IOCTL_H_
\r