From dc051248be106c783da15f41295691095f7c18f2 Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Sat, 14 Jul 2007 22:00:50 +0000 Subject: e200: Tuner driver needs to yield alot and also be mutexed. FM debug screen got broken again and was ignoring cancellation and not drawing the lines. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13896 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/sandisk/sansa-e200/power-e200.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'firmware/target/arm') 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) /** Tuner **/ static bool powered = false; -bool tuner_power(bool status) +bool tuner_power_nolock(bool status) { - bool old_status = powered; + bool old_status; + + old_status = powered; if (status != old_status) { @@ -115,6 +117,15 @@ bool tuner_power(bool status) return old_status; } +bool tuner_power(bool status) +{ + bool old_status; + lv24020lp_lock(); + old_status = tuner_power_nolock(status); + lv24020lp_unlock(); + return old_status; +} + bool tuner_powered(void) { return powered; -- cgit v1.2.3