当前位置: 首页>>代码示例>>C++>>正文


C++ DISP_REG_GET函数代码示例

本文整理汇总了C++中DISP_REG_GET函数的典型用法代码示例。如果您正苦于以下问题:C++ DISP_REG_GET函数的具体用法?C++ DISP_REG_GET怎么用?C++ DISP_REG_GET使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了DISP_REG_GET函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: disp_bls_set_backlight

int disp_bls_set_backlight(unsigned int level)
{
    printf("[DDP] disp_bls_set_backlight: %d, CG = 0x%x, BLS_EN = 0x%x, PWM_DUTY = %d\n", 
        level,
        DISP_REG_GET(DISP_REG_CONFIG_MMSYS_CG_CON0), 
        DISP_REG_GET(DISP_REG_BLS_EN),
        DISP_REG_GET(DISP_REG_BLS_PWM_DUTY));
    
    if (level && (!(DISP_REG_GET(DISP_REG_BLS_EN) & 0x10000)))
    {
        disp_bls_config();
    }

#ifdef USE_DISP_BLS_MUTEX
    disp_bls_get_mutex();
#else
    DISP_REG_SET(DISP_REG_BLS_DEBUG, 0x3);
#endif

    DISP_REG_SET(DISP_REG_BLS_PWM_DUTY, brightness_mapping(level));
    printf("[DDP] PWM_DUTY: %x\n", DISP_REG_GET(DISP_REG_BLS_PWM_DUTY));

#ifdef USE_DISP_BLS_MUTEX
    disp_bls_release_mutex();
#else
    DISP_REG_SET(DISP_REG_BLS_DEBUG, 0x0);
#endif

    return 0;    
}
开发者ID:SteveHuang27,项目名称:Thunder-Kernel,代码行数:30,代码来源:ddp_bls.c

示例2: ddp_check_mutex_l

static void ddp_check_mutex_l(int mutex_id, int* module_list, DDP_MODE ddp_mode)
{
    int i=0;
    kal_uint32 real_value = 0;
    kal_uint32 expect_value = 0;
    kal_uint32 real_sof  = 0;
    MUTEX_SOF  expect_sof  = SOF_SINGLE;
    int module_num = ddp_get_module_num_l(module_list);
    if(mutex_id < DISP_MUTEX_DDP_FIRST || mutex_id > DISP_MUTEX_DDP_LAST)
    {
        DDPDUMP("error:check mutex fail:exceed mutex max (0 ~ %d)\n",DISP_MUTEX_DDP_LAST);
        return;
    }
    real_value = DISP_REG_GET(DISP_REG_CONFIG_MUTEX_MOD(mutex_id));
    for(i = 0 ; i < module_num ; i++)
    {
        if(module_mutex_map[module_list[i]].bit != -1)
            expect_value |= (1 << module_mutex_map[module_list[i]].bit);
    }
    if( expect_value != real_value )
    {
       DDPDUMP("error:mutex %d error: expect 0x%x, real 0x%x\n",mutex_id,expect_value,real_value);
    }
    real_sof  = DISP_REG_GET(DISP_REG_CONFIG_MUTEX_SOF(mutex_id));
    expect_sof = ddp_get_mutex_sof(module_list[module_num-1],ddp_mode);
    if((kal_uint32)expect_sof != real_sof)
    {
       DDPDUMP("error:mutex %d sof error: expect %s, real %s\n", mutex_id,
             ddp_get_mutex_sof_name(expect_sof),
             ddp_get_mutex_sof_name((MUTEX_SOF)real_sof));
    }
}
开发者ID:Jlsmily,项目名称:android_kernel_meilan2,代码行数:32,代码来源:ddp_path.c

示例3: disp_bls_init

