From: Vasily Khoruzhick Date: Fri, 11 Mar 2011 09:20:50 +0000 (+0200) Subject: ARM: pxafb: don't disable controller on cpufreq transition if overlay in use X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=27be9a9e378dad166fc81df310e052e7b67cb667;p=linux-beck.git ARM: pxafb: don't disable controller on cpufreq transition if overlay in use It's not safe to disable controller if overlay(s) is enabled (results in system hang). So we avoid to disable controller in this case. Userspace should choose proper governor to avoid freq changing when overlay is in use, otherwise LCD may blink. Signed-off-by: Vasily Khoruzhick Signed-off-by: Eric Miao --- diff --git a/drivers/video/pxafb.c b/drivers/video/pxafb.c index a3bdcc152671..a2e5b5100ab4 100644 --- a/drivers/video/pxafb.c +++ b/drivers/video/pxafb.c @@ -1648,7 +1648,8 @@ pxafb_freq_transition(struct notifier_block *nb, unsigned long val, void *data) switch (val) { case CPUFREQ_PRECHANGE: - set_ctrlr_state(fbi, C_DISABLE_CLKCHANGE); + if (!fbi->overlay[0].usage && !fbi->overlay[1].usage) + set_ctrlr_state(fbi, C_DISABLE_CLKCHANGE); break; case CPUFREQ_POSTCHANGE: