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
file export-do_kern_mount.patch was initially added on branch b1_5.
[fs/lustre-release.git]
/
lustre
/
ptlbd
/
client.c
diff --git
a/lustre/ptlbd/client.c
b/lustre/ptlbd/client.c
index
6a1d759
..
c44f955
100644
(file)
--- a/
lustre/ptlbd/client.c
+++ b/
lustre/ptlbd/client.c
@@
-55,17
+55,17
@@
static int ptlbd_cl_setup(struct obd_device *obd, obd_count len, void *buf)
if (ptlbd->bd_import != NULL)
RETURN(-EALREADY);
if (ptlbd->bd_import != NULL)
RETURN(-EALREADY);
- if (
lcfg->lcfg_inllen1
< 1) {
+ if (
LUSTRE_CFG_BUFLEN(lcfg, 1)
< 1) {
CERROR("requires a PTLBD server UUID\n");
RETURN(-EINVAL);
}
CERROR("requires a PTLBD server UUID\n");
RETURN(-EINVAL);
}
- if (
lcfg->lcfg_inllen1
> 37) {
+ if (
LUSTRE_CFG_BUFLEN(lcfg, 1)
> 37) {
CERROR("PTLBD server UUID must be less than 38 characters\n");
RETURN(-EINVAL);
}
CERROR("PTLBD server UUID must be less than 38 characters\n");
RETURN(-EINVAL);
}
- obd_str2uuid(&ptlbd->bd_server_uuid, l
cfg->lcfg_inlbuf1
);
+ obd_str2uuid(&ptlbd->bd_server_uuid, l
ustre_cfg_string(lcfg, 1)
);
/*
* from client_obd_connect.. *shrug*
/*
* from client_obd_connect.. *shrug*
@@
-83,8
+83,8
@@
static int ptlbd_cl_setup(struct obd_device *obd, obd_count len, void *buf)
"ptlbd", &ptlbd->bd_client);
imp->imp_client = &ptlbd->bd_client;
imp->imp_obd = obd;
"ptlbd", &ptlbd->bd_client);
imp->imp_client = &ptlbd->bd_client;
imp->imp_obd = obd;
- memcpy(imp->imp_target_uuid.uuid, l
cfg->lcfg_inlbuf1
,
-
lcfg->lcfg_inllen1
);
+ memcpy(imp->imp_target_uuid.uuid, l
ustre_cfg_string(lcfg, 1)
,
+
LUSTRE_CFG_BUFLEN(lcfg, 1)
);
ptlbd_blk_register(ptlbd);
RETURN(0);
ptlbd_blk_register(ptlbd);
RETURN(0);
@@
-166,19
+166,20
@@
out_disco:
/* modelled after ptlrpc_import_disconnect() */
/* modelled after ptlrpc_import_disconnect() */
-int ptlbd_cl_disconnect(struct obd_export *exp,
int
flags)
+int ptlbd_cl_disconnect(struct obd_export *exp,
unsigned long
flags)
{
struct obd_device *obd = exp->exp_obd;
struct ptlbd_obd *ptlbd = &obd->u.ptlbd;
struct obd_import *imp = ptlbd->bd_import;
struct ptlrpc_request *request;
{
struct obd_device *obd = exp->exp_obd;
struct ptlbd_obd *ptlbd = &obd->u.ptlbd;
struct obd_import *imp = ptlbd->bd_import;
struct ptlrpc_request *request;
- int rc, err;
+ int
rc, err;
ENTRY;
if (!obd)
RETURN(-EINVAL);
ENTRY;
if (!obd)
RETURN(-EINVAL);
- request = ptlrpc_prep_req(imp, LUSTRE_PBD_VERSION, PTLBD_DISCONNECT,
+ request = ptlrpc_prep_req(imp, LUSTRE_PBD_VERSION,
+ PTLBD_DISCONNECT,
0, NULL, NULL);
if (!request)
GOTO(out_req, rc = -ENOMEM);
0, NULL, NULL);
if (!request)
GOTO(out_req, rc = -ENOMEM);
@@
-235,7
+236,7
@@
int ptlbd_do_connect(struct ptlbd_obd *ptlbd)
ENTRY;
memset(&conn, 0, sizeof(conn));
ENTRY;
memset(&conn, 0, sizeof(conn));
- rc = obd_connect(&conn, obd, &ptlbd->bd_server_uuid, 0);
+ rc = obd_connect(&conn, obd, &ptlbd->bd_server_uuid,
NULL,
0);
if (rc < 0)
RETURN(rc);
ptlbd->bd_exp = class_conn2export(&conn);
if (rc < 0)
RETURN(rc);
ptlbd->bd_exp = class_conn2export(&conn);