Commit c56e4acf authored by Sripathi Kodi's avatar Sripathi Kodi Committed by Eric Van Hensbergen

9p: VFS switches for 9p2000.L: protocol and client changes

Prepare p9pdu_read/write functions to handle multiple protocols.
Signed-off-by: default avatarSripathi Kodi <sripathik@in.ibm.com>
Signed-off-by: default avatarEric Van Hensbergen <ericvh@gmail.com>
parent d515e86e
...@@ -1321,7 +1321,8 @@ static int p9_client_statsize(struct p9_wstat *wst, int proto_version) ...@@ -1321,7 +1321,8 @@ static int p9_client_statsize(struct p9_wstat *wst, int proto_version)
if (wst->muid) if (wst->muid)
ret += strlen(wst->muid); ret += strlen(wst->muid);
if (proto_version == p9_proto_2000u) { if ((proto_version == p9_proto_2000u) ||
(proto_version == p9_proto_2000L)) {
ret += 2+4+4+4; /* extension[s] n_uid[4] n_gid[4] n_muid[4] */ ret += 2+4+4+4; /* extension[s] n_uid[4] n_gid[4] n_muid[4] */
if (wst->extension) if (wst->extension)
ret += strlen(wst->extension); ret += strlen(wst->extension);
......
...@@ -341,7 +341,8 @@ p9pdu_vreadf(struct p9_fcall *pdu, int proto_version, const char *fmt, ...@@ -341,7 +341,8 @@ p9pdu_vreadf(struct p9_fcall *pdu, int proto_version, const char *fmt,
} }
break; break;
case '?': case '?':
if (proto_version != p9_proto_2000u) if ((proto_version != p9_proto_2000u) &&
(proto_version != p9_proto_2000L))
return 0; return 0;
break; break;
default: default:
...@@ -488,7 +489,8 @@ p9pdu_vwritef(struct p9_fcall *pdu, int proto_version, const char *fmt, ...@@ -488,7 +489,8 @@ p9pdu_vwritef(struct p9_fcall *pdu, int proto_version, const char *fmt,
} }
break; break;
case '?': case '?':
if (proto_version != p9_proto_2000u) if ((proto_version != p9_proto_2000u) &&
(proto_version != p9_proto_2000L))
return 0; return 0;
break; break;
default: default:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment