summaryrefslogtreecommitdiff
path: root/arch/arm/mach-mx6/bus_freq.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-mx6/bus_freq.c')
-rw-r--r--arch/arm/mach-mx6/bus_freq.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/mach-mx6/bus_freq.c b/arch/arm/mach-mx6/bus_freq.c
index 23f56d5deaf1..151b4ee27eb6 100644
--- a/arch/arm/mach-mx6/bus_freq.c
+++ b/arch/arm/mach-mx6/bus_freq.c
@@ -501,6 +501,8 @@ static int busfreq_suspend(struct platform_device *pdev, pm_message_t message)
static int bus_freq_pm_notify(struct notifier_block *nb, unsigned long event,
void *dummy)
{
+ mutex_lock(&bus_freq_mutex);
+
if (event == PM_SUSPEND_PREPARE) {
set_high_bus_freq(1);
busfreq_suspended = 1;
@@ -508,6 +510,8 @@ static int bus_freq_pm_notify(struct notifier_block *nb, unsigned long event,
busfreq_suspended = 0;
}
+ mutex_unlock(&bus_freq_mutex);
+
return NOTIFY_OK;
}
static int busfreq_resume(struct platform_device *pdev)