diff options
Diffstat (limited to 'fs')
| -rw-r--r-- | fs/nfs/inode.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c index 5cb3345eb694..2501b864f7c3 100644 --- a/fs/nfs/inode.c +++ b/fs/nfs/inode.c | |||
| @@ -707,6 +707,13 @@ int nfs_attribute_timeout(struct inode *inode) | |||
| 707 | 707 | ||
| 708 | if (nfs_have_delegation(inode, FMODE_READ)) | 708 | if (nfs_have_delegation(inode, FMODE_READ)) |
| 709 | return 0; | 709 | return 0; |
| 710 | /* | ||
| 711 | * Special case: if the attribute timeout is set to 0, then always | ||
| 712 | * treat the cache as having expired (unless holding | ||
| 713 | * a delegation). | ||
| 714 | */ | ||
| 715 | if (nfsi->attrtimeo == 0) | ||
| 716 | return 1; | ||
| 710 | return !time_in_range(jiffies, nfsi->read_cache_jiffies, nfsi->read_cache_jiffies + nfsi->attrtimeo); | 717 | return !time_in_range(jiffies, nfsi->read_cache_jiffies, nfsi->read_cache_jiffies + nfsi->attrtimeo); |
| 711 | } | 718 | } |
| 712 | 719 | ||
