diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-10-26 10:17:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-10-26 10:17:32 -0400 |
commit | 3cfef9524677a4ecb392d6fbffe6ebce6302f1d4 (patch) | |
tree | 88647d9dc50d634dee9cfeb7f354d620977a2f33 /drivers/acpi | |
parent | 982653009b883ef1529089e3e6f1ae2fee41cbe2 (diff) | |
parent | 68cc3990a545dc0da221b4844dd8b9c06623a6c5 (diff) |
Merge branch 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
* 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (27 commits)
rtmutex: Add missing rcu_read_unlock() in debug_rt_mutex_print_deadlock()
lockdep: Comment all warnings
lib: atomic64: Change the type of local lock to raw_spinlock_t
locking, lib/atomic64: Annotate atomic64_lock::lock as raw
locking, x86, iommu: Annotate qi->q_lock as raw
locking, x86, iommu: Annotate irq_2_ir_lock as raw
locking, x86, iommu: Annotate iommu->register_lock as raw
locking, dma, ipu: Annotate bank_lock as raw
locking, ARM: Annotate low level hw locks as raw
locking, drivers/dca: Annotate dca_lock as raw
locking, powerpc: Annotate uic->lock as raw
locking, x86: mce: Annotate cmci_discover_lock as raw
locking, ACPI: Annotate c3_lock as raw
locking, oprofile: Annotate oprofilefs lock as raw
locking, video: Annotate vga console lock as raw
locking, latencytop: Annotate latency_lock as raw
locking, timer_stats: Annotate table_lock as raw
locking, rwsem: Annotate inner lock as raw
locking, semaphores: Annotate inner lock as raw
locking, sched: Annotate thread_group_cputimer as raw
...
Fix up conflicts in kernel/posix-cpu-timers.c manually: making
cputimer->cputime a raw lock conflicted with the ABBA fix in commit
bcd5cff7216f ("cputimer: Cure lock inversion").
Diffstat (limited to 'drivers/acpi')
-rw-r--r-- | drivers/acpi/processor_idle.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c index 2e69e09ff03e..9b88f9828d8c 100644 --- a/drivers/acpi/processor_idle.c +++ b/drivers/acpi/processor_idle.c | |||
@@ -852,7 +852,7 @@ static int acpi_idle_enter_simple(struct cpuidle_device *dev, | |||
852 | } | 852 | } |
853 | 853 | ||
854 | static int c3_cpu_count; | 854 | static int c3_cpu_count; |
855 | static DEFINE_SPINLOCK(c3_lock); | 855 | static DEFINE_RAW_SPINLOCK(c3_lock); |
856 | 856 | ||
857 | /** | 857 | /** |
858 | * acpi_idle_enter_bm - enters C3 with proper BM handling | 858 | * acpi_idle_enter_bm - enters C3 with proper BM handling |
@@ -930,12 +930,12 @@ static int acpi_idle_enter_bm(struct cpuidle_device *dev, | |||
930 | * without doing anything. | 930 | * without doing anything. |
931 | */ | 931 | */ |
932 | if (pr->flags.bm_check && pr->flags.bm_control) { | 932 | if (pr->flags.bm_check && pr->flags.bm_control) { |
933 | spin_lock(&c3_lock); | 933 | raw_spin_lock(&c3_lock); |
934 | c3_cpu_count++; | 934 | c3_cpu_count++; |
935 | /* Disable bus master arbitration when all CPUs are in C3 */ | 935 | /* Disable bus master arbitration when all CPUs are in C3 */ |
936 | if (c3_cpu_count == num_online_cpus()) | 936 | if (c3_cpu_count == num_online_cpus()) |
937 | acpi_write_bit_register(ACPI_BITREG_ARB_DISABLE, 1); | 937 | acpi_write_bit_register(ACPI_BITREG_ARB_DISABLE, 1); |
938 | spin_unlock(&c3_lock); | 938 | raw_spin_unlock(&c3_lock); |
939 | } else if (!pr->flags.bm_check) { | 939 | } else if (!pr->flags.bm_check) { |
940 | ACPI_FLUSH_CPU_CACHE(); | 940 | ACPI_FLUSH_CPU_CACHE(); |
941 | } | 941 | } |
@@ -944,10 +944,10 @@ static int acpi_idle_enter_bm(struct cpuidle_device *dev, | |||
944 | 944 | ||
945 | /* Re-enable bus master arbitration */ | 945 | /* Re-enable bus master arbitration */ |
946 | if (pr->flags.bm_check && pr->flags.bm_control) { | 946 | if (pr->flags.bm_check && pr->flags.bm_control) { |
947 | spin_lock(&c3_lock); | 947 | raw_spin_lock(&c3_lock); |
948 | acpi_write_bit_register(ACPI_BITREG_ARB_DISABLE, 0); | 948 | acpi_write_bit_register(ACPI_BITREG_ARB_DISABLE, 0); |
949 | c3_cpu_count--; | 949 | c3_cpu_count--; |
950 | spin_unlock(&c3_lock); | 950 | raw_spin_unlock(&c3_lock); |
951 | } | 951 | } |
952 | kt2 = ktime_get_real(); | 952 | kt2 = ktime_get_real(); |
953 | idle_time_ns = ktime_to_ns(ktime_sub(kt2, kt1)); | 953 | idle_time_ns = ktime_to_ns(ktime_sub(kt2, kt1)); |