aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorArchit Taneja <architt@codeaurora.org>2015-09-07 11:45:43 +0530
committerSrinivas Kandagatla <srinivas.kandagatla@linaro.org>2015-11-17 09:22:34 +0000
commit3fd9af510abdff3fcfc0ad87d4ae528df438cf46 (patch)
tree9bafea496f5b01761094b1b836b36a06483138f7 /drivers/gpu/drm
parentd08d80511aa5eda0e2a60ac5cd252c4e4e6e3a4a (diff)
HACK: drm/i2c: adv7511: Remove hotplug event handling
Hotplug detect is currently unstable. Temporarily remove the driver's hotplug handling code. Signed-off-by: Archit Taneja <architt@codeaurora.org>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/i2c/adv7511.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i2c/adv7511.c b/drivers/gpu/drm/i2c/adv7511.c
index 6f2c32c2be4f..7dddb9c159e9 100644
--- a/drivers/gpu/drm/i2c/adv7511.c
+++ b/drivers/gpu/drm/i2c/adv7511.c
@@ -24,6 +24,8 @@
#include "adv7511.h"
+#define HPD_ENABLE 0
+
static struct adv7511 *encoder_to_adv7511(struct drm_encoder *encoder)
{
return to_encoder_slave(encoder)->slave_priv;
@@ -482,6 +484,7 @@ static void adv7511_power_off(struct adv7511 *adv7511)
* Interrupt and hotplug detection
*/
+#if HPD_ENABLE
static bool adv7511_hpd(struct adv7511 *adv7511)
{
unsigned int irq0;
@@ -499,6 +502,7 @@ static bool adv7511_hpd(struct adv7511 *adv7511)
return false;
}
+#endif
static int adv7511_irq_process(struct adv7511 *adv7511, bool process_hpd)
{
@@ -681,7 +685,9 @@ adv7511_detect(struct adv7511 *adv7511,
{
enum drm_connector_status status;
unsigned int val;
+#if HPD_ENABLE
bool hpd;
+#endif
int ret;
ret = regmap_read(adv7511->regmap, ADV7511_REG_STATUS, &val);
@@ -693,6 +699,7 @@ adv7511_detect(struct adv7511 *adv7511,
else
status = connector_status_disconnected;
+#if HPD_ENABLE
hpd = adv7511_hpd(adv7511);
/* The chip resets itself when the cable is disconnected, so in case
@@ -711,6 +718,7 @@ adv7511_detect(struct adv7511 *adv7511,
ADV7511_REG_POWER2_HDP_SRC_MASK,
ADV7511_REG_POWER2_HDP_SRC_BOTH);
}
+#endif
adv7511->status = status;
return status;
@@ -972,6 +980,11 @@ static void adv7533_bridge_post_disable(struct drm_bridge *bridge)
{
struct adv7511 *adv = bridge_to_adv7511(bridge);
+#if HPD_ENABLE
+ if (!adv7511->powered)
+ return;
+#endif
+
adv7511_power_off(adv);
}
@@ -1046,7 +1059,10 @@ static int adv7533_bridge_attach(struct drm_bridge *bridge)
return -ENODEV;
}
+#if HPD_ENABLE
adv->connector.polled = DRM_CONNECTOR_POLL_HPD;
+#endif
+
ret = drm_connector_init(bridge->dev, &adv->connector,
&adv7533_connector_funcs, DRM_MODE_CONNECTOR_HDMIA);
if (ret) {
@@ -1058,7 +1074,9 @@ static int adv7533_bridge_attach(struct drm_bridge *bridge)
drm_connector_register(&adv->connector);
drm_mode_connector_attach_encoder(&adv->connector, adv->encoder);
+#if HPD_ENABLE
drm_helper_hpd_irq_event(adv->connector.dev);
+#endif
adv7533_attach_dsi(adv);