/*
* rtc_lock protects rtc_irq_data
*/
-static spinlock_t rtc_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(rtc_lock);
static unsigned long rtc_irq_data;
/*
SCOOP_REG(SCOOP_IRM) = 0x0000;
}
-static spinlock_t scoop_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(scoop_lock);
static u32 scoop_gpwr;
unsigned short set_scoop_gpio(unsigned short bit)
*/
static DECLARE_WAIT_QUEUE_HEAD(kapmd_wait);
static DECLARE_COMPLETION(kapmd_exit);
-static spinlock_t kapmd_queue_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(kapmd_queue_lock);
static struct apm_queue kapmd_queue;
#include <asm/mach/dma.h>
-spinlock_t dma_spin_lock = SPIN_LOCK_UNLOCKED;
+DEFINE_SPINLOCK(dma_spin_lock);
#if MAX_DMA_CHANNELS > 0
static int noirqdebug;
static volatile unsigned long irq_err_count;
-static spinlock_t irq_controller_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(irq_controller_lock);
static LIST_HEAD(irq_pending);
struct irqdesc irq_desc[NR_IRQS];
wake_up(&sem->wait);
}
-static spinlock_t semaphore_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(semaphore_lock);
void __sched __down(struct semaphore * sem)
{
};
static struct smp_call_struct * volatile smp_call_function_data;
-static spinlock_t smp_call_function_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(smp_call_function_lock);
int __init __cpu_up(unsigned int cpu)
{
cpu_clear(cpu, data->unfinished);
}
-static spinlock_t stop_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(stop_lock);
/*
* ipi_cpu_stop - handle IPI from smp_send_stop()
extern unsigned long wall_jiffies;
/* this needs a better home */
-spinlock_t rtc_lock = SPIN_LOCK_UNLOCKED;
+DEFINE_SPINLOCK(rtc_lock);
#ifdef CONFIG_SA1100_RTC_MODULE
EXPORT_SYMBOL(rtc_lock);
barrier();
}
-spinlock_t die_lock = SPIN_LOCK_UNLOCKED;
+DEFINE_SPINLOCK(die_lock);
/*
* This function is protected against re-entrancy.
}
static LIST_HEAD(undef_hook);
-static spinlock_t undef_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(undef_lock);
void register_undef_hook(struct undef_hook *hook)
{
static char led_state;
static char hw_led_state;
-static spinlock_t leds_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(leds_lock);
static void ebsa285_leds_event(led_event_t evt)
{
/*
* This is a lock for accessing ports GP1_IO_BASE and GP2_IO_BASE
*/
-spinlock_t gpio_lock = SPIN_LOCK_UNLOCKED;
+DEFINE_SPINLOCK(gpio_lock);
static unsigned int current_gpio_op;
static unsigned int current_gpio_io;
static char led_state;
static char hw_led_state;
-static spinlock_t leds_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(leds_lock);
extern spinlock_t gpio_lock;
static void netwinder_leds_event(led_event_t evt)
#define CM_CTRL IO_ADDRESS(INTEGRATOR_HDR_BASE) + INTEGRATOR_HDR_CTRL_OFFSET
-static spinlock_t cm_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(cm_lock);
/**
* cm_control - update the CM_CTRL register.
* 7:2 register number
*
*/
-static spinlock_t v3_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(v3_lock);
#define PCI_BUS_NONMEM_START 0x00000000
#define PCI_BUS_NONMEM_SIZE SZ_256M
#include <asm/mach/time.h>
#include <asm/mach/irq.h>
-static spinlock_t ixp2000_slowport_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(ixp2000_slowport_lock);
static unsigned long ixp2000_slowport_irq_flags;
/*************************************************************************
* these transactions are atomic or we will end up
* with corrupt data on the bus or in a driver.
*/
-static spinlock_t ixp4xx_pci_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(ixp4xx_pci_lock);
/*
* Read from PCI config space
static LIST_HEAD(clocks);
static DECLARE_MUTEX(clocks_sem);
-static spinlock_t clockfw_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(clockfw_lock);
static void propagate_rate(struct clk * clk);
/* MPU virtual clock functions */
static int select_table_rate(unsigned long rate);
int __init_or_module
omap_cfg_reg(const reg_cfg_t reg_cfg)
{
- static spinlock_t mux_spin_lock = SPIN_LOCK_UNLOCKED;
+ static DEFINE_SPINLOCK(mux_spin_lock);
unsigned long flags;
reg_cfg_set *cfg;
static short hw_led_state;
static short saved_state;
-static spinlock_t leds_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(leds_lock);
short sequoia_read(int addr) {
outw(addr,0x24);
* This is the page table (2MB) covering uncached, DMA consistent allocations
*/
static pte_t *consistent_pte;
-static spinlock_t consistent_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(consistent_lock);
/*
* VM region handling support.
static pte_t *from_pte;
static pte_t *to_pte;
-static spinlock_t v6_lock = SPIN_LOCK_UNLOCKED;
+static DEFINE_SPINLOCK(v6_lock);
#define DCACHE_COLOUR(vaddr) ((vaddr & (SHMLBA - 1)) >> PAGE_SHIFT)