• Igor Torrente's avatar
    drm: vkms: Supports to the case where primary plane doesn't match the CRTC · bc0d7fde
    Igor Torrente authored
    We will remove the current assumption that the primary plane has the
    same size and position as CRTC and that the primary plane is the
    bottom-most in zpos order, or is even enabled. At least as far
    as the blending machinery is concerned.
    
    For that we will add CRTC dimension information to `vkms_crtc_state`
    and add a opaque black backgound color.
    
    Because now we need to fill the background, we had a loss in
    performance with this change. Results running the IGT[1] test
    `igt@kms_cursor_crc@pipe-a-cursor-512x512-onscreen` ten times:
    
    |                  Frametime                   |
    |:--------------------------------------------:|
    |  Implementation |  Previous |   This commit  |
    |:---------------:|:---------:|:--------------:|
    | frametime range |  5~18 ms  |     10~22 ms   |
    |     Average     |  8.47 ms  |     12.32 ms   |
    
    [1] IGT commit id: bc3f6833a12221a46659535dac06ebb312490eb4
    
    V6: Improve the commit description (Pekka Paalanen).
        Update some comments (Pekka Paalanen).
        Remove some fields from `vkms_crtc_state` and move where
        some variables are set (Pekka Paalanen).
    Reviewed-by: default avatarMelissa Wen <mwen@igalia.com>
    Signed-off-by: default avatarIgor Torrente <igormtorrente@gmail.com>
    Signed-off-by: default avatarMelissa Wen <melissa.srw@gmail.com>
    Link: https://patchwork.freedesktop.org/patch/msgid/20220905190811.25024-8-igormtorrente@gmail.com
    bc0d7fde
vkms_composer.c 8.67 KB