aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/drivers/pci/ops-sh4.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2010-11-02 09:58:49 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2010-11-02 09:58:49 -0400
commit9e3be1edbe5ca57df51140b523168237b3a01f4d (patch)
treea72c0ec1ce0fbcdcd12ecb6aad9bedcc94b94f9d /arch/sh/drivers/pci/ops-sh4.c
parentASoC: Fix SND_SOC_ALL_CODECS typo for alc5623 (diff)
parentMerge commit 'v2.6.37-rc1' into for-2.6.37 (diff)
downloadlinux-dev-9e3be1edbe5ca57df51140b523168237b3a01f4d.tar.xz
linux-dev-9e3be1edbe5ca57df51140b523168237b3a01f4d.zip
Merge branch 'for-2.6.37' into HEAD
WARN() fix from Joe moved. Conflicts: sound/soc/codecs/wm_hubs.c
Diffstat (limited to 'arch/sh/drivers/pci/ops-sh4.c')
-rw-r--r--arch/sh/drivers/pci/ops-sh4.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/arch/sh/drivers/pci/ops-sh4.c b/arch/sh/drivers/pci/ops-sh4.c
index 0b81999fb88b..b6234203e0ac 100644
--- a/arch/sh/drivers/pci/ops-sh4.c
+++ b/arch/sh/drivers/pci/ops-sh4.c
@@ -9,6 +9,7 @@
*/
#include <linux/pci.h>
#include <linux/io.h>
+#include <linux/spinlock.h>
#include <asm/addrspace.h>
#include "pci-sh4.h"
@@ -18,8 +19,6 @@
#define CONFIG_CMD(bus, devfn, where) \
(0x80000000 | (bus->number << 16) | (devfn << 8) | (where & ~3))
-static DEFINE_SPINLOCK(sh4_pci_lock);
-
/*
* Functions for accessing PCI configuration space with type 1 accesses
*/
@@ -34,10 +33,10 @@ static int sh4_pci_read(struct pci_bus *bus, unsigned int devfn,
* PCIPDR may only be accessed as 32 bit words,
* so we must do byte alignment by hand
*/
- spin_lock_irqsave(&sh4_pci_lock, flags);
+ raw_spin_lock_irqsave(&pci_config_lock, flags);
pci_write_reg(chan, CONFIG_CMD(bus, devfn, where), SH4_PCIPAR);
data = pci_read_reg(chan, SH4_PCIPDR);
- spin_unlock_irqrestore(&sh4_pci_lock, flags);
+ raw_spin_unlock_irqrestore(&pci_config_lock, flags);
switch (size) {
case 1:
@@ -69,10 +68,10 @@ static int sh4_pci_write(struct pci_bus *bus, unsigned int devfn,
int shift;
u32 data;
- spin_lock_irqsave(&sh4_pci_lock, flags);
+ raw_spin_lock_irqsave(&pci_config_lock, flags);
pci_write_reg(chan, CONFIG_CMD(bus, devfn, where), SH4_PCIPAR);
data = pci_read_reg(chan, SH4_PCIPDR);
- spin_unlock_irqrestore(&sh4_pci_lock, flags);
+ raw_spin_unlock_irqrestore(&pci_config_lock, flags);
switch (size) {
case 1: