diff options
author | Robby Cai <R63905@freescale.com> | 2009-12-24 19:35:19 +0800 |
---|---|---|
committer | Robby Cai <R63905@freescale.com> | 2009-12-24 19:41:34 +0800 |
commit | 1c0431bd28ae05e77d30fb29cdb0d4e6421158f8 (patch) | |
tree | 9b1c76c0c6371ab82d7d0b3fe3df737c64a7a555 | |
parent | 980b76bf7f6e382408a8062fdef201e41be084fd (diff) |
ENGR00119635 MX23 fix wrong state transition of enable lcd controller
fix the bug that causes the driver to enable the lcd controller twice,
which will request lcd pins twice.
Signed-off-by: Robby Cai <R63905@freescale.com>
-rw-r--r-- | drivers/video/stmp37xxfb.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/video/stmp37xxfb.c b/drivers/video/stmp37xxfb.c index ff9e2d03722d..32d3b9c06577 100644 --- a/drivers/video/stmp37xxfb.c +++ b/drivers/video/stmp37xxfb.c @@ -45,7 +45,6 @@ enum { F_DISABLE = 0, F_ENABLE, F_REENABLE, - F_STARTUP, }; struct stmp3xxx_fb_data { @@ -131,7 +130,7 @@ static void set_controller_state(struct stmp3xxx_fb_data *data, u32 state) /* * Re-enable the controller when panel changed. */ - if (old_state == F_ENABLE || old_state == F_STARTUP) { + if (old_state == F_ENABLE) { stmp3xxxfb_disable_controller(data); pentry = data->pdata->cur = data->pdata->next; @@ -654,13 +653,13 @@ static int stmp3xxxfb_notifier(struct notifier_block *self, /* REVISIT */ switch (phase) { case CPUFREQ_PRECHANGE: - if (old_state == F_ENABLE || old_state == F_STARTUP) + if (old_state == F_ENABLE) if (pentry->blank_panel) pentry->blank_panel(FB_BLANK_POWERDOWN); break; case CPUFREQ_POSTCHANGE: - if (old_state == F_ENABLE || old_state == F_STARTUP) + if (old_state == F_ENABLE) if (pentry->blank_panel) pentry->blank_panel(FB_BLANK_UNBLANK); break; @@ -756,7 +755,7 @@ static int __devinit stmp3xxxfb_probe(struct platform_device *pdev) data->phys_start); mutex_init(&data->blank_mutex); INIT_WORK(&data->work, stmp3xxxfb_task); - data->state = F_STARTUP; + data->state = F_ENABLE; stmp3xxxfb_default.bits_per_pixel = pentry->bpp; /* NB: rotated */ |