static s32 disp_vdevice_event_proc(void *parg)
#endif
{
	u32 disp = (u32)parg;

	struct disp_device *vdevice = (struct disp_device*)parg;
	struct disp_manager *mgr = NULL;

	if(NULL == vdevice)
		return DISP_IRQ_RETURN;

	disp = vdevice->disp;

	if(disp_al_device_query_irq(disp)) {
		int cur_line = disp_al_device_get_cur_line(disp);
		int start_delay = disp_al_device_get_start_delay(disp);

		mgr = vdevice->manager;
		if(NULL == mgr)
			return DISP_IRQ_RETURN;

		if(cur_line <= (start_delay-4)) {
			sync_event_proc(mgr->disp, false);
		} else {
			sync_event_proc(mgr->disp, false);
		}
	}

	return DISP_IRQ_RETURN;
}
s32 disp_lcd_event_proc(void *parg)
#endif
{
	u32 screen_id = (u32)parg;
	static u32 cntr=0;
	if(tcon_irq_query(screen_id,LCD_IRQ_TCON0_VBLK) || tcon_irq_query(screen_id,LCD_IRQ_TCON1_VBLK)
	    || dsi_irq_query(screen_id,DSI_IRQ_VIDEO_VBLK)) {
		sync_event_proc(screen_id);
	}

	if(tcon_irq_query(screen_id,LCD_IRQ_TCON0_CNTR)) {
		sync_event_proc(screen_id);

		if(disp_al_lcd_tri_busy(screen_id))	{
			if(cntr>=1)	{
				cntr = 0;
			}	else {
				cntr++;
			}
		}	else {
			cntr = 0;
		}

		if(cntr==0)	{
			/* todo? cpu_isr */
			disp_al_lcd_tri_start(screen_id);
		}
	}

	return OSAL_IRQ_RETURN;
}
Exemple #3
0
static s32 disp_hdmi_event_proc(void *parg)
#endif
{
	u32 disp = (u32)parg;
	struct disp_device *hdmi = disp_get_hdmi(disp);
	struct disp_manager *mgr = NULL;

	if(disp_al_device_query_irq(disp)) {
		int cur_line = disp_al_device_get_cur_line(disp);
		int start_delay = disp_al_device_get_start_delay(disp);

		if(NULL == hdmi)
			return DISP_IRQ_RETURN;
		mgr = hdmi->manager;
		if(NULL == mgr)
			return DISP_IRQ_RETURN;

		if(cur_line <= (start_delay-4)) {
			sync_event_proc(mgr->disp);
		} else {
			/* skip a frame */
		}
	}

	return DISP_IRQ_RETURN;
}
Exemple #4
0
static s32 disp_tv_event_proc(void *parg)
#endif
{
	u32 disp = (u32)parg;
	struct disp_device *ptv = disp_get_tv(disp);
	struct disp_manager *mgr = NULL;

	mgr = ptv->manager;
	if(disp_al_device_query_irq(disp)) {		//modify
		int cur_line = disp_al_device_get_cur_line(disp);
		int start_delay = disp_al_device_get_start_delay(disp);
		if((NULL == ptv) || (NULL == mgr))
			return DISP_IRQ_RETURN;

		if(cur_line <= (start_delay-4)) {
			sync_event_proc(mgr->disp);
		} else {
			//skip a frame
		}
	}

	return DISP_IRQ_RETURN;
}