drm/i915: Make IS_GEN macros only take dev_priv
Saves 1416 bytes of .rodata strings. v2: Add parantheses around dev_priv. (Ville Syrjala) Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Reviewed-by: David Weinehall <david.weinehall@linux.intel.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Acked-by: Jani Nikula <jani.nikula@linux.intel.com> Acked-by: Chris Wilson <chris@chris-wilson.co.uk> Acked-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1476352990-2504-1-git-send-email-tvrtko.ursulin@linux.intel.com
This commit is contained in:
@@ -70,7 +70,7 @@ int i915_save_state(struct drm_device *dev)
|
||||
|
||||
i915_save_display(dev);
|
||||
|
||||
if (IS_GEN4(dev))
|
||||
if (IS_GEN4(dev_priv))
|
||||
pci_read_config_word(pdev, GCDGMBUS,
|
||||
&dev_priv->regfile.saveGCDGMBUS);
|
||||
|
||||
@@ -116,7 +116,7 @@ int i915_restore_state(struct drm_device *dev)
|
||||
|
||||
i915_gem_restore_fences(dev);
|
||||
|
||||
if (IS_GEN4(dev))
|
||||
if (IS_GEN4(dev_priv))
|
||||
pci_write_config_word(pdev, GCDGMBUS,
|
||||
dev_priv->regfile.saveGCDGMBUS);
|
||||
i915_restore_display(dev);
|
||||
|
Reference in New Issue
Block a user