Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 121471
b: refs/heads/master
c: 954d7a1
h: refs/heads/master
i:
  121469: a898802
  121467: 2bb18e2
  121463: 042ad3b
  121455: a59db4d
  121439: a6ade1b
  121407: b8f1b70
  121343: 57a60d0
v: v3
  • Loading branch information
Jeff Layton authored and Steve French committed Dec 26, 2008
1 parent 83b1cd1 commit 1d97de2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 72ca545b2d83ac7de671bf66d2dbc214528b4c0c
refs/heads/master: 954d7a1cf12158fed23dd8b0f3f563d5a5c97f28
12 changes: 11 additions & 1 deletion trunk/fs/cifs/cifsfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,9 @@ unsigned int sign_CIFS_PDUs = 1;
extern struct task_struct *oplockThread; /* remove sparse warning */
struct task_struct *oplockThread = NULL;
/* extern struct task_struct * dnotifyThread; remove sparse warning */
#ifdef CONFIG_CIFS_EXPERIMENTAL
static struct task_struct *dnotifyThread = NULL;
#endif
static const struct super_operations cifs_super_ops;
unsigned int CIFSMaxBufSize = CIFS_MAX_MSGSIZE;
module_param(CIFSMaxBufSize, int, 0);
Expand Down Expand Up @@ -1049,6 +1051,7 @@ static int cifs_oplock_thread(void *dummyarg)
return 0;
}

#ifdef CONFIG_CIFS_EXPERIMENTAL
static int cifs_dnotify_thread(void *dummyarg)
{
struct list_head *tmp;
Expand All @@ -1074,6 +1077,7 @@ static int cifs_dnotify_thread(void *dummyarg)

return 0;
}
#endif

static int __init
init_cifs(void)
Expand Down Expand Up @@ -1151,16 +1155,20 @@ init_cifs(void)
goto out_unregister_dfs_key_type;
}

#ifdef CONFIG_CIFS_EXPERIMENTAL
dnotifyThread = kthread_run(cifs_dnotify_thread, NULL, "cifsdnotifyd");
if (IS_ERR(dnotifyThread)) {
rc = PTR_ERR(dnotifyThread);
cERROR(1, ("error %d create dnotify thread", rc));
goto out_stop_oplock_thread;
}
#endif

return 0;

#ifdef CONFIG_CIFS_EXPERIMENTAL
out_stop_oplock_thread:
#endif
kthread_stop(oplockThread);
out_unregister_dfs_key_type:
#ifdef CONFIG_CIFS_DFS_UPCALL
Expand Down Expand Up @@ -1199,8 +1207,10 @@ exit_cifs(void)
cifs_destroy_inodecache();
cifs_destroy_mids();
cifs_destroy_request_bufs();
kthread_stop(oplockThread);
#ifdef CONFIG_CIFS_EXPERIMENTAL
kthread_stop(dnotifyThread);
#endif
kthread_stop(oplockThread);
}

MODULE_AUTHOR("Steve French <sfrench@us.ibm.com>");
Expand Down

0 comments on commit 1d97de2

Please sign in to comment.