drm/rockchip: vop: correct plane state

Before this commit, cat /d/dri/0/summary maybe appear the following
info, in fact the win1-0 state is DISABLED.

VOP [ff370000.vop]: ACTIVE
    Connector: HDMI-A
        bus_format[2025]: YUV8_1X24
        overlay_mode[1] output_mode[f] color_space[3]
    Display mode: 3840x2160p30
        clk[297000] real_clk[297000] type[48] flag[5]
        H: 3840 4016 4104 4400
        V: 2160 2168 2178 2250
    win0-0: ACTIVE
        format: AB24 little-endian (0x34324241) SDR[0] color_space[0]
        csc: y2r[0] r2r[0] r2y[1] csc mode[1]
        zpos: 0
        src: pos[0x0] rect[1280x720]
        dst: pos[0x0] rect[3840x2160]
        buf[0]: addr: 0x0000000002e6c000 pitch: 5120 offset: 0
    win1-0: ACTIVE
    win2-0: DISABLED

Change-Id: I5aaf7b0d1366253bdd56d7a40ecf157c3f95e4bc
Signed-off-by: Sandy Huang <hjc@rock-chips.com>
This commit is contained in:
Sandy Huang
2020-01-13 15:51:14 +08:00
committed by Tao Huang
parent 189c4d2432
commit 769a782ce1

View File

@@ -1554,8 +1554,10 @@ static int vop_plane_atomic_check(struct drm_plane *plane,
void *kvaddr;
crtc = crtc ? crtc : plane->state->crtc;
if (!crtc || !fb)
if (!crtc || !fb) {
plane->state->visible = false;
return 0;
}
crtc_state = drm_atomic_get_existing_crtc_state(state->state, crtc);
if (WARN_ON(!crtc_state))