diff options
author | Sripathi Kodi <sripathik@in.ibm.com> | 2010-03-17 13:02:38 -0400 |
---|---|---|
committer | Eric Van Hensbergen <ericvh@gmail.com> | 2010-04-05 11:37:36 -0400 |
commit | 476ada0436351672fbf482db54cb94b8ba877709 (patch) | |
tree | 21228cf96fdee32f1c63cc7b31d6764935617ec7 /fs/9p | |
parent | db217dece3003df0841bacf9556b5c06aa097dae (diff) |
9p: Fix setting of protocol flags in v9fs_session_info structure.
This patch fixes a simple bug I left behind in my earlier protocol
negotiation patch.
Thanks,
Sripathi.
Signed-off-by: Sripathi Kodi <sripathik@in.ibm.com>
Signed-off-by: Eric Van Hensbergen <ericvh@gmail.com>
Diffstat (limited to 'fs/9p')
-rw-r--r-- | fs/9p/v9fs.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c index 6c7f6a251115..2f814cf0c731 100644 --- a/fs/9p/v9fs.c +++ b/fs/9p/v9fs.c | |||
@@ -241,7 +241,7 @@ struct p9_fid *v9fs_session_init(struct v9fs_session_info *v9ses, | |||
241 | list_add(&v9ses->slist, &v9fs_sessionlist); | 241 | list_add(&v9ses->slist, &v9fs_sessionlist); |
242 | spin_unlock(&v9fs_sessionlist_lock); | 242 | spin_unlock(&v9fs_sessionlist_lock); |
243 | 243 | ||
244 | v9ses->flags = V9FS_PROTO_2000U | V9FS_ACCESS_USER; | 244 | v9ses->flags = V9FS_ACCESS_USER; |
245 | strcpy(v9ses->uname, V9FS_DEFUSER); | 245 | strcpy(v9ses->uname, V9FS_DEFUSER); |
246 | strcpy(v9ses->aname, V9FS_DEFANAME); | 246 | strcpy(v9ses->aname, V9FS_DEFANAME); |
247 | v9ses->uid = ~0; | 247 | v9ses->uid = ~0; |
@@ -262,8 +262,10 @@ struct p9_fid *v9fs_session_init(struct v9fs_session_info *v9ses, | |||
262 | goto error; | 262 | goto error; |
263 | } | 263 | } |
264 | 264 | ||
265 | if (!p9_is_proto_dotu(v9ses->clnt)) | 265 | if (p9_is_proto_dotl(v9ses->clnt)) |
266 | v9ses->flags &= ~V9FS_PROTO_2000U; | 266 | v9ses->flags |= V9FS_PROTO_2000L; |
267 | else if (p9_is_proto_dotu(v9ses->clnt)) | ||
268 | v9ses->flags |= V9FS_PROTO_2000U; | ||
267 | 269 | ||
268 | v9ses->maxdata = v9ses->clnt->msize - P9_IOHDRSZ; | 270 | v9ses->maxdata = v9ses->clnt->msize - P9_IOHDRSZ; |
269 | 271 | ||