diff options
author | José Roberto de Souza <jose.souza@intel.com> | 2018-12-01 00:20:47 +0100 |
---|---|---|
committer | José Roberto de Souza <jose.souza@intel.com> | 2018-12-03 23:55:39 +0100 |
commit | e1bf094b3c7514934168dcb69f18b65aacb5a953 (patch) | |
tree | fd8e655c0df5570871894783fd805f4bb1e6e8f6 /drivers/gpu/drm/i915/intel_fbdev.c | |
parent | drm/i915/dp: Fix link compute m_n calc for DSC (diff) | |
download | linux-e1bf094b3c7514934168dcb69f18b65aacb5a953.tar.xz linux-e1bf094b3c7514934168dcb69f18b65aacb5a953.zip |
drm/i915: Add HAS_DISPLAY() and use it
Right now it is decided if GEN has display by checking the num_pipes,
so lets make it explicit and use a macro.
Cc: Jani Nikula <jani.nikula@intel.com>
Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20181130232048.14216-1-jose.souza@intel.com
Diffstat (limited to 'drivers/gpu/drm/i915/intel_fbdev.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_fbdev.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_fbdev.c b/drivers/gpu/drm/i915/intel_fbdev.c index 2480c7d6edee..fb5bb5b32a60 100644 --- a/drivers/gpu/drm/i915/intel_fbdev.c +++ b/drivers/gpu/drm/i915/intel_fbdev.c @@ -672,7 +672,7 @@ int intel_fbdev_init(struct drm_device *dev) struct intel_fbdev *ifbdev; int ret; - if (WARN_ON(INTEL_INFO(dev_priv)->num_pipes == 0)) + if (WARN_ON(!HAS_DISPLAY(dev_priv))) return -ENODEV; ifbdev = kzalloc(sizeof(struct intel_fbdev), GFP_KERNEL); |