summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/msm_ext_display.h (renamed from include/linux/msm_hdmi.h)54
1 files changed, 32 insertions, 22 deletions
diff --git a/include/linux/msm_hdmi.h b/include/linux/msm_ext_display.h
index 45b206b86765..eb90b49477cc 100644
--- a/include/linux/msm_hdmi.h
+++ b/include/linux/msm_ext_display.h
@@ -1,6 +1,6 @@
-/* include/linux/msm_hdmi.h
+/* include/linux/msm_ext_display.h
*
- * Copyright (c) 2014-2015 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2014-2016 The Linux Foundation. All rights reserved.
*
* This software is licensed under the terms of the GNU General Public
* License version 2, as published by the Free Software Foundation, and
@@ -11,32 +11,32 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*/
-#ifndef _MSM_HDMI_H_
-#define _MSM_HDMI_H_
+#ifndef _MSM_EXT_DISPLAY_H_
+#define _MSM_EXT_DISPLAY_H_
#include <linux/device.h>
#include <linux/platform_device.h>
/*
- * HDMI cable notify handler sturcture.
+ * External display cable notify handler structure.
* link A link for the linked list
- * status Current status of HDMI cable connection
+ * status Current status of HDMI/DP cable connection
* hpd_notify Callback function to provide cable status
*/
-struct hdmi_cable_notify {
+struct ext_disp_cable_notify {
struct list_head link;
int status;
- void (*hpd_notify) (struct hdmi_cable_notify *h);
+ void (*hpd_notify)(struct ext_disp_cable_notify *h);
};
-struct msm_hdmi_audio_edid_blk {
+struct msm_ext_disp_audio_edid_blk {
u8 *audio_data_blk;
unsigned int audio_data_blk_size; /* in bytes */
u8 *spk_alloc_data_blk;
unsigned int spk_alloc_data_blk_size; /* in bytes */
};
-struct msm_hdmi_audio_setup_params {
+struct msm_ext_disp_audio_setup_params {
u32 sample_rate_hz;
u32 num_of_channels;
u32 channel_allocation;
@@ -45,14 +45,24 @@ struct msm_hdmi_audio_setup_params {
u32 sample_present;
};
-struct msm_hdmi_audio_codec_ops {
+struct msm_ext_disp_audio_codec_ops {
int (*audio_info_setup)(struct platform_device *pdev,
- struct msm_hdmi_audio_setup_params *params);
- int (*get_audio_edid_blk) (struct platform_device *pdev,
- struct msm_hdmi_audio_edid_blk *blk);
- int (*hdmi_cable_status) (struct platform_device *pdev, u32 vote);
+ struct msm_ext_disp_audio_setup_params *params);
+ int (*get_audio_edid_blk)(struct platform_device *pdev,
+ struct msm_ext_disp_audio_edid_blk *blk);
+ int (*cable_status)(struct platform_device *pdev, u32 vote);
};
+#ifdef CONFIG_FB_MSM_MDSS_DP_PANEL
+int msm_dp_register_audio_codec(struct platform_device *pdev,
+ struct msm_ext_disp_audio_codec_ops *ops);
+
+#else
+static inline int msm_dp_register_audio_codec(struct platform_device *pdev,
+ struct msm_ext_disp_audio_codec_ops *ops) {
+ return 0;
+}
+#endif /* CONFIG_FB_MSM_MDSS_DP_PANEL */
#ifdef CONFIG_FB_MSM_MDSS_HDMI_PANEL
/*
* Register for HDMI cable connect or disconnect notification.
@@ -60,7 +70,7 @@ struct msm_hdmi_audio_codec_ops {
* @return negative value as error otherwise current status of cable
*/
int register_hdmi_cable_notification(
- struct hdmi_cable_notify *handler);
+ struct ext_disp_cable_notify *handler);
/*
* Un-register for HDMI cable connect or disconnect notification.
@@ -68,26 +78,26 @@ int register_hdmi_cable_notification(
* @return negative value as error
*/
int unregister_hdmi_cable_notification(
- struct hdmi_cable_notify *handler);
+ struct ext_disp_cable_notify *handler);
int msm_hdmi_register_audio_codec(struct platform_device *pdev,
- struct msm_hdmi_audio_codec_ops *ops);
+ struct msm_ext_disp_audio_codec_ops *ops);
#else
static inline int register_hdmi_cable_notification(
- struct hdmi_cable_notify *handler) {
+ struct ext_disp_cable_notify *handler) {
return 0;
}
static inline int unregister_hdmi_cable_notification(
- struct hdmi_cable_notify *handler) {
+ struct ext_disp_cable_notify *handler) {
return 0;
}
static inline int msm_hdmi_register_audio_codec(struct platform_device *pdev,
- struct msm_hdmi_audio_codec_ops *ops) {
+ struct msm_ext_disp_audio_codec_ops *ops) {
return 0;
}
#endif /* CONFIG_FB_MSM_MDSS_HDMI_PANEL */
-#endif /*_MSM_HDMI_H_*/
+#endif /*_MSM_EXT_DISPLAY_H_*/