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
b=19427 correct lmm_object_id and reserve fids for fid-on-OST.
[fs/lustre-release.git]
/
lustre
/
obdfilter
/
filter_capa.c
diff --git
a/lustre/obdfilter/filter_capa.c
b/lustre/obdfilter/filter_capa.c
index
ed35959
..
d99357e
100644
(file)
--- a/
lustre/obdfilter/filter_capa.c
+++ b/
lustre/obdfilter/filter_capa.c
@@
-64,7
+64,7
@@
int filter_update_capa_key(struct obd_device *obd, struct lustre_capa_key *new)
cfs_spin_lock(&capa_lock);
cfs_list_for_each_entry(k, &filter->fo_capa_keys, k_list) {
cfs_spin_lock(&capa_lock);
cfs_list_for_each_entry(k, &filter->fo_capa_keys, k_list) {
- if (k->k_key.lk_
mdsid != new->lk_mdsid
)
+ if (k->k_key.lk_
seq != new->lk_seq
)
continue;
if (keys[0]) {
continue;
if (keys[0]) {
@@
-112,7
+112,7
@@
int filter_update_capa_key(struct obd_device *obd, struct lustre_capa_key *new)
RETURN(0);
}
RETURN(0);
}
-int filter_auth_capa(struct obd_export *exp, struct lu_fid *fid, obd_
gr group
,
+int filter_auth_capa(struct obd_export *exp, struct lu_fid *fid, obd_
seq seq
,
struct lustre_capa *capa, __u64 opc)
{
struct obd_device *obd = exp->exp_obd;
struct lustre_capa *capa, __u64 opc)
{
struct obd_device *obd = exp->exp_obd;
@@
-120,13
+120,12
@@
int filter_auth_capa(struct obd_export *exp, struct lu_fid *fid, obd_gr group,
struct filter_capa_key *k;
struct lustre_capa_key key;
struct obd_capa *oc;
struct filter_capa_key *k;
struct lustre_capa_key key;
struct obd_capa *oc;
- __u64 mdsid;
__u8 *hmac;
int keys_ready = 0, key_found = 0, rc = 0;
ENTRY;
/* skip capa check for llog and obdecho */
__u8 *hmac;
int keys_ready = 0, key_found = 0, rc = 0;
ENTRY;
/* skip capa check for llog and obdecho */
- if (!fi
lter_group_is_mds(group
))
+ if (!fi
d_seq_is_mdt(seq
))
RETURN(0);
/* capability is disabled */
RETURN(0);
/* capability is disabled */
@@
-136,16
+135,15
@@
int filter_auth_capa(struct obd_export *exp, struct lu_fid *fid, obd_gr group,
if (!(exp->exp_connect_flags & OBD_CONNECT_OSS_CAPA))
RETURN(0);
if (!(exp->exp_connect_flags & OBD_CONNECT_OSS_CAPA))
RETURN(0);
- mdsid = objgrp_to_mdsno(group);
if (capa == NULL) {
if (fid)
if (capa == NULL) {
if (fid)
- CERROR("
mdsno
/fid/opc "LPU64"/"DFID"/"LPX64
+ CERROR("
seq
/fid/opc "LPU64"/"DFID"/"LPX64
": no capability has been passed\n",
": no capability has been passed\n",
-
mdsid
, PFID(fid), opc);
+
seq
, PFID(fid), opc);
else
else
- CERROR("
mdsno
/opc "LPU64"/"LPX64
+ CERROR("
seq
/opc "LPU64"/"LPX64
": no capability has been passed\n",
": no capability has been passed\n",
-
mdsid
, opc);
+
seq
, opc);
RETURN(-EACCES);
}
RETURN(-EACCES);
}
@@
-180,7
+178,7
@@
int filter_auth_capa(struct obd_export *exp, struct lu_fid *fid, obd_gr group,
cfs_spin_lock(&capa_lock);
cfs_list_for_each_entry(k, &filter->fo_capa_keys, k_list) {
cfs_spin_lock(&capa_lock);
cfs_list_for_each_entry(k, &filter->fo_capa_keys, k_list) {
- if (k->k_key.lk_
mdsid == mdsid
) {
+ if (k->k_key.lk_
seq == seq
) {
keys_ready = 1;
if (k->k_key.lk_keyid == capa_keyid(capa)) {
key = k->k_key;
keys_ready = 1;
if (k->k_key.lk_keyid == capa_keyid(capa)) {
key = k->k_key;
@@
-227,15
+225,14
@@
int filter_auth_capa(struct obd_export *exp, struct lu_fid *fid, obd_gr group,
RETURN(0);
}
RETURN(0);
}
-int filter_capa_fixoa(struct obd_export *exp, struct obdo *oa, obd_
gr group
,
+int filter_capa_fixoa(struct obd_export *exp, struct obdo *oa, obd_
seq seq
,
struct lustre_capa *capa)
{
struct lustre_capa *capa)
{
- __u64 mdsid;
int rc = 0;
ENTRY;
/* skip capa check for llog and obdecho */
int rc = 0;
ENTRY;
/* skip capa check for llog and obdecho */
- if (!fi
lter_group_is_mds(group
))
+ if (!fi
d_seq_is_mdt(seq
))
RETURN(0);
if (!(exp->exp_connect_flags & OBD_CONNECT_OSS_CAPA))
RETURN(0);
if (!(exp->exp_connect_flags & OBD_CONNECT_OSS_CAPA))
@@
-244,7
+241,6
@@
int filter_capa_fixoa(struct obd_export *exp, struct obdo *oa, obd_gr group,
if (unlikely(!capa))
RETURN(-EACCES);
if (unlikely(!capa))
RETURN(-EACCES);
- mdsid = objgrp_to_mdsno(group);
if (capa_flags(capa) == LC_ID_CONVERT) {
struct obd_device *obd = exp->exp_obd;
struct filter_obd *filter = &obd->u.filter;
if (capa_flags(capa) == LC_ID_CONVERT) {
struct obd_device *obd = exp->exp_obd;
struct filter_obd *filter = &obd->u.filter;
@@
-253,7
+249,7
@@
int filter_capa_fixoa(struct obd_export *exp, struct obdo *oa, obd_gr group,
cfs_spin_lock(&capa_lock);
cfs_list_for_each_entry(k, &filter->fo_capa_keys, k_list) {
cfs_spin_lock(&capa_lock);
cfs_list_for_each_entry(k, &filter->fo_capa_keys, k_list) {
- if (k->k_key.lk_
mdsid == mdsid
&&
+ if (k->k_key.lk_
seq == seq
&&
k->k_key.lk_keyid == capa_keyid(capa)) {
found = 1;
break;
k->k_key.lk_keyid == capa_keyid(capa)) {
found = 1;
break;