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
LU-3557 mdt: fix open existing file with O_CREAT for ro mount
[fs/lustre-release.git]
/
lustre
/
mdt
/
mdt_handler.c
diff --git
a/lustre/mdt/mdt_handler.c
b/lustre/mdt/mdt_handler.c
index
15f6c4b
..
0de83de
100644
(file)
--- a/
lustre/mdt/mdt_handler.c
+++ b/
lustre/mdt/mdt_handler.c
@@
-3537,7
+3537,14
@@
static struct mdt_it_flavor {
},
[MDT_IT_OCREAT] = {
.it_fmt = &RQF_LDLM_INTENT,
},
[MDT_IT_OCREAT] = {
.it_fmt = &RQF_LDLM_INTENT,
- .it_flags = MUTABOR,
+ /*
+ * OCREAT is not a MUTABOR request as if the file
+ * already exists.
+ * We do the extra check of OBD_CONNECT_RDONLY in
+ * mdt_reint_open() when we really need to create
+ * the object.
+ */
+ .it_flags = 0,
.it_act = mdt_intent_reint,
.it_reint = REINT_OPEN
},
.it_act = mdt_intent_reint,
.it_reint = REINT_OPEN
},