diff options
| author | Ingo Molnar <mingo@kernel.org> | 2013-01-24 06:47:48 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2013-01-24 06:47:48 -0500 |
| commit | befddb21c845f8fb49e637997891ef97c6a869dc (patch) | |
| tree | 0e7629123184f2dd50291ad6d477b894175f0f26 /fs/nfs/proc.c | |
| parent | e716efde75267eab919cdb2bef5b2cb77f305326 (diff) | |
| parent | 7d1f9aeff1ee4a20b1aeb377dd0f579fe9647619 (diff) | |
Merge tag 'v3.8-rc4' into irq/core
Merge Linux 3.8-rc4 before pulling in new commits - we were on an old v3.7 base.
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'fs/nfs/proc.c')
| -rw-r--r-- | fs/nfs/proc.c | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/fs/nfs/proc.c b/fs/nfs/proc.c index 50a88c3546ed..f084dac948e1 100644 --- a/fs/nfs/proc.c +++ b/fs/nfs/proc.c | |||
| @@ -47,39 +47,6 @@ | |||
| 47 | #define NFSDBG_FACILITY NFSDBG_PROC | 47 | #define NFSDBG_FACILITY NFSDBG_PROC |
| 48 | 48 | ||
| 49 | /* | 49 | /* |
| 50 | * wrapper to handle the -EKEYEXPIRED error message. This should generally | ||
| 51 | * only happen if using krb5 auth and a user's TGT expires. NFSv2 doesn't | ||
| 52 | * support the NFSERR_JUKEBOX error code, but we handle this situation in the | ||
| 53 | * same way that we handle that error with NFSv3. | ||
| 54 | */ | ||
| 55 | static int | ||
| 56 | nfs_rpc_wrapper(struct rpc_clnt *clnt, struct rpc_message *msg, int flags) | ||
| 57 | { | ||
| 58 | int res; | ||
| 59 | do { | ||
| 60 | res = rpc_call_sync(clnt, msg, flags); | ||
| 61 | if (res != -EKEYEXPIRED) | ||
| 62 | break; | ||
| 63 | freezable_schedule_timeout_killable(NFS_JUKEBOX_RETRY_TIME); | ||
| 64 | res = -ERESTARTSYS; | ||
| 65 | } while (!fatal_signal_pending(current)); | ||
| 66 | return res; | ||
| 67 | } | ||
| 68 | |||
| 69 | #define rpc_call_sync(clnt, msg, flags) nfs_rpc_wrapper(clnt, msg, flags) | ||
| 70 | |||
| 71 | static int | ||
| 72 | nfs_async_handle_expired_key(struct rpc_task *task) | ||
| 73 | { | ||
| 74 | if (task->tk_status != -EKEYEXPIRED) | ||
| 75 | return 0; | ||
| 76 | task->tk_status = 0; | ||
| 77 | rpc_restart_call(task); | ||
| 78 | rpc_delay(task, NFS_JUKEBOX_RETRY_TIME); | ||
| 79 | return 1; | ||
| 80 | } | ||
| 81 | |||
| 82 | /* | ||
| 83 | * Bare-bones access to getattr: this is for nfs_read_super. | 50 | * Bare-bones access to getattr: this is for nfs_read_super. |
| 84 | */ | 51 | */ |
| 85 | static int | 52 | static int |
| @@ -364,8 +331,6 @@ static void nfs_proc_unlink_rpc_prepare(struct rpc_task *task, struct nfs_unlink | |||
| 364 | 331 | ||
| 365 | static int nfs_proc_unlink_done(struct rpc_task *task, struct inode *dir) | 332 | static int nfs_proc_unlink_done(struct rpc_task *task, struct inode *dir) |
| 366 | { | 333 | { |
| 367 | if (nfs_async_handle_expired_key(task)) | ||
| 368 | return 0; | ||
| 369 | nfs_mark_for_revalidate(dir); | 334 | nfs_mark_for_revalidate(dir); |
| 370 | return 1; | 335 | return 1; |
| 371 | } | 336 | } |
| @@ -385,8 +350,6 @@ static int | |||
| 385 | nfs_proc_rename_done(struct rpc_task *task, struct inode *old_dir, | 350 | nfs_proc_rename_done(struct rpc_task *task, struct inode *old_dir, |
| 386 | struct inode *new_dir) | 351 | struct inode *new_dir) |
| 387 | { | 352 | { |
| 388 | if (nfs_async_handle_expired_key(task)) | ||
| 389 | return 0; | ||
| 390 | nfs_mark_for_revalidate(old_dir); | 353 | nfs_mark_for_revalidate(old_dir); |
| 391 | nfs_mark_for_revalidate(new_dir); | 354 | nfs_mark_for_revalidate(new_dir); |
| 392 | return 1; | 355 | return 1; |
| @@ -642,9 +605,6 @@ static int nfs_read_done(struct rpc_task *task, struct nfs_read_data *data) | |||
| 642 | { | 605 | { |
| 643 | struct inode *inode = data->header->inode; | 606 | struct inode *inode = data->header->inode; |
| 644 | 607 | ||
| 645 | if (nfs_async_handle_expired_key(task)) | ||
| 646 | return -EAGAIN; | ||
| 647 | |||
| 648 | nfs_invalidate_atime(inode); | 608 | nfs_invalidate_atime(inode); |
| 649 | if (task->tk_status >= 0) { | 609 | if (task->tk_status >= 0) { |
| 650 | nfs_refresh_inode(inode, data->res.fattr); | 610 | nfs_refresh_inode(inode, data->res.fattr); |
| @@ -671,9 +631,6 @@ static int nfs_write_done(struct rpc_task *task, struct nfs_write_data *data) | |||
| 671 | { | 631 | { |
| 672 | struct inode *inode = data->header->inode; | 632 | struct inode *inode = data->header->inode; |
| 673 | 633 | ||
| 674 | if (nfs_async_handle_expired_key(task)) | ||
| 675 | return -EAGAIN; | ||
| 676 | |||
| 677 | if (task->tk_status >= 0) | 634 | if (task->tk_status >= 0) |
| 678 | nfs_post_op_update_inode_force_wcc(inode, data->res.fattr); | 635 | nfs_post_op_update_inode_force_wcc(inode, data->res.fattr); |
| 679 | return 0; | 636 | return 0; |