void disp_bls_init(unsigned int srcWidth, unsigned int srcHeight)
{
    struct cust_mt65xx_led *cust_led_list = get_cust_led_list();
    struct cust_mt65xx_led *cust = NULL;
    struct PWM_config *config_data = NULL;

    if(cust_led_list)
    {
        cust = &cust_led_list[MT65XX_LED_TYPE_LCD];
        if((strcmp(cust->name,"lcd-backlight") == 0) && (cust->mode == MT65XX_LED_MODE_CUST_BLS_PWM))
        {
            config_data = &cust->config_data;
            if (config_data->clock_source >= 0 && config_data->clock_source <= 3)
            {
            	unsigned int regVal = DISP_REG_GET(CLK_CFG_1);
                DISP_REG_SET(CLK_CFG_1, (regVal & ~0x3) | config_data->clock_source);
                printf("disp_bls_init : CLK_CFG_1 0x%x => 0x%x\n", regVal, DISP_REG_GET(CLK_CFG_1));
            }
            gPWMDiv = (config_data->div == 0) ? PWM_DEFAULT_DIV_VALUE : config_data->div;
            gPWMDiv &= 0x3FF;
            printf("disp_bls_init : PWM config data (%d,%d)\n", config_data->clock_source, config_data->div);
        }
    }
    
    printf("[DDP] disp_bls_init : srcWidth = %d, srcHeight = %d\n", srcWidth, srcHeight);
    printf("[DDP] disp_bls_init : CG = 0x%x, BLS_EN = 0x%x, PWM_DUTY = %d\n", 
        DISP_REG_GET(DISP_REG_CONFIG_MMSYS_CG_CON0), 
        DISP_REG_GET(DISP_REG_BLS_EN),
        DISP_REG_GET(DISP_REG_BLS_PWM_DUTY));
    
    DISP_REG_SET(DISP_REG_BLS_SRC_SIZE, (srcHeight << 16) | srcWidth);
    DISP_REG_SET(DISP_REG_BLS_PWM_DUTY, 0);
    DISP_REG_SET(DISP_REG_BLS_PWM_CON, 0x0 | (gPWMDiv << 16));
    DISP_REG_SET(DISP_REG_BLS_EN, 0x00010000);
}
开发者ID:SteveHuang27,项目名称:Thunder-Kernel,代码行数:35,代码来源:ddp_bls.c

示例4: ddp_dump_reg_to_buf

unsigned int ddp_dump_reg_to_buf(unsigned int start_module, unsigned long *addr)
{
	unsigned int cnt = 0;
	unsigned long reg_addr;

	switch (start_module) {
	case 0:		/* DISP_MODULE_WDMA0: */
		reg_addr = DISP_REG_WDMA_INTEN;

		while (reg_addr <= DISP_REG_WDMA_PRE_ADD2) {
			addr[cnt++] = DISP_REG_GET(reg_addr);
			reg_addr += 4;
		}
	case 1:		/* DISP_MODULE_OVL: */
		reg_addr = DISP_REG_OVL_STA;

		while (reg_addr <= DISP_REG_OVL_L3_PITCH) {
			addr[cnt++] = DISP_REG_GET(reg_addr);
			reg_addr += 4;
		}
	case 2:		/* DISP_MODULE_RDMA: */
		reg_addr = DISP_REG_RDMA_INT_ENABLE;

		while (reg_addr <= DISP_REG_RDMA_PRE_ADD_1) {
			addr[cnt++] = DISP_REG_GET(reg_addr);
			reg_addr += 4;
		}
		break;
	}
	return cnt * sizeof(unsigned long);
}
开发者ID:John677,项目名称:Kernal_k3note,代码行数:31,代码来源:ddp_debug.c

示例5: rdma_dump_analysis

