/usr/src/kernel-patches/lustre/patches/nfs-cifs-intent-2.6-suse.patch is in linux-patch-lustre 1.8.5+dfsg-3ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 | Index: linux-2.6.5-7.108/fs/nfs/dir.c
===================================================================
--- linux-2.6.5-7.108.orig/fs/nfs/dir.c 2004-09-15 19:26:43.012732408 +0300
+++ linux-2.6.5-7.108/fs/nfs/dir.c 2004-09-15 20:03:32.882781096 +0300
@@ -709,7 +709,7 @@
return 0;
if (!nd || (nd->flags & LOOKUP_CONTINUE) || !(nd->flags & LOOKUP_CREATE))
return 0;
- return (nd->intent.open.flags & O_EXCL) != 0;
+ return (nd->intent.it_flags & O_EXCL) != 0;
}
static struct dentry *nfs_lookup(struct inode *dir, struct dentry * dentry, struct nameidata *nd)
@@ -782,7 +782,7 @@
if (nd->flags & LOOKUP_DIRECTORY)
return 0;
/* Are we trying to write to a read only partition? */
- if (IS_RDONLY(dir) && (nd->intent.open.flags & (O_CREAT|O_TRUNC|FMODE_WRITE)))
+ if (IS_RDONLY(dir) && (nd->intent.it_flags & (O_CREAT|O_TRUNC|FMODE_WRITE)))
return 0;
return 1;
}
@@ -803,7 +803,7 @@
dentry->d_op = NFS_PROTO(dir)->dentry_ops;
/* Let vfs_create() deal with O_EXCL */
- if (nd->intent.open.flags & O_EXCL)
+ if (nd->intent.it_flags & O_EXCL)
goto no_entry;
/* Open the file on the server */
@@ -811,7 +811,7 @@
/* Revalidate parent directory attribute cache */
nfs_revalidate_inode(NFS_SERVER(dir), dir);
- if (nd->intent.open.flags & O_CREAT) {
+ if (nd->intent.it_flags & O_CREAT) {
nfs_begin_data_update(dir);
inode = nfs4_atomic_open(dir, dentry, nd);
nfs_end_data_update(dir);
@@ -827,7 +827,7 @@
break;
/* This turned out not to be a regular file */
case -ELOOP:
- if (!(nd->intent.open.flags & O_NOFOLLOW))
+ if (!(nd->intent.it_flags & O_NOFOLLOW))
goto no_open;
/* case -EISDIR: */
/* case -EINVAL: */
@@ -861,7 +861,7 @@
dir = parent->d_inode;
if (!is_atomic_open(dir, nd))
goto no_open;
- openflags = nd->intent.open.flags;
+ openflags = nd->intent.it_flags;
if (openflags & O_CREAT) {
/* If this is a negative dentry, just drop it */
if (!inode)
@@ -1026,7 +1026,7 @@
attr.ia_valid = ATTR_MODE;
if (nd && (nd->flags & LOOKUP_CREATE))
- open_flags = nd->intent.open.flags;
+ open_flags = nd->intent.it_flags;
/*
* The 0 argument passed into the create function should one day
Index: linux-2.6.5-7.108/fs/nfs/nfs4proc.c
===================================================================
--- linux-2.6.5-7.108.orig/fs/nfs/nfs4proc.c 2004-04-04 06:37:39.000000000 +0300
+++ linux-2.6.5-7.108/fs/nfs/nfs4proc.c 2004-09-15 20:03:32.885780640 +0300
@@ -792,17 +792,17 @@
struct nfs4_state *state;
if (nd->flags & LOOKUP_CREATE) {
- attr.ia_mode = nd->intent.open.create_mode;
+ attr.ia_mode = nd->intent.it_create_mode;
attr.ia_valid = ATTR_MODE;
if (!IS_POSIXACL(dir))
attr.ia_mode &= ~current->fs->umask;
} else {
attr.ia_valid = 0;
- BUG_ON(nd->intent.open.flags & O_CREAT);
+ BUG_ON(nd->intent.it_flags & O_CREAT);
}
cred = rpcauth_lookupcred(NFS_SERVER(dir)->client->cl_auth, 0);
- state = nfs4_do_open(dir, &dentry->d_name, nd->intent.open.flags, &attr, cred);
+ state = nfs4_do_open(dir, &dentry->d_name, nd->intent.it_flags, &attr, cred);
put_rpccred(cred);
if (IS_ERR(state))
return (struct inode *)state;
Index: linux-2.6.5-7.108/fs/cifs/dir.c
===================================================================
--- linux-2.6.5-7.108.orig/fs/cifs/dir.c 2004-09-04 13:28:22.000000000 +0300
+++ linux-2.6.5-7.108/fs/cifs/dir.c 2004-09-15 20:03:40.065689128 +0300
@@ -173,23 +173,23 @@
}
if(nd) {
- if ((nd->intent.open.flags & O_ACCMODE) == O_RDONLY)
+ if ((nd->intent.it_flags & O_ACCMODE) == O_RDONLY)
desiredAccess = GENERIC_READ;
- else if ((nd->intent.open.flags & O_ACCMODE) == O_WRONLY) {
+ else if ((nd->intent.it_flags & O_ACCMODE) == O_WRONLY) {
desiredAccess = GENERIC_WRITE;
write_only = TRUE;
- } else if ((nd->intent.open.flags & O_ACCMODE) == O_RDWR) {
+ } else if ((nd->intent.it_flags & O_ACCMODE) == O_RDWR) {
/* GENERIC_ALL is too much permission to request */
/* can cause unnecessary access denied on create */
/* desiredAccess = GENERIC_ALL; */
desiredAccess = GENERIC_READ | GENERIC_WRITE;
}
- if((nd->intent.open.flags & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL))
+ if((nd->intent.it_flags & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL))
disposition = FILE_CREATE;
- else if((nd->intent.open.flags & (O_CREAT | O_TRUNC)) == (O_CREAT | O_TRUNC))
+ else if((nd->intent.it_flags & (O_CREAT | O_TRUNC)) == (O_CREAT | O_TRUNC))
disposition = FILE_OVERWRITE_IF;
- else if((nd->intent.open.flags & O_CREAT) == O_CREAT)
+ else if((nd->intent.it_flags & O_CREAT) == O_CREAT)
disposition = FILE_OPEN_IF;
else {
cFYI(1,("Create flag not set in create function"));
@@ -359,7 +359,7 @@
parent_dir_inode, direntry->d_name.name, direntry));
if(nd) { /* BB removeme */
- cFYI(1,("In lookup nd flags 0x%x open intent flags 0x%x",nd->flags,nd->intent.open.flags));
+ cFYI(1,("In lookup nd flags 0x%x open intent flags 0x%x",nd->flags,nd->intent.it_flags));
} /* BB removeme BB */
/* BB Add check of incoming data - e.g. frame not longer than maximum SMB - let server check the namelen BB */
|