• Ville Syrjälä's avatar
    drm/i915: Support variable cursor height on ivb+ · 024faac7
    Ville Syrjälä authored
    IVB introduced the CUR_FBC_CTL register which allows reducing the cursor
    height down to 8 lines from the otherwise square cursor dimensions.
    Implement support for it. CUR_FBC_CTL can't be used when the cursor
    is rotated.
    
    Commandeer the otherwise unused cursor->cursor.size to track the
    current value of CUR_FBC_CTL to optimize away redundant CUR_FBC_CTL
    writes, and to notice when we need to arm the update via CURBASE if
    just CUR_FBC_CTL changes.
    
    v2: Reverse the gen check to make it sane
    v3: Only enable CUR_FBC_CTL when cursor is enabled, adapt to
        earlier code changes which means we now actually turn off
        the cursor when we're supposed to unlike v2
    v4: Add a comment about rotation vs. CUR_FBC_CTL,
        rebase due to 'dirty' (Chris)
    v5: Rebase to the atomic world
        Handle 180 degree rotation
        Add HAS_CUR_FBC()
    v6: Rebase
    v7: Rebase due to I915_WRITE_FW/uncore.lock
        s/size/fbc_ctl/
    Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
    Link: http://patchwork.freedesktop.org/patch/msgid/20170327185546.2977-12-ville.syrjala@linux.intel.comReviewed-by: default avatarImre Deak <imre.deak@intel.com>
    024faac7
i915_drv.h 120 KB