void rdma_dump_analysis(DISP_MODULE_ENUM module)
{
    unsigned int idx = rdma_index(module);
    DDPDUMP("==DISP RDMA%d ANALYSIS==\n", idx); 
    DDPDUMP("rdma%d: en=%d, memory mode=%d, w=%d, h=%d, pitch=%d, addr=0x%x, fmt=%s, fifo_min=%d, \
    in_p_cnt=%d, in_l_cnt=%d, out_p_cnt=%d, out_l_cnt=%d, rdma_start_time=%lld ns,rdma_end_time=%lld ns\n",

        idx,
        DISP_REG_GET(DISP_REG_RDMA_GLOBAL_CON+DISP_RDMA_INDEX_OFFSET*idx)&0x1,
        (DISP_REG_GET(DISP_REG_RDMA_GLOBAL_CON+DISP_RDMA_INDEX_OFFSET*idx)&0x2)?1:0,
        DISP_REG_GET(DISP_REG_RDMA_SIZE_CON_0+DISP_RDMA_INDEX_OFFSET*idx)&0xfff,
        DISP_REG_GET(DISP_REG_RDMA_SIZE_CON_1+DISP_RDMA_INDEX_OFFSET*idx)&0xfffff,
        DISP_REG_GET(DISP_REG_RDMA_MEM_SRC_PITCH+DISP_RDMA_INDEX_OFFSET*idx), 
        DISP_REG_GET(DISP_REG_RDMA_MEM_START_ADDR+DISP_RDMA_INDEX_OFFSET*idx),
        rdma_intput_format_name(
            (DISP_REG_GET(DISP_REG_RDMA_MEM_CON+DISP_RDMA_INDEX_OFFSET*idx)>>4)&0xf,
            (DISP_REG_GET(DISP_REG_RDMA_MEM_CON+DISP_RDMA_INDEX_OFFSET*idx)>>8)&0x1
            ),
        DISP_REG_GET(DISP_REG_RDMA_FIFO_LOG+DISP_RDMA_INDEX_OFFSET*idx),
        DISP_REG_GET(DISP_REG_RDMA_IN_P_CNT+DISP_RDMA_INDEX_OFFSET*idx),
        DISP_REG_GET(DISP_REG_RDMA_IN_LINE_CNT+DISP_RDMA_INDEX_OFFSET*idx),
        DISP_REG_GET(DISP_REG_RDMA_OUT_P_CNT+DISP_RDMA_INDEX_OFFSET*idx),
        DISP_REG_GET(DISP_REG_RDMA_OUT_LINE_CNT+DISP_RDMA_INDEX_OFFSET*idx),
        rdma_start_time[idx],
        rdma_end_time[idx]
    );
    DDPDUMP("irq cnt: start=%d, end=%d, underflow=%d, targetline=%d \n", 
      rdma_start_irq_cnt[idx], rdma_done_irq_cnt[idx], rdma_underflow_irq_cnt[idx], rdma_targetline_irq_cnt[idx]);
      
    return ;
}
开发者ID:TechExhibeo,项目名称:kernel_lenovo_a7000,代码行数:31,代码来源:ddp_rdma.c

示例6: rdma_resolution_test

int rdma_resolution_test(DISP_MODULE_ENUM module,unsigned int fw,unsigned fh)
{
	int ret=0;
	unsigned int idx = rdma_index(module);
	
	int pw = DISP_REG_GET(DISP_REG_RDMA_SIZE_CON_0+DISP_RDMA_INDEX_OFFSET*idx)&0xfff;
	int ph = DISP_REG_GET(DISP_REG_RDMA_SIZE_CON_1+DISP_RDMA_INDEX_OFFSET*idx)&0xfffff;

    //reset rdma
	ret=rdma_reset(module,NULL);
	if(ret!=0)
	{
		printk("reset fail\n");
		return -1;
	}

	DISP_REG_SET_FIELD(NULL,SIZE_CON_0_FLD_OUTPUT_FRAME_WIDTH, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_SIZE_CON_0, pw);
    DISP_REG_SET_FIELD(NULL,SIZE_CON_1_FLD_OUTPUT_FRAME_HEIGHT, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_SIZE_CON_1, ph);
	DISP_REG_SET_FIELD(NULL,SIZE_CON_0_FLD_OUTPUT_FRAME_WIDTH, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_SIZE_CON_0, fw);
    DISP_REG_SET_FIELD(NULL,SIZE_CON_1_FLD_OUTPUT_FRAME_HEIGHT, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_SIZE_CON_1, fh);

	int w = DISP_REG_GET(DISP_REG_RDMA_SIZE_CON_0+DISP_RDMA_INDEX_OFFSET*idx)&0xfff;
    int h = DISP_REG_GET(DISP_REG_RDMA_SIZE_CON_1+DISP_RDMA_INDEX_OFFSET*idx)&0xfffff;
    if((w!=pw) && (h!=ph))
    {
        printk("w=%d,h=%d,pw=%d,ph=%d,fw=%d,fh=%d\n",w,h,pw,ph,fw,fh);
		DISP_REG_SET_FIELD(NULL,SIZE_CON_0_FLD_OUTPUT_FRAME_WIDTH, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_SIZE_CON_0, pw);
    	DISP_REG_SET_FIELD(NULL,SIZE_CON_1_FLD_OUTPUT_FRAME_HEIGHT, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_SIZE_CON_1, ph);
		ret =-1;
    }
	
	return ret;
}
开发者ID:TechExhibeo,项目名称:kernel_lenovo_a7000,代码行数:33,代码来源:ddp_rdma.c

