diff options
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/core/ucm.c | 3 | ||||
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_file_ops.c | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/drivers/infiniband/core/ucm.c b/drivers/infiniband/core/ucm.c index 3e6a8ff6d76c..b25675faaaf5 100644 --- a/drivers/infiniband/core/ucm.c +++ b/drivers/infiniband/core/ucm.c | |||
@@ -45,6 +45,7 @@ | |||
45 | #include <linux/cdev.h> | 45 | #include <linux/cdev.h> |
46 | #include <linux/idr.h> | 46 | #include <linux/idr.h> |
47 | #include <linux/mutex.h> | 47 | #include <linux/mutex.h> |
48 | #include <linux/smp_lock.h> | ||
48 | 49 | ||
49 | #include <asm/uaccess.h> | 50 | #include <asm/uaccess.h> |
50 | 51 | ||
@@ -1155,11 +1156,11 @@ static unsigned int ib_ucm_poll(struct file *filp, | |||
1155 | return mask; | 1156 | return mask; |
1156 | } | 1157 | } |
1157 | 1158 | ||
1158 | /* No BKL needed here: no global resources used */ | ||
1159 | static int ib_ucm_open(struct inode *inode, struct file *filp) | 1159 | static int ib_ucm_open(struct inode *inode, struct file *filp) |
1160 | { | 1160 | { |
1161 | struct ib_ucm_file *file; | 1161 | struct ib_ucm_file *file; |
1162 | 1162 | ||
1163 | cycle_kernel_lock(); | ||
1163 | file = kmalloc(sizeof(*file), GFP_KERNEL); | 1164 | file = kmalloc(sizeof(*file), GFP_KERNEL); |
1164 | if (!file) | 1165 | if (!file) |
1165 | return -ENOMEM; | 1166 | return -ENOMEM; |
diff --git a/drivers/infiniband/hw/ipath/ipath_file_ops.c b/drivers/infiniband/hw/ipath/ipath_file_ops.c index e80cfbd4f3fd..35f301c88b57 100644 --- a/drivers/infiniband/hw/ipath/ipath_file_ops.c +++ b/drivers/infiniband/hw/ipath/ipath_file_ops.c | |||
@@ -39,6 +39,7 @@ | |||
39 | #include <linux/highmem.h> | 39 | #include <linux/highmem.h> |
40 | #include <linux/io.h> | 40 | #include <linux/io.h> |
41 | #include <linux/jiffies.h> | 41 | #include <linux/jiffies.h> |
42 | #include <linux/smp_lock.h> | ||
42 | #include <asm/pgtable.h> | 43 | #include <asm/pgtable.h> |
43 | 44 | ||
44 | #include "ipath_kernel.h" | 45 | #include "ipath_kernel.h" |
@@ -1812,10 +1813,10 @@ done: | |||
1812 | return ret; | 1813 | return ret; |
1813 | } | 1814 | } |
1814 | 1815 | ||
1815 | /* No BKL needed here */ | ||
1816 | static int ipath_open(struct inode *in, struct file *fp) | 1816 | static int ipath_open(struct inode *in, struct file *fp) |
1817 | { | 1817 | { |
1818 | /* The real work is performed later in ipath_assign_port() */ | 1818 | /* The real work is performed later in ipath_assign_port() */ |
1819 | cycle_kernel_lock(); | ||
1819 | fp->private_data = kzalloc(sizeof(struct ipath_filedata), GFP_KERNEL); | 1820 | fp->private_data = kzalloc(sizeof(struct ipath_filedata), GFP_KERNEL); |
1820 | return fp->private_data ? 0 : -ENOMEM; | 1821 | return fp->private_data ? 0 : -ENOMEM; |
1821 | } | 1822 | } |