/* Now start the DSI clock */
REG_WRITE(MRST_DPLL_A, 0x0);
REG_WRITE(MRST_FPA0, 0x0);
- REG_WRITE(MRST_FPA0, ctx->fp);
- REG_WRITE(MRST_DPLL_A, ((ctx->dpll) & ~BIT30));
+ if (ctx != NULL) {
+ REG_WRITE(MRST_FPA0, ctx->fp);
+ REG_WRITE(MRST_DPLL_A, ((ctx->dpll) & ~BIT30));
+ } else {
+ pr_err("no dsi context, using hardcoded DPLL value\n");
+ /* using hardcode DPLL */
+ REG_WRITE(MRST_FPA0, 0xC1);
+ REG_WRITE(MRST_DPLL_A, 0x00800000);
+ }
/* per spec of display controller, before enable VCO, need wait
* 0.5us, here wait 1us */
/*make sure VGA plane is off. it initializes to on after reset!*/
PSB_WVDC32(0x80000000, VGACNTRL);
-#ifndef CONFIG_SUPPORT_TOSHIBA_MIPI_LVDS_BRIDGE
dpll = PSB_RVDC32(dpll_reg);
if (!(dpll & DPLL_VCO_ENABLE)) {
return -EINVAL;
}
}
-#endif
/* Restore mode */
PSB_WVDC32(htot_val, htot_reg);