From d76b0d9b2d87cfc95686e148767cbf7d0e22bdc0 Mon Sep 17 00:00:00 2001 From: David Howells Date: Fri, 14 Nov 2008 10:39:25 +1100 Subject: CRED: Use creds in file structs Attach creds to file structs and discard f_uid/f_gid. file_operations::open() methods (such as hppfs_open()) should use file->f_cred rather than current_cred(). At the moment file->f_cred will be current_cred() at this point. Signed-off-by: David Howells Reviewed-by: James Morris Signed-off-by: James Morris --- fs/coda/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fs/coda/file.c') diff --git a/fs/coda/file.c b/fs/coda/file.c index 29137ff3ca6..5a876998549 100644 --- a/fs/coda/file.c +++ b/fs/coda/file.c @@ -174,7 +174,7 @@ int coda_release(struct inode *coda_inode, struct file *coda_file) BUG_ON(!cfi || cfi->cfi_magic != CODA_MAGIC); err = venus_close(coda_inode->i_sb, coda_i2f(coda_inode), - coda_flags, coda_file->f_uid); + coda_flags, coda_file->f_cred->fsuid); host_inode = cfi->cfi_container->f_path.dentry->d_inode; cii = ITOC(coda_inode); -- cgit From 7596b27dbd8de7bcfa7a80b2756114b49bd5c018 Mon Sep 17 00:00:00 2001 From: Randy Dunlap Date: Wed, 19 Nov 2008 11:30:27 -0800 Subject: coda: fix creds reference Needs a header file for credentials struct: linux-next-20081023/fs/coda/file.c:177: error: dereferencing pointer to incomplete type Signed-off-by: Randy Dunlap Cc: Jan Harkes Cc: David Howells Cc: James Morris Signed-off-by: Andrew Morton Signed-off-by: James Morris --- fs/coda/file.c | 1 + 1 file changed, 1 insertion(+) (limited to 'fs/coda/file.c') diff --git a/fs/coda/file.c b/fs/coda/file.c index 5a876998549..466303db2df 100644 --- a/fs/coda/file.c +++ b/fs/coda/file.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include -- cgit