• Sagar Arun Kamble's avatar
    drm/i915/bxt: Check BIOS RC6 setup before enabling RC6 · 274008e8
    Sagar Arun Kamble authored
    RC6 setup is shared between BIOS and Driver. BIOS sets up subset of RC6
    setup registers. If those are not setup Driver should not enable RC6.
    For implementing this, driver can check RC_CTRL0 and RC_CTRL1 values
    to know if BIOS has enabled HW/SW RC6.
    This will also enable user to control RC6 using BIOS settings alone.
    RC6 related instability can be avoided by disabling via BIOS settings
    till driver fixes it.
    
    v2: Had placed logic in gen8 function by mistake. Fixed it.
    Ensuring RPM is not enabled in case BIOS disabled RC6.
    
    v3: Need to disable RPM if RC6 is disabled due to BIOS settings. (Daniel)
    Runtime PM enabling happens before gen9_enable_rc6.
    Moved the updation of enable_rc6 parameter in intel_uncore_sanitize.
    
    v4: Added elaborate check for BIOS RC6 setup. Prepared check_pctx for bxt.
        (Imre)
    
    v5: Caching reserved stolen base and size in the driver private data.
        Reorganized RC6 setup check. Moved from gen9_enable_rc6 to
        intel_uncore_sanitize. (Imre)
    
    v6: Rebasing on the patch submitted by Imre that moves gem_init_stolen
        earlier in the load.
    
    v7: Removed PWRCTX_MAXCNT_VCSUNIT1 check as it applies to SKL. (Imre)
    
    v8: Fixed formatting and checkpatch issues. Fixed functional issue where
        RC6 ctx size check was missing. (Imre)
    
    Cc: Imre Deak <imre.deak@intel.com>
    Signed-off-by: default avatarSagar Arun Kamble <sagar.a.kamble@intel.com>
    Signed-off-by: default avatarImre Deak <imre.deak@intel.com>
    Link: http://patchwork.freedesktop.org/patch/msgid/1454697809-22113-1-git-send-email-sagar.a.kamble@intel.com
    274008e8
intel_drv.h 53.3 KB