diff options
author | Hal Rosenstock <halr@voltaire.com> | 2005-07-27 14:45:41 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-07-27 19:26:14 -0400 |
commit | 3f75daddb4fc6b695faa4e12e76894389e913dcb (patch) | |
tree | 33f665bd5d0c42d616196dbbc15d9925519feb50 /drivers | |
parent | a977049dacdef6a9e69fb4872b42a68e93a69956 (diff) |
[PATCH] IB: User MAD ABI changes to support RMPP
User MAD ABI changes to support RMPP
Signed-off-by: Hal Rosenstock <halr@voltaire.com>
Cc: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/infiniband/include/ib_user_mad.h | 28 |
1 files changed, 22 insertions, 6 deletions
diff --git a/drivers/infiniband/include/ib_user_mad.h b/drivers/infiniband/include/ib_user_mad.h index 06ad4a6075fa..a9a56b50aacc 100644 --- a/drivers/infiniband/include/ib_user_mad.h +++ b/drivers/infiniband/include/ib_user_mad.h | |||
@@ -1,5 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2004 Topspin Communications. All rights reserved. | 2 | * Copyright (c) 2004 Topspin Communications. All rights reserved. |
3 | * Copyright (c) 2005 Voltaire, Inc. All rights reserved. | ||
3 | * | 4 | * |
4 | * This software is available to you under a choice of one of two | 5 | * This software is available to you under a choice of one of two |
5 | * licenses. You may choose to be licensed under the terms of the GNU | 6 | * licenses. You may choose to be licensed under the terms of the GNU |
@@ -29,7 +30,7 @@ | |||
29 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | 30 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
30 | * SOFTWARE. | 31 | * SOFTWARE. |
31 | * | 32 | * |
32 | * $Id: ib_user_mad.h 1389 2004-12-27 22:56:47Z roland $ | 33 | * $Id: ib_user_mad.h 2814 2005-07-06 19:14:09Z halr $ |
33 | */ | 34 | */ |
34 | 35 | ||
35 | #ifndef IB_USER_MAD_H | 36 | #ifndef IB_USER_MAD_H |
@@ -42,7 +43,7 @@ | |||
42 | * Increment this value if any changes that break userspace ABI | 43 | * Increment this value if any changes that break userspace ABI |
43 | * compatibility are made. | 44 | * compatibility are made. |
44 | */ | 45 | */ |
45 | #define IB_USER_MAD_ABI_VERSION 2 | 46 | #define IB_USER_MAD_ABI_VERSION 5 |
46 | 47 | ||
47 | /* | 48 | /* |
48 | * Make sure that all structs defined in this file remain laid out so | 49 | * Make sure that all structs defined in this file remain laid out so |
@@ -51,13 +52,13 @@ | |||
51 | */ | 52 | */ |
52 | 53 | ||
53 | /** | 54 | /** |
54 | * ib_user_mad - MAD packet | 55 | * ib_user_mad_hdr - MAD packet header |
55 | * @data - Contents of MAD | ||
56 | * @id - ID of agent MAD received with/to be sent with | 56 | * @id - ID of agent MAD received with/to be sent with |
57 | * @status - 0 on successful receive, ETIMEDOUT if no response | 57 | * @status - 0 on successful receive, ETIMEDOUT if no response |
58 | * received (transaction ID in data[] will be set to TID of original | 58 | * received (transaction ID in data[] will be set to TID of original |
59 | * request) (ignored on send) | 59 | * request) (ignored on send) |
60 | * @timeout_ms - Milliseconds to wait for response (unset on receive) | 60 | * @timeout_ms - Milliseconds to wait for response (unset on receive) |
61 | * @retries - Number of automatic retries to attempt | ||
61 | * @qpn - Remote QP number received from/to be sent to | 62 | * @qpn - Remote QP number received from/to be sent to |
62 | * @qkey - Remote Q_Key to be sent with (unset on receive) | 63 | * @qkey - Remote Q_Key to be sent with (unset on receive) |
63 | * @lid - Remote lid received from/to be sent to | 64 | * @lid - Remote lid received from/to be sent to |
@@ -72,11 +73,12 @@ | |||
72 | * | 73 | * |
73 | * All multi-byte quantities are stored in network (big endian) byte order. | 74 | * All multi-byte quantities are stored in network (big endian) byte order. |
74 | */ | 75 | */ |
75 | struct ib_user_mad { | 76 | struct ib_user_mad_hdr { |
76 | __u8 data[256]; | ||
77 | __u32 id; | 77 | __u32 id; |
78 | __u32 status; | 78 | __u32 status; |
79 | __u32 timeout_ms; | 79 | __u32 timeout_ms; |
80 | __u32 retries; | ||
81 | __u32 length; | ||
80 | __u32 qpn; | 82 | __u32 qpn; |
81 | __u32 qkey; | 83 | __u32 qkey; |
82 | __u16 lid; | 84 | __u16 lid; |
@@ -91,6 +93,17 @@ struct ib_user_mad { | |||
91 | }; | 93 | }; |
92 | 94 | ||
93 | /** | 95 | /** |
96 | * ib_user_mad - MAD packet | ||
97 | * @hdr - MAD packet header | ||
98 | * @data - Contents of MAD | ||
99 | * | ||
100 | */ | ||
101 | struct ib_user_mad { | ||
102 | struct ib_user_mad_hdr hdr; | ||
103 | __u8 data[0]; | ||
104 | }; | ||
105 | |||
106 | /** | ||
94 | * ib_user_mad_reg_req - MAD registration request | 107 | * ib_user_mad_reg_req - MAD registration request |
95 | * @id - Set by the kernel; used to identify agent in future requests. | 108 | * @id - Set by the kernel; used to identify agent in future requests. |
96 | * @qpn - Queue pair number; must be 0 or 1. | 109 | * @qpn - Queue pair number; must be 0 or 1. |
@@ -103,6 +116,8 @@ struct ib_user_mad { | |||
103 | * management class to receive. | 116 | * management class to receive. |
104 | * @oui: Indicates IEEE OUI when mgmt_class is a vendor class | 117 | * @oui: Indicates IEEE OUI when mgmt_class is a vendor class |
105 | * in the range from 0x30 to 0x4f. Otherwise not used. | 118 | * in the range from 0x30 to 0x4f. Otherwise not used. |
119 | * @rmpp_version: If set, indicates the RMPP version used. | ||
120 | * | ||
106 | */ | 121 | */ |
107 | struct ib_user_mad_reg_req { | 122 | struct ib_user_mad_reg_req { |
108 | __u32 id; | 123 | __u32 id; |
@@ -111,6 +126,7 @@ struct ib_user_mad_reg_req { | |||
111 | __u8 mgmt_class; | 126 | __u8 mgmt_class; |
112 | __u8 mgmt_class_version; | 127 | __u8 mgmt_class_version; |
113 | __u8 oui[3]; | 128 | __u8 oui[3]; |
129 | __u8 rmpp_version; | ||
114 | }; | 130 | }; |
115 | 131 | ||
116 | #define IB_IOCTL_MAGIC 0x1b | 132 | #define IB_IOCTL_MAGIC 0x1b |