mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-29 18:11:20 +00:00
NFS: DNS resolver PipeFS notifier introduced
This patch subscribes DNS resolver caches to RPC pipefs notifications. Notifier is registering on NFS module load. This notifier callback is responsible for creation/destruction of PipeFS DNS resolver cache directory. Note that no locking required in notifier callback because PipeFS superblock pointer is passed as an argument from it's creation or destruction routine and thus we can be sure about it's validity. Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
1b340d0118
commit
9df69c81b4
3 changed files with 43 additions and 3 deletions
|
@ -112,7 +112,7 @@ int nfs_cache_wait_for_upcall(struct nfs_cache_defer_req *dreq)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int nfs_cache_register_sb(struct super_block *sb, struct cache_detail *cd)
|
||||
int nfs_cache_register_sb(struct super_block *sb, struct cache_detail *cd)
|
||||
{
|
||||
int ret;
|
||||
struct dentry *dir;
|
||||
|
@ -147,7 +147,7 @@ err:
|
|||
return ret;
|
||||
}
|
||||
|
||||
static void nfs_cache_unregister_sb(struct super_block *sb, struct cache_detail *cd)
|
||||
void nfs_cache_unregister_sb(struct super_block *sb, struct cache_detail *cd)
|
||||
{
|
||||
if (cd->u.pipefs.dir)
|
||||
sunrpc_cache_unregister_pipefs(cd);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue