drm/vmwgfx: Use drm_plane_mask() & co.
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Tue, 26 Jun 2018 19:47:16 +0000 (22:47 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Mon, 2 Jul 2018 15:45:56 +0000 (18:45 +0300)
Use drm_{plane,connector}_mask() where appropriate.

Cc: VMware Graphics <linux-graphics-maintainer@vmware.com>
Cc: Sinclair Yeh <syeh@vmware.com>
Cc: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180626194716.12522-10-ville.syrjala@linux.intel.com
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
drivers/gpu/drm/vmwgfx/vmwgfx_kms.c

index 6317672070cdc92eaa55d6d78622d570f5259331..bc5fbd39cf9afdda27072d5f6e5d0f698f92e543 100644 (file)
@@ -535,9 +535,9 @@ int vmw_du_crtc_atomic_check(struct drm_crtc *crtc,
                             struct drm_crtc_state *new_state)
 {
        struct vmw_display_unit *du = vmw_crtc_to_du(new_state->crtc);
-       int connector_mask = 1 << drm_connector_index(&du->connector);
+       int connector_mask = drm_connector_mask(&du->connector);
        bool has_primary = new_state->plane_mask &
-                          BIT(drm_plane_index(crtc->primary));
+                          drm_plane_mask(crtc->primary);
 
        /* We always want to have an active plane with an active CRTC */
        if (has_primary != new_state->enable)