diff options
Diffstat (limited to 'include/net/9p/client.h')
| -rw-r--r-- | include/net/9p/client.h | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/include/net/9p/client.h b/include/net/9p/client.h index fb00b329f0d3..f076dfa75ae8 100644 --- a/include/net/9p/client.h +++ b/include/net/9p/client.h | |||
| @@ -29,6 +29,19 @@ | |||
| 29 | /* Number of requests per row */ | 29 | /* Number of requests per row */ |
| 30 | #define P9_ROW_MAXTAG 255 | 30 | #define P9_ROW_MAXTAG 255 |
| 31 | 31 | ||
| 32 | /** enum p9_proto_versions - 9P protocol versions | ||
| 33 | * @p9_proto_legacy: 9P Legacy mode, pre-9P2000.u | ||
| 34 | * @p9_proto_2000u: 9P2000.u extension | ||
| 35 | * @p9_proto_2000L: 9P2000.L extension | ||
| 36 | */ | ||
| 37 | |||
| 38 | enum p9_proto_versions{ | ||
| 39 | p9_proto_legacy = 0, | ||
| 40 | p9_proto_2000u = 1, | ||
| 41 | p9_proto_2000L = 2, | ||
| 42 | }; | ||
| 43 | |||
| 44 | |||
| 32 | /** | 45 | /** |
| 33 | * enum p9_trans_status - different states of underlying transports | 46 | * enum p9_trans_status - different states of underlying transports |
| 34 | * @Connected: transport is connected and healthy | 47 | * @Connected: transport is connected and healthy |
| @@ -111,6 +124,7 @@ struct p9_req_t { | |||
| 111 | * @lock: protect @fidlist | 124 | * @lock: protect @fidlist |
| 112 | * @msize: maximum data size negotiated by protocol | 125 | * @msize: maximum data size negotiated by protocol |
| 113 | * @dotu: extension flags negotiated by protocol | 126 | * @dotu: extension flags negotiated by protocol |
| 127 | * @proto_version: 9P protocol version to use | ||
| 114 | * @trans_mod: module API instantiated with this client | 128 | * @trans_mod: module API instantiated with this client |
| 115 | * @trans: tranport instance state and API | 129 | * @trans: tranport instance state and API |
| 116 | * @conn: connection state information used by trans_fd | 130 | * @conn: connection state information used by trans_fd |
| @@ -137,7 +151,7 @@ struct p9_req_t { | |||
| 137 | struct p9_client { | 151 | struct p9_client { |
| 138 | spinlock_t lock; /* protect client structure */ | 152 | spinlock_t lock; /* protect client structure */ |
| 139 | int msize; | 153 | int msize; |
| 140 | unsigned char dotu; | 154 | unsigned char proto_version; |
| 141 | struct p9_trans_module *trans_mod; | 155 | struct p9_trans_module *trans_mod; |
| 142 | enum p9_trans_status status; | 156 | enum p9_trans_status status; |
| 143 | void *trans; | 157 | void *trans; |
| @@ -209,5 +223,7 @@ int p9_parse_header(struct p9_fcall *, int32_t *, int8_t *, int16_t *, int); | |||
| 209 | int p9stat_read(char *, int, struct p9_wstat *, int); | 223 | int p9stat_read(char *, int, struct p9_wstat *, int); |
| 210 | void p9stat_free(struct p9_wstat *); | 224 | void p9stat_free(struct p9_wstat *); |
| 211 | 225 | ||
| 226 | int p9_is_proto_dotu(struct p9_client *clnt); | ||
| 227 | int p9_is_proto_dotl(struct p9_client *clnt); | ||
| 212 | 228 | ||
| 213 | #endif /* NET_9P_CLIENT_H */ | 229 | #endif /* NET_9P_CLIENT_H */ |