示例7: rdma_reset

int rdma_reset(DISP_MODULE_ENUM module,void * handle) {
    unsigned int delay_cnt=0;
    int ret =0;
    unsigned int idx = rdma_index(module);

    ASSERT(idx <= 2);

    DISP_REG_SET_FIELD(handle,GLOBAL_CON_FLD_SOFT_RESET, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_GLOBAL_CON, 1);
    while((DISP_REG_GET(idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_GLOBAL_CON)&0x700)==0x100)
    {
        delay_cnt++;
        udelay(10);
        if(delay_cnt>10000)
        {
            ret = -1;
            DDPERR("rdma%d_reset timeout, stage 1! DISP_REG_RDMA_GLOBAL_CON=0x%x \n", idx, DISP_REG_GET(idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_GLOBAL_CON));
            break;
        }
    }      
    DISP_REG_SET_FIELD(handle,GLOBAL_CON_FLD_SOFT_RESET, idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_GLOBAL_CON, 0);
    delay_cnt =0;
    while((DISP_REG_GET(idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_GLOBAL_CON)&0x700)!=0x100)
    {
        delay_cnt++;
        udelay(10);
        if(delay_cnt>10000)
        {
            ret = -1;
            DDPERR("rdma%d_reset timeout, stage 2! DISP_REG_RDMA_GLOBAL_CON=0x%x \n", idx, DISP_REG_GET(idx*DISP_RDMA_INDEX_OFFSET+ DISP_REG_RDMA_GLOBAL_CON));
            break;
        }
    }   
    return ret;
}
开发者ID:TechExhibeo,项目名称:kernel_lenovo_a7000,代码行数:34,代码来源:ddp_rdma.c

示例8: ovl_get_info

