Lines Matching refs:viu
365 priv->viu.vpp_line_in_length = hd_end_lines - hd_start_lines + 1; in meson_overlay_setup_scaler_params()
386 priv->viu.vpp_vsc_start_phase_step = ratio_y << 6; in meson_overlay_setup_scaler_params()
388 priv->viu.vpp_vsc_ini_phase = vphase << 8; in meson_overlay_setup_scaler_params()
389 priv->viu.vpp_vsc_phase_ctrl = (1 << 13) | (4 << 8) | in meson_overlay_setup_scaler_params()
392 priv->viu.vd1_if0_luma_x0 = VD_X_START(hd_start_lines) | in meson_overlay_setup_scaler_params()
394 priv->viu.vd1_if0_chroma_x0 = VD_X_START(hd_start_lines >> 1) | in meson_overlay_setup_scaler_params()
397 priv->viu.viu_vd1_fmt_w = in meson_overlay_setup_scaler_params()
401 priv->viu.vd1_afbc_vd_cfmt_w = in meson_overlay_setup_scaler_params()
405 priv->viu.vd1_afbc_vd_cfmt_h = in meson_overlay_setup_scaler_params()
408 priv->viu.vd1_afbc_mif_hor_scope = AFBC_MIF_BLK_BGN_H(afbc_left / 32) | in meson_overlay_setup_scaler_params()
411 priv->viu.vd1_afbc_mif_ver_scope = AFBC_MIF_BLK_BGN_V(afbc_top / 4) | in meson_overlay_setup_scaler_params()
414 priv->viu.vd1_afbc_size_out = in meson_overlay_setup_scaler_params()
418 priv->viu.vd1_afbc_pixel_hor_scope = in meson_overlay_setup_scaler_params()
422 priv->viu.vd1_afbc_pixel_ver_scope = in meson_overlay_setup_scaler_params()
426 priv->viu.vd1_afbc_size_in = in meson_overlay_setup_scaler_params()
430 priv->viu.vd1_if0_luma_y0 = VD_Y_START(vd_start_lines) | in meson_overlay_setup_scaler_params()
433 priv->viu.vd1_if0_chroma_y0 = VD_Y_START(vd_start_lines >> 1) | in meson_overlay_setup_scaler_params()
436 priv->viu.vpp_pic_in_height = h_in; in meson_overlay_setup_scaler_params()
438 priv->viu.vpp_postblend_vd1_h_start_end = VD_H_START(hsc_startp) | in meson_overlay_setup_scaler_params()
440 priv->viu.vpp_blend_vd2_h_start_end = VD_H_START(hd_start_lines) | in meson_overlay_setup_scaler_params()
442 priv->viu.vpp_hsc_region12_startp = VD_REGION13_END(0) | in meson_overlay_setup_scaler_params()
444 priv->viu.vpp_hsc_region34_startp = in meson_overlay_setup_scaler_params()
447 priv->viu.vpp_hsc_region4_endp = hsc_endp - hsc_startp; in meson_overlay_setup_scaler_params()
448 priv->viu.vpp_hsc_start_phase_step = ratio_x << 6; in meson_overlay_setup_scaler_params()
449 priv->viu.vpp_hsc_region1_phase_slope = 0; in meson_overlay_setup_scaler_params()
450 priv->viu.vpp_hsc_region3_phase_slope = 0; in meson_overlay_setup_scaler_params()
451 priv->viu.vpp_hsc_phase_ctrl = (1 << 21) | (4 << 16); in meson_overlay_setup_scaler_params()
453 priv->viu.vpp_line_in_length = hd_end_lines - hd_start_lines + 1; in meson_overlay_setup_scaler_params()
454 priv->viu.vpp_preblend_h_size = hd_end_lines - hd_start_lines + 1; in meson_overlay_setup_scaler_params()
456 priv->viu.vpp_postblend_vd1_v_start_end = VD_V_START(vsc_startp) | in meson_overlay_setup_scaler_params()
458 priv->viu.vpp_blend_vd2_v_start_end = in meson_overlay_setup_scaler_params()
462 priv->viu.vpp_vsc_region12_startp = 0; in meson_overlay_setup_scaler_params()
463 priv->viu.vpp_vsc_region34_startp = in meson_overlay_setup_scaler_params()
466 priv->viu.vpp_vsc_region4_endp = vsc_endp - vsc_startp; in meson_overlay_setup_scaler_params()
467 priv->viu.vpp_vsc_start_phase_step = ratio_y << 6; in meson_overlay_setup_scaler_params()
490 priv->viu.vd1_afbc = true; in meson_overlay_atomic_update()
492 priv->viu.vd1_afbc_mode = AFBC_MIF_URGENT(3) | in meson_overlay_atomic_update()
498 priv->viu.vd1_afbc_mode |= AFBC_BLK_MEM_MODE; in meson_overlay_atomic_update()
502 priv->viu.vd1_afbc_mode |= AFBC_SCATTER_MODE; in meson_overlay_atomic_update()
504 priv->viu.vd1_afbc_en = 0x1600 | AFBC_DEC_ENABLE; in meson_overlay_atomic_update()
506 priv->viu.vd1_afbc_conv_ctrl = AFBC_CONV_LBUF_LEN(256); in meson_overlay_atomic_update()
508 priv->viu.vd1_afbc_dec_def_color = AFBC_DEF_COLOR_Y(1023); in meson_overlay_atomic_update()
511 priv->viu.vd1_afbc_vd_cfmt_ctrl = AFBC_HORZ_RPT_PIXEL0 | in meson_overlay_atomic_update()
522 priv->viu.vd1_afbc_mode |= in meson_overlay_atomic_update()
524 priv->viu.vd1_afbc_dec_def_color |= in meson_overlay_atomic_update()
529 priv->viu.vd1_afbc_dec_def_color |= in meson_overlay_atomic_update()
535 priv->viu.vd1_if0_gen_reg = 0; in meson_overlay_atomic_update()
536 priv->viu.vd1_if0_canvas0 = 0; in meson_overlay_atomic_update()
537 priv->viu.viu_vd1_fmt_ctrl = 0; in meson_overlay_atomic_update()
539 priv->viu.vd1_afbc = false; in meson_overlay_atomic_update()
541 priv->viu.vd1_if0_gen_reg = VD_URGENT_CHROMA | in meson_overlay_atomic_update()
551 priv->viu.vd1_if0_repeat_loop = 0; in meson_overlay_atomic_update()
552 priv->viu.vd1_if0_luma0_rpt_pat = interlace_mode ? 8 : 0; in meson_overlay_atomic_update()
553 priv->viu.vd1_if0_chroma0_rpt_pat = interlace_mode ? 8 : 0; in meson_overlay_atomic_update()
554 priv->viu.vd1_range_map_y = 0; in meson_overlay_atomic_update()
555 priv->viu.vd1_range_map_cb = 0; in meson_overlay_atomic_update()
556 priv->viu.vd1_range_map_cr = 0; in meson_overlay_atomic_update()
559 priv->viu.vd1_if0_gen_reg2 = 0; in meson_overlay_atomic_update()
560 priv->viu.viu_vd1_fmt_ctrl = 0; in meson_overlay_atomic_update()
566 priv->viu.vd1_if0_gen_reg |= VD_BYTES_PER_PIXEL(1); in meson_overlay_atomic_update()
567 priv->viu.vd1_if0_canvas0 = in meson_overlay_atomic_update()
571 priv->viu.viu_vd1_fmt_ctrl = VD_HORZ_Y_C_RATIO(1) | /* /2 */ in meson_overlay_atomic_update()
580 priv->viu.vd1_if0_gen_reg |= VD_SEPARATE_EN; in meson_overlay_atomic_update()
581 priv->viu.vd1_if0_canvas0 = in meson_overlay_atomic_update()
586 priv->viu.vd1_if0_gen_reg2 = VD_COLOR_MAP(1); in meson_overlay_atomic_update()
588 priv->viu.vd1_if0_gen_reg2 = VD_COLOR_MAP(2); in meson_overlay_atomic_update()
589 priv->viu.viu_vd1_fmt_ctrl = VD_HORZ_Y_C_RATIO(1) | /* /2 */ in meson_overlay_atomic_update()
601 priv->viu.vd1_if0_gen_reg |= VD_SEPARATE_EN; in meson_overlay_atomic_update()
602 priv->viu.vd1_if0_canvas0 = in meson_overlay_atomic_update()
608 priv->viu.viu_vd1_fmt_ctrl = in meson_overlay_atomic_update()
617 priv->viu.viu_vd1_fmt_ctrl = in meson_overlay_atomic_update()
626 priv->viu.viu_vd1_fmt_ctrl = in meson_overlay_atomic_update()
635 priv->viu.viu_vd1_fmt_ctrl = in meson_overlay_atomic_update()
648 priv->viu.vd1_planes = fb->format->num_planes; in meson_overlay_atomic_update()
650 switch (priv->viu.vd1_planes) { in meson_overlay_atomic_update()
653 priv->viu.vd1_addr2 = gem->paddr + fb->offsets[2]; in meson_overlay_atomic_update()
654 priv->viu.vd1_stride2 = fb->pitches[2]; in meson_overlay_atomic_update()
655 priv->viu.vd1_height2 = in meson_overlay_atomic_update()
659 priv->viu.vd1_addr2, in meson_overlay_atomic_update()
660 priv->viu.vd1_stride2, in meson_overlay_atomic_update()
661 priv->viu.vd1_height2); in meson_overlay_atomic_update()
665 priv->viu.vd1_addr1 = gem->paddr + fb->offsets[1]; in meson_overlay_atomic_update()
666 priv->viu.vd1_stride1 = fb->pitches[1]; in meson_overlay_atomic_update()
667 priv->viu.vd1_height1 = in meson_overlay_atomic_update()
671 priv->viu.vd1_addr1, in meson_overlay_atomic_update()
672 priv->viu.vd1_stride1, in meson_overlay_atomic_update()
673 priv->viu.vd1_height1); in meson_overlay_atomic_update()
677 priv->viu.vd1_addr0 = gem->paddr + fb->offsets[0]; in meson_overlay_atomic_update()
678 priv->viu.vd1_stride0 = fb->pitches[0]; in meson_overlay_atomic_update()
679 priv->viu.vd1_height0 = in meson_overlay_atomic_update()
683 priv->viu.vd1_addr0, in meson_overlay_atomic_update()
684 priv->viu.vd1_stride0, in meson_overlay_atomic_update()
685 priv->viu.vd1_height0); in meson_overlay_atomic_update()
688 if (priv->viu.vd1_afbc) { in meson_overlay_atomic_update()
689 if (priv->viu.vd1_afbc_mode & AFBC_SCATTER_MODE) { in meson_overlay_atomic_update()
695 priv->viu.vd1_afbc_head_addr = priv->viu.vd1_addr0 >> 4; in meson_overlay_atomic_update()
696 priv->viu.vd1_afbc_body_addr = 0; in meson_overlay_atomic_update()
703 if (priv->viu.vd1_afbc_mode & AFBC_BLK_MEM_MODE) in meson_overlay_atomic_update()
706 body_size = (ALIGN(priv->viu.vd1_stride0, 64) / 64) * in meson_overlay_atomic_update()
707 (ALIGN(priv->viu.vd1_height0, 32) / 32) * in meson_overlay_atomic_update()
710 priv->viu.vd1_afbc_body_addr = priv->viu.vd1_addr0 >> 4; in meson_overlay_atomic_update()
712 priv->viu.vd1_afbc_head_addr = (priv->viu.vd1_addr0 + in meson_overlay_atomic_update()
717 priv->viu.vd1_enabled = true; in meson_overlay_atomic_update()
732 priv->viu.vd1_enabled = false; in meson_overlay_atomic_disable()