Commit 3d6535cb authored by Hans de Goede's avatar Hans de Goede

drm/i915: Enable fastboot by default on Skylake and newer

We really want to have fastboot enabled by default to avoid an ugly
modeset during boot.

Rather then enabling it everywhere, lets start with enabling it on
Skylake and newer.
Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
Signed-off-by: default avatarMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190124130114.3967-1-maarten.lankhorst@linux.intel.com
parent 9407d3bd
...@@ -97,8 +97,10 @@ i915_param_named_unsafe(disable_power_well, int, 0400, ...@@ -97,8 +97,10 @@ i915_param_named_unsafe(disable_power_well, int, 0400,
i915_param_named_unsafe(enable_ips, int, 0600, "Enable IPS (default: true)"); i915_param_named_unsafe(enable_ips, int, 0600, "Enable IPS (default: true)");
i915_param_named(fastboot, bool, 0600, i915_param_named(fastboot, int, 0600,
"Try to skip unnecessary mode sets at boot time (default: false)"); "Try to skip unnecessary mode sets at boot time "
"(0=disabled, 1=enabled) "
"Default: -1 (use per-chip default)");
i915_param_named_unsafe(prefault_disable, bool, 0600, i915_param_named_unsafe(prefault_disable, bool, 0600,
"Disable page prefaulting for pread/pwrite/reloc (default:false). " "Disable page prefaulting for pread/pwrite/reloc (default:false). "
......
...@@ -63,10 +63,10 @@ struct drm_printer; ...@@ -63,10 +63,10 @@ struct drm_printer;
param(int, edp_vswing, 0) \ param(int, edp_vswing, 0) \
param(int, reset, 2) \ param(int, reset, 2) \
param(unsigned int, inject_load_failure, 0) \ param(unsigned int, inject_load_failure, 0) \
param(int, fastboot, -1) \
/* leave bools at the end to not create holes */ \ /* leave bools at the end to not create holes */ \
param(bool, alpha_support, IS_ENABLED(CONFIG_DRM_I915_ALPHA_SUPPORT)) \ param(bool, alpha_support, IS_ENABLED(CONFIG_DRM_I915_ALPHA_SUPPORT)) \
param(bool, enable_hangcheck, true) \ param(bool, enable_hangcheck, true) \
param(bool, fastboot, false) \
param(bool, prefault_disable, false) \ param(bool, prefault_disable, false) \
param(bool, load_detect_test, false) \ param(bool, load_detect_test, false) \
param(bool, force_reset_modeset_test, false) \ param(bool, force_reset_modeset_test, false) \
......
...@@ -11719,6 +11719,15 @@ pipe_config_err(bool adjust, const char *name, const char *format, ...) ...@@ -11719,6 +11719,15 @@ pipe_config_err(bool adjust, const char *name, const char *format, ...)
va_end(args); va_end(args);
} }
static bool fastboot_enabled(struct drm_i915_private *dev_priv)
{
if (i915_modparams.fastboot != -1)
return i915_modparams.fastboot;
/* Enable fastboot by default on Skylake and newer */
return INTEL_GEN(dev_priv) >= 9;
}
static bool static bool
intel_pipe_config_compare(struct drm_i915_private *dev_priv, intel_pipe_config_compare(struct drm_i915_private *dev_priv,
struct intel_crtc_state *current_config, struct intel_crtc_state *current_config,
...@@ -11730,7 +11739,7 @@ intel_pipe_config_compare(struct drm_i915_private *dev_priv, ...@@ -11730,7 +11739,7 @@ intel_pipe_config_compare(struct drm_i915_private *dev_priv,
(current_config->base.mode.private_flags & I915_MODE_FLAG_INHERITED) && (current_config->base.mode.private_flags & I915_MODE_FLAG_INHERITED) &&
!(pipe_config->base.mode.private_flags & I915_MODE_FLAG_INHERITED); !(pipe_config->base.mode.private_flags & I915_MODE_FLAG_INHERITED);
if (fixup_inherited && !i915_modparams.fastboot) { if (fixup_inherited && !fastboot_enabled(dev_priv)) {
DRM_DEBUG_KMS("initial modeset and fastboot not set\n"); DRM_DEBUG_KMS("initial modeset and fastboot not set\n");
ret = false; ret = false;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment