public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Paulo Zanoni <przanoni@gmail.com>
To: intel-gfx@lists.freedesktop.org
Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
Subject: [PATCH 3/4] drm/i915: remove redundant is_edp() check
Date: Tue, 22 Apr 2014 19:55:44 -0300	[thread overview]
Message-ID: <1398207345-1865-3-git-send-email-przanoni@gmail.com> (raw)
In-Reply-To: <1398207345-1865-1-git-send-email-przanoni@gmail.com>

From: Paulo Zanoni <paulo.r.zanoni@intel.com>

If intel_edp_init_connector() returns false, then we know that
is_edp() is true because of the early return at
intel_edp_init_connector(). So remove the redundant check.

Change proposed by Chris on his review to "drm/i915: get power domain
in case the BIOS enabled eDP VDD".

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 drivers/gpu/drm/i915/intel_dp.c | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index b385b03..a25f708 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -3958,12 +3958,10 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,
 
 	if (!intel_edp_init_connector(intel_dp, intel_connector, &power_seq)) {
 		drm_dp_aux_unregister_i2c_bus(&intel_dp->aux);
-		if (is_edp(intel_dp)) {
-			cancel_delayed_work_sync(&intel_dp->panel_vdd_work);
-			mutex_lock(&dev->mode_config.mutex);
-			edp_panel_vdd_off_sync(intel_dp);
-			mutex_unlock(&dev->mode_config.mutex);
-		}
+		cancel_delayed_work_sync(&intel_dp->panel_vdd_work);
+		mutex_lock(&dev->mode_config.mutex);
+		edp_panel_vdd_off_sync(intel_dp);
+		mutex_unlock(&dev->mode_config.mutex);
 		drm_sysfs_connector_remove(connector);
 		drm_connector_cleanup(connector);
 		return false;
-- 
1.9.0

  parent reply	other threads:[~2014-04-22 22:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-09 21:47 [PATCH] drm/i915: get power domain in case the BIOS enabled eDP VDD Paulo Zanoni
2014-04-10  7:21 ` Daniel Vetter
2014-04-10  7:36   ` Chris Wilson
2014-04-11 13:21 ` Daniel Vetter
2014-04-22 22:55   ` [PATCH 1/4] " Paulo Zanoni
2014-04-22 22:55     ` [PATCH 2/4] drm/i915: add intel_dp_power_get/put Paulo Zanoni
2014-04-23  9:45       ` Ville Syrjälä
2014-04-24 13:49         ` [PATCH 2/4] drm/i915: add intel_encoder_power_get/put Paulo Zanoni
2014-04-24 14:11           ` Ville Syrjälä
2014-04-24 15:14             ` Daniel Vetter
2014-04-22 22:55     ` Paulo Zanoni [this message]
2014-04-22 22:55     ` [PATCH 4/4] drm/i915: remove useless runtime PM get call Paulo Zanoni
2014-04-23  9:52       ` Ville Syrjälä
2014-04-24 13:50         ` [PATCH 4/4] drm/i915: remove useless runtime PM get calls Paulo Zanoni
2014-04-24 14:05           ` Ville Syrjälä
2014-07-14 15:59             ` Daniel Vetter
2014-04-23  6:59     ` [PATCH 1/4] drm/i915: get power domain in case the BIOS enabled eDP VDD Daniel Vetter
2014-04-23 11:02     ` Jani Nikula

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1398207345-1865-3-git-send-email-przanoni@gmail.com \
    --to=przanoni@gmail.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=paulo.r.zanoni@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox