diff options
Diffstat (limited to 'fs/ocfs2/stack_user.c')
| -rw-r--r-- | fs/ocfs2/stack_user.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/ocfs2/stack_user.c b/fs/ocfs2/stack_user.c index 6b97d11f6bf8..bd7e0f3acfc7 100644 --- a/fs/ocfs2/stack_user.c +++ b/fs/ocfs2/stack_user.c | |||
| @@ -21,6 +21,7 @@ | |||
| 21 | #include <linux/fs.h> | 21 | #include <linux/fs.h> |
| 22 | #include <linux/miscdevice.h> | 22 | #include <linux/miscdevice.h> |
| 23 | #include <linux/mutex.h> | 23 | #include <linux/mutex.h> |
| 24 | #include <linux/smp_lock.h> | ||
| 24 | #include <linux/reboot.h> | 25 | #include <linux/reboot.h> |
| 25 | #include <asm/uaccess.h> | 26 | #include <asm/uaccess.h> |
| 26 | 27 | ||
| @@ -619,10 +620,12 @@ static int ocfs2_control_open(struct inode *inode, struct file *file) | |||
| 619 | return -ENOMEM; | 620 | return -ENOMEM; |
| 620 | p->op_this_node = -1; | 621 | p->op_this_node = -1; |
| 621 | 622 | ||
| 623 | lock_kernel(); | ||
| 622 | mutex_lock(&ocfs2_control_lock); | 624 | mutex_lock(&ocfs2_control_lock); |
| 623 | file->private_data = p; | 625 | file->private_data = p; |
| 624 | list_add(&p->op_list, &ocfs2_control_private_list); | 626 | list_add(&p->op_list, &ocfs2_control_private_list); |
| 625 | mutex_unlock(&ocfs2_control_lock); | 627 | mutex_unlock(&ocfs2_control_lock); |
| 628 | unlock_kernel(); | ||
| 626 | 629 | ||
| 627 | return 0; | 630 | return 0; |
| 628 | } | 631 | } |
| @@ -816,8 +819,7 @@ out: | |||
| 816 | return rc; | 819 | return rc; |
| 817 | } | 820 | } |
| 818 | 821 | ||
| 819 | static int user_cluster_disconnect(struct ocfs2_cluster_connection *conn, | 822 | static int user_cluster_disconnect(struct ocfs2_cluster_connection *conn) |
| 820 | int hangup_pending) | ||
| 821 | { | 823 | { |
| 822 | dlm_release_lockspace(conn->cc_lockspace, 2); | 824 | dlm_release_lockspace(conn->cc_lockspace, 2); |
| 823 | conn->cc_lockspace = NULL; | 825 | conn->cc_lockspace = NULL; |
