diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-22 13:43:11 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-22 13:43:11 -0400 |
commit | 5704e44d283e907623e3775c1262f206a2c48cf3 (patch) | |
tree | 0a981b24173e90854e7b7d812b35859e1e5f0174 /kernel | |
parent | 91151240ed8e97cc4457dae4094153c2744f1eb8 (diff) | |
parent | 6de5bd128d381ad88ac6d419a5e597048eb468cf (diff) |
Merge branch 'config' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl
* 'config' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl:
BKL: introduce CONFIG_BKL.
dabusb: remove the BKL
sunrpc: remove the big kernel lock
init/main.c: remove BKL notations
blktrace: remove the big kernel lock
rtmutex-tester: make it build without BKL
dvb-core: kill the big kernel lock
dvb/bt8xx: kill the big kernel lock
tlclk: remove big kernel lock
fix rawctl compat ioctls breakage on amd64 and itanic
uml: kill big kernel lock
parisc: remove big kernel lock
cris: autoconvert trivial BKL users
alpha: kill big kernel lock
isapnp: BKL removal
s390/block: kill the big kernel lock
hpet: kill BKL, add compat_ioctl
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/rtmutex-tester.c | 6 | ||||
-rw-r--r-- | kernel/trace/blktrace.c | 14 |
2 files changed, 9 insertions, 11 deletions
diff --git a/kernel/rtmutex-tester.c b/kernel/rtmutex-tester.c index a56f629b057a..66cb89bc5ef1 100644 --- a/kernel/rtmutex-tester.c +++ b/kernel/rtmutex-tester.c | |||
@@ -76,7 +76,9 @@ static int handle_op(struct test_thread_data *td, int lockwakeup) | |||
76 | } | 76 | } |
77 | 77 | ||
78 | if (!lockwakeup && td->bkl == 4) { | 78 | if (!lockwakeup && td->bkl == 4) { |
79 | #ifdef CONFIG_LOCK_KERNEL | ||
79 | unlock_kernel(); | 80 | unlock_kernel(); |
81 | #endif | ||
80 | td->bkl = 0; | 82 | td->bkl = 0; |
81 | } | 83 | } |
82 | return 0; | 84 | return 0; |
@@ -133,14 +135,18 @@ static int handle_op(struct test_thread_data *td, int lockwakeup) | |||
133 | if (td->bkl) | 135 | if (td->bkl) |
134 | return 0; | 136 | return 0; |
135 | td->bkl = 1; | 137 | td->bkl = 1; |
138 | #ifdef CONFIG_LOCK_KERNEL | ||
136 | lock_kernel(); | 139 | lock_kernel(); |
140 | #endif | ||
137 | td->bkl = 4; | 141 | td->bkl = 4; |
138 | return 0; | 142 | return 0; |
139 | 143 | ||
140 | case RTTEST_UNLOCKBKL: | 144 | case RTTEST_UNLOCKBKL: |
141 | if (td->bkl != 4) | 145 | if (td->bkl != 4) |
142 | break; | 146 | break; |
147 | #ifdef CONFIG_LOCK_KERNEL | ||
143 | unlock_kernel(); | 148 | unlock_kernel(); |
149 | #endif | ||
144 | td->bkl = 0; | 150 | td->bkl = 0; |
145 | return 0; | 151 | return 0; |
146 | 152 | ||
diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c index 959f8d6c8cc1..5328e8779d4d 100644 --- a/kernel/trace/blktrace.c +++ b/kernel/trace/blktrace.c | |||
@@ -23,7 +23,6 @@ | |||
23 | #include <linux/mutex.h> | 23 | #include <linux/mutex.h> |
24 | #include <linux/slab.h> | 24 | #include <linux/slab.h> |
25 | #include <linux/debugfs.h> | 25 | #include <linux/debugfs.h> |
26 | #include <linux/smp_lock.h> | ||
27 | #include <linux/time.h> | 26 | #include <linux/time.h> |
28 | #include <linux/uaccess.h> | 27 | #include <linux/uaccess.h> |
29 | 28 | ||
@@ -639,7 +638,6 @@ int blk_trace_ioctl(struct block_device *bdev, unsigned cmd, char __user *arg) | |||
639 | if (!q) | 638 | if (!q) |
640 | return -ENXIO; | 639 | return -ENXIO; |
641 | 640 | ||
642 | lock_kernel(); | ||
643 | mutex_lock(&bdev->bd_mutex); | 641 | mutex_lock(&bdev->bd_mutex); |
644 | 642 | ||
645 | switch (cmd) { | 643 | switch (cmd) { |
@@ -667,7 +665,6 @@ int blk_trace_ioctl(struct block_device *bdev, unsigned cmd, char __user *arg) | |||
667 | } | 665 | } |
668 | 666 | ||
669 | mutex_unlock(&bdev->bd_mutex); | 667 | mutex_unlock(&bdev->bd_mutex); |
670 | unlock_kernel(); | ||
671 | return ret; | 668 | return ret; |
672 | } | 669 | } |
673 | 670 | ||
@@ -1652,10 +1649,9 @@ static ssize_t sysfs_blk_trace_attr_show(struct device *dev, | |||
1652 | struct block_device *bdev; | 1649 | struct block_device *bdev; |
1653 | ssize_t ret = -ENXIO; | 1650 | ssize_t ret = -ENXIO; |
1654 | 1651 | ||
1655 | lock_kernel(); | ||
1656 | bdev = bdget(part_devt(p)); | 1652 | bdev = bdget(part_devt(p)); |
1657 | if (bdev == NULL) | 1653 | if (bdev == NULL) |
1658 | goto out_unlock_kernel; | 1654 | goto out; |
1659 | 1655 | ||
1660 | q = blk_trace_get_queue(bdev); | 1656 | q = blk_trace_get_queue(bdev); |
1661 | if (q == NULL) | 1657 | if (q == NULL) |
@@ -1683,8 +1679,7 @@ out_unlock_bdev: | |||
1683 | mutex_unlock(&bdev->bd_mutex); | 1679 | mutex_unlock(&bdev->bd_mutex); |
1684 | out_bdput: | 1680 | out_bdput: |
1685 | bdput(bdev); | 1681 | bdput(bdev); |
1686 | out_unlock_kernel: | 1682 | out: |
1687 | unlock_kernel(); | ||
1688 | return ret; | 1683 | return ret; |
1689 | } | 1684 | } |
1690 | 1685 | ||
@@ -1714,11 +1709,10 @@ static ssize_t sysfs_blk_trace_attr_store(struct device *dev, | |||
1714 | 1709 | ||
1715 | ret = -ENXIO; | 1710 | ret = -ENXIO; |
1716 | 1711 | ||
1717 | lock_kernel(); | ||
1718 | p = dev_to_part(dev); | 1712 | p = dev_to_part(dev); |
1719 | bdev = bdget(part_devt(p)); | 1713 | bdev = bdget(part_devt(p)); |
1720 | if (bdev == NULL) | 1714 | if (bdev == NULL) |
1721 | goto out_unlock_kernel; | 1715 | goto out; |
1722 | 1716 | ||
1723 | q = blk_trace_get_queue(bdev); | 1717 | q = blk_trace_get_queue(bdev); |
1724 | if (q == NULL) | 1718 | if (q == NULL) |
@@ -1753,8 +1747,6 @@ out_unlock_bdev: | |||
1753 | mutex_unlock(&bdev->bd_mutex); | 1747 | mutex_unlock(&bdev->bd_mutex); |
1754 | out_bdput: | 1748 | out_bdput: |
1755 | bdput(bdev); | 1749 | bdput(bdev); |
1756 | out_unlock_kernel: | ||
1757 | unlock_kernel(); | ||
1758 | out: | 1750 | out: |
1759 | return ret ? ret : count; | 1751 | return ret ? ret : count; |
1760 | } | 1752 | } |