diff options
author | Chris Wilson <[email protected]> | 2019-11-20 18:22:09 +0000 |
---|---|---|
committer | Joonas Lahtinen <[email protected]> | 2019-11-25 15:28:38 +0200 |
commit | 732f9ca4a737aea3983ad86007e88e7fffe8cd6a (patch) | |
tree | f47d95072f8756133e39e88a841220f4d5a63faf | |
parent | 03a2a606066cf8af7a090669848e4e84351ded06 (diff) |
drm/i915/gt: Fixup config ifdeffery for pm_suspend_target_state
pm_suspend_target_state is declared under CONFIG_PM_SLEEP but only
defined under CONFIG_SUSPEND. Play safe and only use the symbol if it is
both declared and defined.
Reported-by: [email protected]
Signed-off-by: Chris Wilson <[email protected]>
Fixes: a70a9e998e8e ("drm/i915: Defer rc6 shutdown to suspend_late")
Cc: Andi Shyti <[email protected]>
Cc: Joonas Lahtinen <[email protected]>
Reviewed-by: Joonas Lahtinen <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Signed-off-by: Joonas Lahtinen <[email protected]>
-rw-r--r-- | drivers/gpu/drm/i915/gt/intel_gt_pm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/gt/intel_gt_pm.c b/drivers/gpu/drm/i915/gt/intel_gt_pm.c index 6187cdd06646..7917cc348375 100644 --- a/drivers/gpu/drm/i915/gt/intel_gt_pm.c +++ b/drivers/gpu/drm/i915/gt/intel_gt_pm.c @@ -272,7 +272,7 @@ void intel_gt_suspend_prepare(struct intel_gt *gt) static suspend_state_t pm_suspend_target(void) { -#if IS_ENABLED(CONFIG_PM_SLEEP) +#if IS_ENABLED(CONFIG_SUSPEND) && IS_ENABLED(CONFIG_PM_SLEEP) return pm_suspend_target_state; #else return PM_SUSPEND_TO_IDLE; |