void ovl_get_info(int idx, void *data)
{
	int i = 0;
	OVL_BASIC_STRUCT *pdata = (OVL_BASIC_STRUCT *)data;
	unsigned int idx_offset = 0;
	unsigned int layer_off = 0;
	unsigned int src_on = DISP_REG_GET(DISP_REG_OVL_SRC_CON + idx_offset);
	OVL_BASIC_STRUCT *p = NULL;

	memset(pdata, 0, sizeof(OVL_BASIC_STRUCT)*OVL_LAYER_NUM);    

	idx_offset = 0;
	src_on = DISP_REG_GET(DISP_REG_OVL_SRC_CON + idx_offset);
	for (i = 0; i < OVL_LAYER_NUM_PER_OVL; i++) {
		layer_off  = (i%4)*OVL_LAYER_OFFSET + idx_offset;
		p = &pdata[i];
		p->layer = i;
		p->layer_en = src_on & (0x1<<i);
		if (p->layer_en) {
			p->fmt = (DISP_REG_GET(layer_off+DISP_REG_OVL_L0_CON)>>12)&0xf;
			p->addr =  DISP_REG_GET(layer_off+DISP_REG_OVL_L0_ADDR);
			p->src_w = DISP_REG_GET(layer_off+DISP_REG_OVL_L0_SRC_SIZE)&0xfff;
			p->src_h = (DISP_REG_GET(layer_off+DISP_REG_OVL_L0_SRC_SIZE)>>16)&0xfff;
			p->src_pitch = DISP_REG_GET(layer_off+DISP_REG_OVL_L0_PITCH)&0xffff;
			p->bpp = ddp_get_bpp(DISP_MODULE_OVL, (DISP_REG_GET(layer_off+DISP_REG_OVL_L0_CON)>>12)&0xf);
		}
		DISP_DBG("ovl_get_info:layer%d,en %d,w %d,h %d, bpp %d,addr %lx\n",
			i, p->layer_en, p->src_w, p->src_h, p->bpp, p->addr);
	}
开发者ID:CobraJet93,项目名称:kernel-3.10.54,代码行数:29,代码来源:ddp_met.c

示例9: OVLReset

int OVLReset() {

    unsigned int delay_cnt = 0;
    static unsigned int cnt=0;
    printk("[DDP] OVLReset called %d \n", cnt++);

    DISP_REG_SET(DISP_REG_OVL_RST, 0x1);              // soft reset
    DISP_REG_SET(DISP_REG_OVL_RST, 0x0);
    while (((DISP_REG_GET(DISP_REG_OVL_FLOW_CTRL_DBG)&0x3ff) != 0x1) &&
            ((DISP_REG_GET(DISP_REG_OVL_FLOW_CTRL_DBG)&0x3ff) != 0x2)) {
        delay_cnt++;
        if(delay_cnt>10000)
        {
            printk("[DDP] error, OVLReset() timeout! \n");
            ddp_dump_info(DISP_MODULE_CONFIG);
            ddp_dump_info(DISP_MODULE_MUTEX);
            ddp_dump_info(DISP_MODULE_OVL);
            ddp_dump_info(DISP_MODULE_RDMA);
            disp_dump_reg(DISP_MODULE_OVL);
            smi_dumpDebugMsg();
            break;
        }
    }

#if 0
    DISP_REG_SET(DISP_REG_OVL_ROI_SIZE    , 0x00);           // clear regs
    DISP_REG_SET(DISP_REG_OVL_ROI_BGCLR   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_SRC_CON     , 0x00);

    DISP_REG_SET(DISP_REG_OVL_L0_CON      , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L0_SRCKEY   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L0_SRC_SIZE , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L0_OFFSET   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L0_ADDR     , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L0_PITCH    , 0x00);

    DISP_REG_SET(DISP_REG_OVL_L1_CON      , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L1_SRCKEY   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L1_SRC_SIZE , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L1_OFFSET   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L1_ADDR     , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L1_PITCH    , 0x00);

    DISP_REG_SET(DISP_REG_OVL_L2_CON      , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L2_SRCKEY   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L2_SRC_SIZE , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L2_OFFSET   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L2_ADDR     , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L2_PITCH    , 0x00);

    DISP_REG_SET(DISP_REG_OVL_L3_CON      , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L3_SRCKEY   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L3_SRC_SIZE , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L3_OFFSET   , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L3_ADDR     , 0x00);
    DISP_REG_SET(DISP_REG_OVL_L3_PITCH    , 0x00);
#endif

    return 0;
}
开发者ID:resbeut,项目名称:S5501-3.10,代码行数:60,代码来源:ddp_ovl.c

示例10: RDMAPollingInterrupt

static int RDMAPollingInterrupt(DISP_MODULE_ENUM module, int bit, int timeout)
{
    unsigned int idx = rdma_index(module);
    unsigned int cnt  = 0;
	unsigned int regval = 0;
    if( timeout <= 0)
    {
        while((DISP_REG_GET(idx*DISP_INDEX_OFFSET+ DISP_REG_RDMA_INT_STATUS) & bit)==0);
        cnt = 1;
    }
    else
    {
        // time need to update
        cnt = timeout*1000/100;
        while(cnt > 0)
        {
            cnt--;
		regval = DISP_REG_GET(idx*DISP_INDEX_OFFSET+ DISP_REG_RDMA_INT_STATUS);
            if(regval  & bit )
            {
            	DISP_CPU_REG_SET(idx*DISP_INDEX_OFFSET+ DISP_REG_RDMA_INT_STATUS, ~regval);
               break;
            }
            udelay(100);
        }
    }
    //should clear?
    DDPMSG(" RDMA%d polling interrupt ret =%d \n", idx, cnt);
    return cnt;
}
开发者ID:Scorpio92,项目名称:mediatek,代码行数:30,代码来源:ddp_rdma.c

示例11: WDMAReset

int WDMAReset(unsigned idx) {
    
    
    unsigned int delay_cnt = 0;
    static unsigned int wdma_timeout_cnt = 0;
    
    //WDMA_RST = 0x00;
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_RST , 0x01);            // soft reset
    while(((DISP_REG_GET(DISP_REG_OVL_FLOW_CTRL_DBG)&0x3ff) != 0x1) &&
          ((DISP_REG_GET(DISP_REG_OVL_FLOW_CTRL_DBG)&0x3ff) != 0x2))
    {
         delay_cnt++;
         if(delay_cnt>10000)
         {
             printk("[DDP] error, WDMAReset(%d) timeout! wdma_timeout_cnt=%d \n", idx, wdma_timeout_cnt++);
             WDMADumpHidenReg(idx);
             disp_dump_reg(DISP_MODULE_WDMA0);
             smi_dumpDebugMsg();
             break;
         }
    }
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_RST , 0x00);
    
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_CFG , 0x00);
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_SRC_SIZE , 0x00);
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_CLIP_SIZE , 0x00);
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_CLIP_COORD , 0x00);
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_DST_ADDR , 0x00);
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_DST_W_IN_BYTE , 0x00);
    DISP_REG_SET(idx*DISP_INDEX_OFFSET+DISP_REG_WDMA_ALPHA , 0x00);          // clear regs

    return 0;
}
开发者ID:Proshivalskiy,项目名称:MT6582_kernel_source,代码行数:33,代码来源:ddp_wdma.c

