aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/i915/i915_gem.c2
-rw-r--r--drivers/gpu/drm/i915/intel_sdvo.c15
2 files changed, 7 insertions, 10 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index cf4ffbee1c00..bced9b25c71e 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -2400,7 +2400,7 @@ i915_gem_clear_fence_reg(struct drm_gem_object *obj)
2400 I915_WRITE64(FENCE_REG_965_0 + (obj_priv->fence_reg * 8), 0); 2400 I915_WRITE64(FENCE_REG_965_0 + (obj_priv->fence_reg * 8), 0);
2401 break; 2401 break;
2402 case 3: 2402 case 3:
2403 if (obj_priv->fence_reg > 8) 2403 if (obj_priv->fence_reg >= 8)
2404 fence_reg = FENCE_REG_945_8 + (obj_priv->fence_reg - 8) * 4; 2404 fence_reg = FENCE_REG_945_8 + (obj_priv->fence_reg - 8) * 4;
2405 else 2405 else
2406 case 2: 2406 case 2:
diff --git a/drivers/gpu/drm/i915/intel_sdvo.c b/drivers/gpu/drm/i915/intel_sdvo.c
index e8e902d614ed..ee73e428a84a 100644
--- a/drivers/gpu/drm/i915/intel_sdvo.c
+++ b/drivers/gpu/drm/i915/intel_sdvo.c
@@ -2170,8 +2170,7 @@ intel_sdvo_tv_init(struct intel_sdvo *intel_sdvo, int type)
2170 return true; 2170 return true;
2171 2171
2172err: 2172err:
2173 intel_sdvo_destroy_enhance_property(connector); 2173 intel_sdvo_destroy(connector);
2174 kfree(intel_sdvo_connector);
2175 return false; 2174 return false;
2176} 2175}
2177 2176
@@ -2243,8 +2242,7 @@ intel_sdvo_lvds_init(struct intel_sdvo *intel_sdvo, int device)
2243 return true; 2242 return true;
2244 2243
2245err: 2244err:
2246 intel_sdvo_destroy_enhance_property(connector); 2245 intel_sdvo_destroy(connector);
2247 kfree(intel_sdvo_connector);
2248 return false; 2246 return false;
2249} 2247}
2250 2248
@@ -2522,11 +2520,10 @@ static bool intel_sdvo_create_enhance_property(struct intel_sdvo *intel_sdvo,
2522 uint16_t response; 2520 uint16_t response;
2523 } enhancements; 2521 } enhancements;
2524 2522
2525 if (!intel_sdvo_get_value(intel_sdvo, 2523 enhancements.response = 0;
2526 SDVO_CMD_GET_SUPPORTED_ENHANCEMENTS, 2524 intel_sdvo_get_value(intel_sdvo,
2527 &enhancements, sizeof(enhancements))) 2525 SDVO_CMD_GET_SUPPORTED_ENHANCEMENTS,
2528 return false; 2526 &enhancements, sizeof(enhancements));
2529
2530 if (enhancements.response == 0) { 2527 if (enhancements.response == 0) {
2531 DRM_DEBUG_KMS("No enhancement is supported\n"); 2528 DRM_DEBUG_KMS("No enhancement is supported\n");
2532 return true; 2529 return true;