Merge branch 'nfs-for-2.6.36' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6
* 'nfs-for-2.6.36' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6: (42 commits) NFS: NFSv4.1 is no longer a "developer only" feature NFS: NFS_V4 is no longer an EXPERIMENTAL feature NFS: Fix /proc/mount for legacy binary interface NFS: Fix the locking in nfs4_callback_getattr SUNRPC: Defer deleting the security context until gss_do_free_ctx() SUNRPC: prevent task_cleanup running on freed xprt SUNRPC: Reduce asynchronous RPC task stack usage SUNRPC: Move the bound cred to struct rpc_rqst SUNRPC: Clean up of rpc_bindcred() SUNRPC: Move remaining RPC client related task initialisation into clnt.c SUNRPC: Ensure that rpc_exit() always wakes up a sleeping task SUNRPC: Make the credential cache hashtable size configurable SUNRPC: Store the hashtable size in struct rpc_cred_cache NFS: Ensure the AUTH_UNIX credcache is allocated dynamically NFS: Fix the NFS users of rpc_restart_call() SUNRPC: The function rpc_restart_call() should return success/failure NFSv4: Get rid of the bogus RPC_ASSASSINATED(task) checks NFSv4: Clean up the process of renewing the NFSv4 lease NFSv4.1: Handle NFS4ERR_DELAY on SEQUENCE correctly NFS: nfs_rename() should not have to flush out writebacks ...
This commit is contained in:
@@ -523,6 +523,7 @@ enum {
|
||||
NFSPROC4_CLNT_GETACL,
|
||||
NFSPROC4_CLNT_SETACL,
|
||||
NFSPROC4_CLNT_FS_LOCATIONS,
|
||||
NFSPROC4_CLNT_RELEASE_LOCKOWNER,
|
||||
|
||||
/* nfs41 */
|
||||
NFSPROC4_CLNT_EXCHANGE_ID,
|
||||
|
||||
+11
-2
@@ -72,13 +72,20 @@ struct nfs_access_entry {
|
||||
int mask;
|
||||
};
|
||||
|
||||
struct nfs_lock_context {
|
||||
atomic_t count;
|
||||
struct list_head list;
|
||||
struct nfs_open_context *open_context;
|
||||
fl_owner_t lockowner;
|
||||
pid_t pid;
|
||||
};
|
||||
|
||||
struct nfs4_state;
|
||||
struct nfs_open_context {
|
||||
atomic_t count;
|
||||
struct nfs_lock_context lock_context;
|
||||
struct path path;
|
||||
struct rpc_cred *cred;
|
||||
struct nfs4_state *state;
|
||||
fl_owner_t lockowner;
|
||||
fmode_t mode;
|
||||
|
||||
unsigned long flags;
|
||||
@@ -353,6 +360,8 @@ extern void nfs_setattr_update_inode(struct inode *inode, struct iattr *attr);
|
||||
extern struct nfs_open_context *get_nfs_open_context(struct nfs_open_context *ctx);
|
||||
extern void put_nfs_open_context(struct nfs_open_context *ctx);
|
||||
extern struct nfs_open_context *nfs_find_open_context(struct inode *inode, struct rpc_cred *cred, fmode_t mode);
|
||||
extern struct nfs_lock_context *nfs_get_lock_context(struct nfs_open_context *ctx);
|
||||
extern void nfs_put_lock_context(struct nfs_lock_context *l_ctx);
|
||||
extern u64 nfs_compat_user_ino64(u64 fileid);
|
||||
extern void nfs_fattr_init(struct nfs_fattr *fattr);
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@ struct nlm_host;
|
||||
struct nfs4_sequence_args;
|
||||
struct nfs4_sequence_res;
|
||||
struct nfs_server;
|
||||
struct nfs4_minor_version_ops;
|
||||
|
||||
/*
|
||||
* The nfs_client identifies our client state to the server.
|
||||
@@ -70,11 +71,7 @@ struct nfs_client {
|
||||
*/
|
||||
char cl_ipaddr[48];
|
||||
unsigned char cl_id_uniquifier;
|
||||
int (* cl_call_sync)(struct nfs_server *server,
|
||||
struct rpc_message *msg,
|
||||
struct nfs4_sequence_args *args,
|
||||
struct nfs4_sequence_res *res,
|
||||
int cache_reply);
|
||||
const struct nfs4_minor_version_ops *cl_mvops;
|
||||
#endif /* CONFIG_NFS_V4 */
|
||||
|
||||
#ifdef CONFIG_NFS_V4_1
|
||||
|
||||
@@ -69,5 +69,6 @@ struct nfs_mount_data {
|
||||
#define NFS_MOUNT_LOOKUP_CACHE_NONEG 0x10000
|
||||
#define NFS_MOUNT_LOOKUP_CACHE_NONE 0x20000
|
||||
#define NFS_MOUNT_NORESVPORT 0x40000
|
||||
#define NFS_MOUNT_LEGACY_INTERFACE 0x80000
|
||||
|
||||
#endif
|
||||
|
||||
@@ -39,6 +39,7 @@ struct nfs_page {
|
||||
struct list_head wb_list; /* Defines state of page: */
|
||||
struct page *wb_page; /* page to read in/write out */
|
||||
struct nfs_open_context *wb_context; /* File state context info */
|
||||
struct nfs_lock_context *wb_lock_context; /* lock context info */
|
||||
atomic_t wb_complete; /* i/os we're waiting for */
|
||||
pgoff_t wb_index; /* Offset >> PAGE_CACHE_SHIFT */
|
||||
unsigned int wb_offset, /* Offset & ~PAGE_CACHE_MASK */
|
||||
|
||||
+10
-2
@@ -196,8 +196,10 @@ struct nfs_openargs {
|
||||
__u64 clientid;
|
||||
__u64 id;
|
||||
union {
|
||||
struct iattr * attrs; /* UNCHECKED, GUARDED */
|
||||
nfs4_verifier verifier; /* EXCLUSIVE */
|
||||
struct {
|
||||
struct iattr * attrs; /* UNCHECKED, GUARDED */
|
||||
nfs4_verifier verifier; /* EXCLUSIVE */
|
||||
};
|
||||
nfs4_stateid delegation; /* CLAIM_DELEGATE_CUR */
|
||||
fmode_t delegation_type; /* CLAIM_PREVIOUS */
|
||||
} u;
|
||||
@@ -313,6 +315,10 @@ struct nfs_lockt_res {
|
||||
struct nfs4_sequence_res seq_res;
|
||||
};
|
||||
|
||||
struct nfs_release_lockowner_args {
|
||||
struct nfs_lowner lock_owner;
|
||||
};
|
||||
|
||||
struct nfs4_delegreturnargs {
|
||||
const struct nfs_fh *fhandle;
|
||||
const nfs4_stateid *stateid;
|
||||
@@ -332,6 +338,7 @@ struct nfs4_delegreturnres {
|
||||
struct nfs_readargs {
|
||||
struct nfs_fh * fh;
|
||||
struct nfs_open_context *context;
|
||||
struct nfs_lock_context *lock_context;
|
||||
__u64 offset;
|
||||
__u32 count;
|
||||
unsigned int pgbase;
|
||||
@@ -352,6 +359,7 @@ struct nfs_readres {
|
||||
struct nfs_writeargs {
|
||||
struct nfs_fh * fh;
|
||||
struct nfs_open_context *context;
|
||||
struct nfs_lock_context *lock_context;
|
||||
__u64 offset;
|
||||
__u32 count;
|
||||
enum nfs3_stable_how stable;
|
||||
|
||||
@@ -61,13 +61,7 @@ struct rpc_cred {
|
||||
/*
|
||||
* Client authentication handle
|
||||
*/
|
||||
#define RPC_CREDCACHE_HASHBITS 4
|
||||
#define RPC_CREDCACHE_NR (1 << RPC_CREDCACHE_HASHBITS)
|
||||
struct rpc_cred_cache {
|
||||
struct hlist_head hashtable[RPC_CREDCACHE_NR];
|
||||
spinlock_t lock;
|
||||
};
|
||||
|
||||
struct rpc_cred_cache;
|
||||
struct rpc_authops;
|
||||
struct rpc_auth {
|
||||
unsigned int au_cslack; /* call cred size estimate */
|
||||
@@ -112,7 +106,7 @@ struct rpc_credops {
|
||||
void (*crdestroy)(struct rpc_cred *);
|
||||
|
||||
int (*crmatch)(struct auth_cred *, struct rpc_cred *, int);
|
||||
void (*crbind)(struct rpc_task *, struct rpc_cred *, int);
|
||||
struct rpc_cred * (*crbind)(struct rpc_task *, struct rpc_cred *, int);
|
||||
__be32 * (*crmarshal)(struct rpc_task *, __be32 *);
|
||||
int (*crrefresh)(struct rpc_task *);
|
||||
__be32 * (*crvalidate)(struct rpc_task *, __be32 *);
|
||||
@@ -125,11 +119,12 @@ struct rpc_credops {
|
||||
extern const struct rpc_authops authunix_ops;
|
||||
extern const struct rpc_authops authnull_ops;
|
||||
|
||||
void __init rpc_init_authunix(void);
|
||||
void __init rpc_init_generic_auth(void);
|
||||
void __init rpcauth_init_module(void);
|
||||
int __init rpc_init_authunix(void);
|
||||
int __init rpc_init_generic_auth(void);
|
||||
int __init rpcauth_init_module(void);
|
||||
void __exit rpcauth_remove_module(void);
|
||||
void __exit rpc_destroy_generic_auth(void);
|
||||
void rpc_destroy_authunix(void);
|
||||
|
||||
struct rpc_cred * rpc_lookup_cred(void);
|
||||
struct rpc_cred * rpc_lookup_machine_cred(void);
|
||||
@@ -140,10 +135,8 @@ void rpcauth_release(struct rpc_auth *);
|
||||
struct rpc_cred * rpcauth_lookup_credcache(struct rpc_auth *, struct auth_cred *, int);
|
||||
void rpcauth_init_cred(struct rpc_cred *, const struct auth_cred *, struct rpc_auth *, const struct rpc_credops *);
|
||||
struct rpc_cred * rpcauth_lookupcred(struct rpc_auth *, int);
|
||||
void rpcauth_bindcred(struct rpc_task *, struct rpc_cred *, int);
|
||||
void rpcauth_generic_bind_cred(struct rpc_task *, struct rpc_cred *, int);
|
||||
struct rpc_cred * rpcauth_generic_bind_cred(struct rpc_task *, struct rpc_cred *, int);
|
||||
void put_rpccred(struct rpc_cred *);
|
||||
void rpcauth_unbindcred(struct rpc_task *);
|
||||
__be32 * rpcauth_marshcred(struct rpc_task *, __be32 *);
|
||||
__be32 * rpcauth_checkverf(struct rpc_task *, __be32 *);
|
||||
int rpcauth_wrap_req(struct rpc_task *task, kxdrproc_t encode, void *rqstp, __be32 *data, void *obj);
|
||||
|
||||
@@ -131,6 +131,7 @@ struct rpc_clnt *rpc_bind_new_program(struct rpc_clnt *,
|
||||
struct rpc_clnt *rpc_clone_client(struct rpc_clnt *);
|
||||
void rpc_shutdown_client(struct rpc_clnt *);
|
||||
void rpc_release_client(struct rpc_clnt *);
|
||||
void rpc_task_release_client(struct rpc_task *);
|
||||
|
||||
int rpcb_register(u32, u32, int, unsigned short);
|
||||
int rpcb_v4_register(const u32 program, const u32 version,
|
||||
@@ -148,8 +149,8 @@ int rpc_call_sync(struct rpc_clnt *clnt,
|
||||
const struct rpc_message *msg, int flags);
|
||||
struct rpc_task *rpc_call_null(struct rpc_clnt *clnt, struct rpc_cred *cred,
|
||||
int flags);
|
||||
void rpc_restart_call_prepare(struct rpc_task *);
|
||||
void rpc_restart_call(struct rpc_task *);
|
||||
int rpc_restart_call_prepare(struct rpc_task *);
|
||||
int rpc_restart_call(struct rpc_task *);
|
||||
void rpc_setbufsize(struct rpc_clnt *, unsigned int, unsigned int);
|
||||
size_t rpc_max_payload(struct rpc_clnt *);
|
||||
void rpc_force_rebind(struct rpc_clnt *);
|
||||
|
||||
@@ -213,6 +213,7 @@ struct rpc_task *rpc_run_bc_task(struct rpc_rqst *req,
|
||||
const struct rpc_call_ops *ops);
|
||||
void rpc_put_task(struct rpc_task *);
|
||||
void rpc_exit_task(struct rpc_task *);
|
||||
void rpc_exit(struct rpc_task *, int);
|
||||
void rpc_release_calldata(const struct rpc_call_ops *, void *);
|
||||
void rpc_killall_tasks(struct rpc_clnt *);
|
||||
void rpc_execute(struct rpc_task *);
|
||||
@@ -241,12 +242,6 @@ void rpc_destroy_mempool(void);
|
||||
extern struct workqueue_struct *rpciod_workqueue;
|
||||
void rpc_prepare_task(struct rpc_task *task);
|
||||
|
||||
static inline void rpc_exit(struct rpc_task *task, int status)
|
||||
{
|
||||
task->tk_status = status;
|
||||
task->tk_action = rpc_exit_task;
|
||||
}
|
||||
|
||||
static inline int rpc_wait_for_completion_task(struct rpc_task *task)
|
||||
{
|
||||
return __rpc_wait_for_completion_task(task, NULL);
|
||||
|
||||
@@ -64,6 +64,7 @@ struct rpc_rqst {
|
||||
* This is the private part
|
||||
*/
|
||||
struct rpc_task * rq_task; /* RPC task data */
|
||||
struct rpc_cred * rq_cred; /* Bound cred */
|
||||
__be32 rq_xid; /* request XID */
|
||||
int rq_cong; /* has incremented xprt->cong */
|
||||
u32 rq_seqno; /* gss seq no. used on req. */
|
||||
|
||||
Reference in New Issue
Block a user