diff options
Diffstat (limited to 'firmware/target/arm/sandisk/sansa-e200')
-rw-r--r-- | firmware/target/arm/sandisk/sansa-e200/power-e200.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/firmware/target/arm/sandisk/sansa-e200/power-e200.c b/firmware/target/arm/sandisk/sansa-e200/power-e200.c index 002dcb8407..2745f0ba50 100644 --- a/firmware/target/arm/sandisk/sansa-e200/power-e200.c +++ b/firmware/target/arm/sandisk/sansa-e200/power-e200.c | |||
@@ -66,9 +66,11 @@ void ide_power_enable(bool on) | |||
66 | /** Tuner **/ | 66 | /** Tuner **/ |
67 | static bool powered = false; | 67 | static bool powered = false; |
68 | 68 | ||
69 | bool tuner_power(bool status) | 69 | bool tuner_power_nolock(bool status) |
70 | { | 70 | { |
71 | bool old_status = powered; | 71 | bool old_status; |
72 | |||
73 | old_status = powered; | ||
72 | 74 | ||
73 | if (status != old_status) | 75 | if (status != old_status) |
74 | { | 76 | { |
@@ -115,6 +117,15 @@ bool tuner_power(bool status) | |||
115 | return old_status; | 117 | return old_status; |
116 | } | 118 | } |
117 | 119 | ||
120 | bool tuner_power(bool status) | ||
121 | { | ||
122 | bool old_status; | ||
123 | lv24020lp_lock(); | ||
124 | old_status = tuner_power_nolock(status); | ||
125 | lv24020lp_unlock(); | ||
126 | return old_status; | ||
127 | } | ||
128 | |||
118 | bool tuner_powered(void) | 129 | bool tuner_powered(void) |
119 | { | 130 | { |
120 | return powered; | 131 | return powered; |