diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-06-08 04:46:23 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-07-01 09:15:39 -0400 |
commit | a8fb688e1d0cfffe715ada2d1af33af82b647922 (patch) | |
tree | 34f09ff6aa0257116e45c16d44462c646ec6eb1b /arch/arm/plat-spear | |
parent | aeea1808fe752e917b966961bde3e9603f206dec (diff) |
ARM: spear: update for PL08x dma engine changes
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/plat-spear')
-rw-r--r-- | arch/arm/plat-spear/include/plat/pl080.h | 6 | ||||
-rw-r--r-- | arch/arm/plat-spear/pl080.c | 10 |
2 files changed, 7 insertions, 9 deletions
diff --git a/arch/arm/plat-spear/include/plat/pl080.h b/arch/arm/plat-spear/include/plat/pl080.h index 2bc6b54460a8..eb6590ded40d 100644 --- a/arch/arm/plat-spear/include/plat/pl080.h +++ b/arch/arm/plat-spear/include/plat/pl080.h | |||
@@ -14,8 +14,8 @@ | |||
14 | #ifndef __PLAT_PL080_H | 14 | #ifndef __PLAT_PL080_H |
15 | #define __PLAT_PL080_H | 15 | #define __PLAT_PL080_H |
16 | 16 | ||
17 | struct pl08x_dma_chan; | 17 | struct pl08x_channel_data; |
18 | int pl080_get_signal(struct pl08x_dma_chan *ch); | 18 | int pl080_get_signal(const struct pl08x_channel_data *cd); |
19 | void pl080_put_signal(struct pl08x_dma_chan *ch); | 19 | void pl080_put_signal(const struct pl08x_channel_data *cd, int signal); |
20 | 20 | ||
21 | #endif /* __PLAT_PL080_H */ | 21 | #endif /* __PLAT_PL080_H */ |
diff --git a/arch/arm/plat-spear/pl080.c b/arch/arm/plat-spear/pl080.c index 12cf27f935f9..cfa1199d0f4a 100644 --- a/arch/arm/plat-spear/pl080.c +++ b/arch/arm/plat-spear/pl080.c | |||
@@ -27,9 +27,8 @@ struct { | |||
27 | unsigned char val; | 27 | unsigned char val; |
28 | } signals[16] = {{0, 0}, }; | 28 | } signals[16] = {{0, 0}, }; |
29 | 29 | ||
30 | int pl080_get_signal(struct pl08x_dma_chan *ch) | 30 | int pl080_get_signal(const struct pl08x_channel_data *cd) |
31 | { | 31 | { |
32 | const struct pl08x_channel_data *cd = ch->cd; | ||
33 | unsigned int signal = cd->min_signal, val; | 32 | unsigned int signal = cd->min_signal, val; |
34 | unsigned long flags; | 33 | unsigned long flags; |
35 | 34 | ||
@@ -63,18 +62,17 @@ int pl080_get_signal(struct pl08x_dma_chan *ch) | |||
63 | return signal; | 62 | return signal; |
64 | } | 63 | } |
65 | 64 | ||
66 | void pl080_put_signal(struct pl08x_dma_chan *ch) | 65 | void pl080_put_signal(const struct pl08x_channel_data *cd, int signal) |
67 | { | 66 | { |
68 | const struct pl08x_channel_data *cd = ch->cd; | ||
69 | unsigned long flags; | 67 | unsigned long flags; |
70 | 68 | ||
71 | spin_lock_irqsave(&lock, flags); | 69 | spin_lock_irqsave(&lock, flags); |
72 | 70 | ||
73 | /* if signal is not used */ | 71 | /* if signal is not used */ |
74 | if (!signals[cd->min_signal].busy) | 72 | if (!signals[signal].busy) |
75 | BUG(); | 73 | BUG(); |
76 | 74 | ||
77 | signals[cd->min_signal].busy--; | 75 | signals[signal].busy--; |
78 | 76 | ||
79 | spin_unlock_irqrestore(&lock, flags); | 77 | spin_unlock_irqrestore(&lock, flags); |
80 | } | 78 | } |