ARM: Fix OMAP3 framebuffer divider setting

QEMU was crashing since when setting the DSS divider we were _clearing_
the TV divider, and QEMU did not check for a divide by zero.

This "fixes" the QEMU crash and gets us a working framebuffer on Beagle ;)
This commit is contained in:
Ithamar R. Adema
2014-10-25 14:49:51 -07:00
parent 1436138938
commit 9c71c67140
2 changed files with 2 additions and 6 deletions
@@ -262,7 +262,7 @@ found:
setreg(DISPC, DISPC_TIMING_V, m->dispc_timing_v);
modreg(DISPC, DISPC_DIVISOR, 0xffff, m->dispc_divisor);
modaddr(CM_CLKSEL_DSS, 0xffff, m->dss_divisor);
modaddr(CM_CLKSEL_DSS, 0x3f, m->dss_divisor);
// Tell hardware to update, and wait for it
modreg(DISPC, DISPC_CONTROL,
+1 -5
View File
@@ -110,11 +110,7 @@ platform_init_video(void)
gFramebuffer = arch_get_fb_arm_920(0x88000000);
#elif defined(BOARD_CPU_OMAP3)
extern ArchFramebuffer *arch_get_fb_arm_omap3(addr_t base);
//FIXME: This is disabled because writing to CM_CLKSEL_DSS during the initialisation
//of the framebuffer driver on OMAP3 triggers a floating point exception
//(tested in qemu-linaro from git at commit ac0bfdb9c310276521e5b089d7f36c1f610ca60b)
//gFramebuffer = arch_get_fb_arm_omap3(FB_BASE);
gFramebuffer = NULL;
gFramebuffer = arch_get_fb_arm_omap3(FB_BASE);
#elif defined(BOARD_CPU_PXA270)
ArchFramebuffer *arch_get_fb_arm_pxa270(addr_t base);
gFramebuffer = arch_get_fb_arm_pxa270(0xA3000000);