]> git.kernelconcepts.de Git - mv-sheeva.git/blobdiff - kernel/trace/blktrace.c
Merge branch 'llseek' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl
[mv-sheeva.git] / kernel / trace / blktrace.c
index 2d5f3a757316b3c0520f4e9f91c064f1067c11a6..bc251ed667248fb8c72a0dd59ddf3a9a42e1c23d 100644 (file)
@@ -23,7 +23,6 @@
 #include <linux/mutex.h>
 #include <linux/slab.h>
 #include <linux/debugfs.h>
-#include <linux/smp_lock.h>
 #include <linux/time.h>
 #include <linux/uaccess.h>
 
@@ -641,7 +640,6 @@ int blk_trace_ioctl(struct block_device *bdev, unsigned cmd, char __user *arg)
        if (!q)
                return -ENXIO;
 
-       lock_kernel();
        mutex_lock(&bdev->bd_mutex);
 
        switch (cmd) {
@@ -669,7 +667,6 @@ int blk_trace_ioctl(struct block_device *bdev, unsigned cmd, char __user *arg)
        }
 
        mutex_unlock(&bdev->bd_mutex);
-       unlock_kernel();
        return ret;
 }
 
@@ -1654,10 +1651,9 @@ static ssize_t sysfs_blk_trace_attr_show(struct device *dev,
        struct block_device *bdev;
        ssize_t ret = -ENXIO;
 
-       lock_kernel();
        bdev = bdget(part_devt(p));
        if (bdev == NULL)
-               goto out_unlock_kernel;
+               goto out;
 
        q = blk_trace_get_queue(bdev);
        if (q == NULL)
@@ -1685,8 +1681,7 @@ out_unlock_bdev:
        mutex_unlock(&bdev->bd_mutex);
 out_bdput:
        bdput(bdev);
-out_unlock_kernel:
-       unlock_kernel();
+out:
        return ret;
 }
 
@@ -1716,11 +1711,10 @@ static ssize_t sysfs_blk_trace_attr_store(struct device *dev,
 
        ret = -ENXIO;
 
-       lock_kernel();
        p = dev_to_part(dev);
        bdev = bdget(part_devt(p));
        if (bdev == NULL)
-               goto out_unlock_kernel;
+               goto out;
 
        q = blk_trace_get_queue(bdev);
        if (q == NULL)
@@ -1755,8 +1749,6 @@ out_unlock_bdev:
        mutex_unlock(&bdev->bd_mutex);
 out_bdput:
        bdput(bdev);
-out_unlock_kernel:
-       unlock_kernel();
 out:
        return ret ? ret : count;
 }