Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
- fixes to the MDS: it now answers requests from the request test
[fs/lustre-release.git]
/
lustre
/
lib
/
mds_pack.c
diff --git
a/lustre/lib/mds_pack.c
b/lustre/lib/mds_pack.c
index
da1c3dd
..
88d8188
100644
(file)
--- a/
lustre/lib/mds_pack.c
+++ b/
lustre/lib/mds_pack.c
@@
-56,7
+56,7
@@
int mds_pack_req(char *name, int namelen, char *tgt, int tgtlen,
{
char *ptr;
- *len = sizeof(**hdr) + size_round(namelen) + sizeround(tgtlen) +
+ *len = sizeof(**hdr) + size_round(namelen) + size
_
round(tgtlen) +
sizeof(**req);
*buf = kmalloc(*len, GFP_KERNEL);
@@
-72,12
+72,12
@@
int mds_pack_req(char *name, int namelen, char *tgt, int tgtlen,
(*hdr)->type = MDS_TYPE_REQ;
- (*req)->namelen = NTOH_u32(namelen);
+ (*req)->namelen = NTOH_
_
u32(namelen);
if (name) {
LOGL(name, namelen, ptr);
}
- (*req)->tgtlen = NTOH_u32(tgtlen);
+ (*req)->tgtlen = NTOH_
_
u32(tgtlen);
if (tgt) {
LOGL(tgt, tgtlen, ptr);
}
@@
-95,8
+95,8
@@
int mds_unpack_req(char *buf, int len,
*hdr = (struct mds_req_hdr *) (buf);
*req = (struct mds_req *) (buf + sizeof(**hdr));
- (*req)->namelen = NTOH_u32((*req)->namelen);
- (*req)->tgtlen = NTOH_u32((*req)->namelen);
+ (*req)->namelen = NTOH_
_
u32((*req)->namelen);
+ (*req)->tgtlen = NTOH_
_
u32((*req)->namelen);
if (len < sizeof(**hdr) + sizeof(**req) + (*req)->namelen +
(*req)->tgtlen ) {
@@
-112,7
+112,7
@@
int mds_unpack_req(char *buf, int len,
if ((*req)->tgtlen) {
(*req)->tgt = buf + sizeof(**hdr) + sizeof(**req) +
- size
rount
((*req)->namelen);
+ size
_round
((*req)->namelen);
} else {
(*req)->tgt = NULL;
}
@@
-127,7
+127,7
@@
int mds_pack_rep(char *name, int namelen, char *tgt, int tgtlen,
{
char *ptr;
- *len = sizeof(**hdr) + size_round(namelen) + sizeround(tgtlen) +
+ *len = sizeof(**hdr) + size_round(namelen) + size
_
round(tgtlen) +
sizeof(**rep);
*buf = kmalloc(*len, GFP_KERNEL);
@@
-141,12
+141,12
@@
int mds_pack_rep(char *name, int namelen, char *tgt, int tgtlen,
*rep = (struct mds_rep *)(*buf + sizeof(**hdr));
ptr = *buf + sizeof(**hdr) + sizeof(**rep);
- (*rep)->namelen = NTOH_u32(namelen);
+ (*rep)->namelen = NTOH_
_
u32(namelen);
if (name) {
LOGL(name, namelen, ptr);
}
- (*rep)->tgtlen = NTOH_u32(tgtlen);
+ (*rep)->tgtlen = NTOH_
_
u32(tgtlen);
if (tgt) {
LOGL(tgt, tgtlen, ptr);
}
@@
-164,8
+164,8
@@
int mds_unpack_rep(char *buf, int len,
*hdr = (struct mds_rep_hdr *) (buf);
*rep = (struct mds_rep *) (buf + sizeof(**hdr));
- (*rep)->namelen = NTOH_u32((*rep)->namelen);
- (*rep)->tgtlen = NTOH_u32((*rep)->namelen);
+ (*rep)->namelen = NTOH_
_
u32((*rep)->namelen);
+ (*rep)->tgtlen = NTOH_
_
u32((*rep)->namelen);
if (len < sizeof(**hdr) + sizeof(**rep) + (*rep)->namelen +
(*rep)->tgtlen ) {
@@
-181,7
+181,7
@@
int mds_unpack_rep(char *buf, int len,
if ((*rep)->tgtlen) {
(*rep)->tgt = buf + sizeof(**hdr) + sizeof(**rep) +
- size
rount
((*rep)->namelen);
+ size
_round
((*rep)->namelen);
} else {
(*rep)->tgt = NULL;
}