Exemple #1
0
//enable: 0 disable
//           1 enable
//           2 disable right now
__s32 IEP_Deu_Enable(__u32 sel, __u32 enable)
{
	__u32 strtab_addr;

	//pr_warn("bsp_disp_deu_disable, ====3======sel=%d, enable=%d\n", sel, enable);
	strtab_addr =(__u32)g_strtab_addr;
	if(enable == 1) {
		deu_clk_open(sel, 1);
		DEU_EBIOS_Enable(sel, 1);

		__inf("vir_addr:0x%08x, phy_addr:0x%08x\n", strtab_addr, (__u32)(__pa(strtab_addr)));

		/* virtual to physcal addr */
		strtab_addr = __pa(strtab_addr);

		DEU_EBIOS_LP_Set_STR_Addr(sel, strtab_addr);
		DEU_EBIOS_LP_STR_Enable(sel, TRUE);
		DEU_EBIOS_LP_STR_Cfg_Rdy(sel);
		DEU_EBIOS_Set_Csc_Coeff(sel, gdeu[sel].frameinfo.csc_mode);
		DEU_EBIOS_Csc_Enable(sel, 1);
		g_deu_status[sel] |= DEU_USED;
		g_deu_status[sel] &= DEU_NEED_CLOSED_MASK;
	}	else {
		DEU_EBIOS_Csc_Enable(sel, 0);
		DEU_EBIOS_Enable(sel, 0);

		g_deu_status[sel] |= DEU_NEED_CLOSED;

		if(enable == 2)	{
			IEP_Deu_Operation_In_Vblanking(sel);
		}
	}

	return DIS_SUCCESS;
}
Exemple #2
0
__s32 IEP_Deu_Enable(__u32 sel, __u32 enable)
{
	__u32 strtab_addr;

    strtab_addr =(__u32)g_strtab_addr;
	if(enable)
	{
		deu_clk_open(sel);
		DEU_EBIOS_Enable(sel, 1);

		//__inf("vir_addr:0x%08x, phy_addr:0x%08x\n", strtab_addr, (__u32)(OSAL_VAtoPA((void*)strtab_addr)));

		//virtual to physcal addr
		strtab_addr = (__u32)OSAL_VAtoPA((void*)strtab_addr);



		DEU_EBIOS_LP_Set_STR_Addr(sel, strtab_addr);
		DEU_EBIOS_LP_STR_Cfg_Rdy(sel);
		DEU_EBIOS_Set_Csc_Coeff(sel, gdeu[sel].frameinfo.csc_mode);
		DEU_EBIOS_Csc_Enable(sel, 1);
		g_deu_status[sel] |= DEU_USED;

	}
	else
	{
		DEU_EBIOS_Csc_Enable(sel, 0);
		DEU_EBIOS_Enable(sel, 0);

		g_deu_status[sel] |= DEU_NEED_CLOSED;

	}

    return DIS_SUCCESS;
}