Commit 235e3845 authored by Lifu Chen's avatar Lifu Chen Committed by Tony Lindgren

ARM: OMAP2+: Use DEFINE_SPINLOCK() for spinlock

spinlock can be initialized automatically with DEFINE_SPINLOCK()
rather than explicitly calling spin_lock_init().
Reported-by: default avatarHulk Robot <hulkci@huawei.com>
Signed-off-by: default avatarLifu Chen <chenlifu@huawei.com>
Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
parent 0db1f107
...@@ -85,7 +85,7 @@ static int dma_lch_count; ...@@ -85,7 +85,7 @@ static int dma_lch_count;
static int dma_chan_count; static int dma_chan_count;
static int omap_dma_reserve_channels; static int omap_dma_reserve_channels;
static spinlock_t dma_chan_lock; static DEFINE_SPINLOCK(dma_chan_lock);
static struct omap_dma_lch *dma_chan; static struct omap_dma_lch *dma_chan;
static inline void disable_lnk(int lch); static inline void disable_lnk(int lch);
...@@ -902,7 +902,6 @@ static int omap_system_dma_probe(struct platform_device *pdev) ...@@ -902,7 +902,6 @@ static int omap_system_dma_probe(struct platform_device *pdev)
if (!dma_chan) if (!dma_chan)
return -ENOMEM; return -ENOMEM;
spin_lock_init(&dma_chan_lock);
for (ch = 0; ch < dma_chan_count; ch++) { for (ch = 0; ch < dma_chan_count; ch++) {
omap_clear_dma(ch); omap_clear_dma(ch);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment