diff mbox

[09/22] drm/i915: Use intel_best_encoder() directly

Message ID 1352741580-12141-10-git-send-email-ville.syrjala@linux.intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Ville Syrjälä Nov. 12, 2012, 5:32 p.m. UTC
From: Ville Syrjälä <ville.syrjala@linux.intel.com>

All connectors use intel_best_encoder() as their best_encoder() func, so
just call it directly w/o the indirection.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_atomic.c |   10 ++--------
 1 files changed, 2 insertions(+), 8 deletions(-)
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/intel_atomic.c b/drivers/gpu/drm/i915/intel_atomic.c
index 6dd07fb..e58ec3f 100644
--- a/drivers/gpu/drm/i915/intel_atomic.c
+++ b/drivers/gpu/drm/i915/intel_atomic.c
@@ -152,8 +152,6 @@  static int process_connectors(struct intel_crtc_state *s, const uint32_t *ids, i
 	int i;
 
 	for (i = 0; i < count_ids; i++) {
-		struct drm_encoder *encoder;
-		const struct drm_connector_helper_funcs *connector_funcs;
 		struct drm_mode_object *obj;
 		int j;
 
@@ -169,9 +167,8 @@  static int process_connectors(struct intel_crtc_state *s, const uint32_t *ids, i
 		}
 
 		connector = obj_to_connector(obj);
-		connector_funcs = connector->helper_private;
 
-		encoder = connector_funcs->best_encoder(connector);
+		encoder = intel_best_encoder(connector);
 
 		if (!drm_encoder_crtc_ok(encoder, crtc))
 			return -EINVAL;
@@ -180,9 +177,6 @@  static int process_connectors(struct intel_crtc_state *s, const uint32_t *ids, i
 	}
 
 	list_for_each_entry(connector, &dev->mode_config.connector_list, head) {
-		const struct drm_connector_helper_funcs *connector_funcs =
-			connector->helper_private;
-
 		for (i = 0; i < count_ids; i++) {
 			if (connector == connectors[i])
 				break;
@@ -196,7 +190,7 @@  static int process_connectors(struct intel_crtc_state *s, const uint32_t *ids, i
 			continue;
 		}
 
-		encoder = connector_funcs->best_encoder(connector);
+		encoder = intel_best_encoder(connector);
 
 		connector->encoder = encoder;
 		encoder->crtc = crtc;