示例12: aal_config

static int aal_config(DISP_MODULE_ENUM module, disp_ddp_path_config *pConfig, void *cmdq)
{
	if (pConfig->dst_dirty) {
		int width, height;

		width = pConfig->dst_w;
		height = pConfig->dst_h;

		DISP_REG_SET(cmdq, DISP_AAL_SIZE, (width << 16) | height);
		DISP_REG_MASK(cmdq, DISP_AAL_CFG, 0x0, 0x1);	/* Disable relay mode */

		disp_aal_init(module, width, height, cmdq);

		DISP_REG_MASK(cmdq, DISP_AAL_EN, 0x1, 0x1);

		AAL_DBG("AAL_CFG = 0x%x, AAL_SIZE = 0x%x(%d, %d)",
			DISP_REG_GET(DISP_AAL_CFG), DISP_REG_GET(DISP_AAL_SIZE), width, height);
	}

	if (pConfig->ovl_dirty || pConfig->rdma_dirty) {
		disp_aal_notify_frame_dirty();
	}

	return 0;
}
开发者ID:vvmhz54,项目名称:ALPS.L1.MP6.V2.19_CENON6580_WE_1_L_KERNEL,代码行数:25,代码来源:ddp_aal.c

示例13: mutex_dump_analysis

static void mutex_dump_analysis(void)
{
    int i=0;
    int j=0;
    char mutex_module[512]={'\0'};
    char * p = NULL;
    int len = 0;
    DDPDUMP("==DISP Mutex Analysis==\n");
    for (i = 0; i < 5; i++)
    {
        p = mutex_module;
        len = 0;
        if( DISP_REG_GET(DISP_REG_CONFIG_MUTEX_MOD(i))!=0 &&
           ((DISP_REG_GET(DISP_REG_CONFIG_MUTEX_EN(i)+0x20*i)==1 &&
            DISP_REG_GET(DISP_REG_CONFIG_MUTEX_SOF(i)+0x20*i)!=SOF_SINGLE ) ||
            DISP_REG_GET(DISP_REG_CONFIG_MUTEX_SOF(i)+0x20*i)==SOF_SINGLE))
        {
          len = sprintf(p,"MUTEX%d :mode=%s,module=(",
            i, ddp_mutex_sof_to_string( DISP_REG_GET(DISP_REG_CONFIG_MUTEX_SOF(i))));
          p += len;
          for(j=11;j<=25;j++)
          {
              if((DISP_REG_GET(DISP_REG_CONFIG_MUTEX_MOD(i))>>j)&0x1)
              {
                 len = sprintf(p,"%s,", ddp_get_mutex_module_name(j));
                 p += len;
              }
          }
          DDPDUMP("%s)\n",mutex_module);
        }
    }
开发者ID:SelfImp,项目名称:m75,代码行数:31,代码来源:ddp_dump.c

示例14: disp_aal_on_end_of_frame

void disp_aal_on_end_of_frame(void)
{
    unsigned int intsta;
    int i;
    unsigned long flags;

    intsta = DISP_REG_GET(DISP_AAL_INTSTA);

    AAL_DBG("disp_aal_on_end_of_frame: intsta: 0x%x", intsta);
    if (intsta & 0x2) { /* End of frame */
        if (spin_trylock_irqsave(&g_aal_hist_lock, flags)) {
            DISP_CPU_REG_SET(DISP_AAL_INTSTA, (intsta & ~0x3));
        
            for (i = 0; i < AAL_HIST_BIN; i++) {
                g_aal_hist.maxHist[i] = DISP_REG_GET(DISP_AAL_STATUS_00 + (i << 2));
            }
            g_aal_hist_available = 1;

            /* Allow to disable interrupt */
            g_aal_dirty_frame_retrieved = 1;
            
            spin_unlock_irqrestore(&g_aal_hist_lock, flags);

            wake_up_interruptible(&g_aal_hist_wq);
        } else {
            /*
             * Histogram was not be retrieved, but it's OK.
             * Another interrupt will come until histogram available
             * See: disp_aal_set_interrupt()
             */
        }
    }
}
开发者ID:SelfImp,项目名称:m75,代码行数:33,代码来源:ddp_aal.c

示例15: disp_bls_config

int disp_bls_config(void)
{
#if !defined(MTK_AAL_SUPPORT) 
    struct cust_mt65xx_led *cust_led_list = get_cust_led_list();
    struct cust_mt65xx_led *cust = NULL;
    struct PWM_config *config_data = NULL;

    if(cust_led_list)
    {
        cust = &cust_led_list[MT65XX_LED_TYPE_LCD];
        if((strcmp(cust->name,"lcd-backlight") == 0) && (cust->mode == MT65XX_LED_MODE_CUST_BLS_PWM))
        {
            config_data = &cust->config_data;
            if (config_data->clock_source >= 0 && config_data->clock_source <= 3)
            {
		unsigned int regVal = DISP_REG_GET(CLK_CFG_1);
                DISP_REG_SET(CLK_CFG_1, (regVal & ~0x3) | config_data->clock_source);
                printf("disp_bls_config : CLK_CFG_1 0x%x => 0x%x\n", regVal, DISP_REG_GET(CLK_CFG_1));
            }
            gPWMDiv = (config_data->div == 0) ? PWM_DEFAULT_DIV_VALUE : config_data->div;
            gPWMDiv &= 0x3FF;
            printf("disp_bls_config : PWM config data (%d,%d)\n", config_data->clock_source, config_data->div);
        }
    }
    
    printf("[DDP] disp_bls_config : CG = 0x%x, BLS_EN = 0x%x, PWM_DUTY = %d\n", 
        DISP_REG_GET(DISP_REG_CONFIG_MMSYS_CG_CON0), 
        DISP_REG_GET(DISP_REG_BLS_EN),
        DISP_REG_GET(DISP_REG_BLS_PWM_DUTY));
#ifdef USE_DISP_BLS_MUTEX
    printf("[DDP] disp_bls_config : gBLSMutexID = %d\n", gBLSMutexID);
    DISP_REG_SET(DISP_REG_CONFIG_MUTEX_RST(gBLSMutexID), 1);
    DISP_REG_SET(DISP_REG_CONFIG_MUTEX_RST(gBLSMutexID), 0);
    DISP_REG_SET(DISP_REG_CONFIG_MUTEX_MOD(gBLSMutexID), 0x200);    // BLS
    DISP_REG_SET(DISP_REG_CONFIG_MUTEX_SOF(gBLSMutexID), 0);        // single mode
    DISP_REG_SET(DISP_REG_CONFIG_MUTEX_EN(gBLSMutexID), 1);

    if (disp_bls_get_mutex() == 0)
    {
#else
        DISP_REG_SET(DISP_REG_BLS_DEBUG, 0x3);
#endif

        DISP_REG_SET(DISP_REG_BLS_PWM_DUTY, 0);
        DISP_REG_SET(DISP_REG_BLS_PWM_CON, 0x0 | (gPWMDiv << 16));
        DISP_REG_SET(DISP_REG_BLS_EN, 0x00010000);

#ifdef USE_DISP_BLS_MUTEX
        if (disp_bls_release_mutex() == 0)
            return 0;
    }
    return -1;
#else
    DISP_REG_SET(DISP_REG_BLS_DEBUG, 0x0);
#endif

#endif
    return 0;
}
开发者ID:SteveHuang27,项目名称:Thunder-Kernel,代码行数:59,代码来源:ddp_bls.c


注:本文中的DISP_REG_GET函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。