drm/rockchip: cdn-dp: add hdmi-codec jack event

Use HDMI connection / disconnection notifications to update an ALSA
jack object.

Change-Id: Ia18537be1ddb899b7ac490560bf91d7de83eae02
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
This commit is contained in:
Chris Zhong
2016-11-24 14:22:51 +08:00
committed by Huang, Tao
parent bbf5af445f
commit 5da8af22eb

View File

@@ -23,6 +23,7 @@
#include <linux/component.h>
#include <linux/extcon.h>
#include <linux/firmware.h>
#include <linux/hdmi-notifier.h>
#include <linux/regmap.h>
#include <linux/reset.h>
#include <linux/mfd/syscon.h>
@@ -653,6 +654,8 @@ static void cdn_dp_encoder_enable(struct drm_encoder *encoder)
}
out:
mutex_unlock(&dp->lock);
if (!ret)
hdmi_event_connect(dp->dev);
}
static void cdn_dp_encoder_disable(struct drm_encoder *encoder)
@@ -669,6 +672,7 @@ static void cdn_dp_encoder_disable(struct drm_encoder *encoder)
}
}
mutex_unlock(&dp->lock);
hdmi_event_disconnect(dp->dev);
/*
* In the following 2 cases, we need to run the event_work to re-enable