[PATCH v4 06/15] OMAPDSS: hdmi: Add exported functions for storing HDMI audio data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Implements omapdss_hdmi_get_audio_data() and omapdss_hdmi_set_audio_data()
for storing HDMI audio data in OMAPDSS HDMI drvdata.

Signed-off-by: Jyri Sarha <jsarha@xxxxxx>
---
 drivers/video/fbdev/omap2/dss/hdmi.h        |    2 ++
 drivers/video/fbdev/omap2/dss/hdmi_common.c |   16 ++++++++++++++++
 include/video/omapdss.h                     |    3 +++
 3 files changed, 21 insertions(+)

diff --git a/drivers/video/fbdev/omap2/dss/hdmi.h b/drivers/video/fbdev/omap2/dss/hdmi.h
index 6bf077b..c357057 100644
--- a/drivers/video/fbdev/omap2/dss/hdmi.h
+++ b/drivers/video/fbdev/omap2/dss/hdmi.h
@@ -368,6 +368,8 @@ struct omap_hdmi {
 	bool core_enabled;
 
 	struct omap_dss_device output;
+
+	void *audio_data;
 };
 
 #endif
diff --git a/drivers/video/fbdev/omap2/dss/hdmi_common.c b/drivers/video/fbdev/omap2/dss/hdmi_common.c
index 1b8fcc6..318e754 100644
--- a/drivers/video/fbdev/omap2/dss/hdmi_common.c
+++ b/drivers/video/fbdev/omap2/dss/hdmi_common.c
@@ -146,3 +146,19 @@ int hdmi_compute_acr(u32 pclk, u32 sample_freq, u32 *n, u32 *cts)
 
 	return 0;
 }
+
+void *omapdss_hdmi_get_audio_data(struct device *dev)
+{
+	struct omap_hdmi *hd = dev_get_drvdata(dev);
+
+	return hd->audio_data;
+}
+EXPORT_SYMBOL_GPL(omapdss_hdmi_get_audio_data);
+
+void omapdss_hdmi_set_audio_data(struct device *dev, void *data)
+{
+	struct omap_hdmi *hd = dev_get_drvdata(dev);
+
+	hd->audio_data = data;
+}
+EXPORT_SYMBOL_GPL(omapdss_hdmi_set_audio_data);
diff --git a/include/video/omapdss.h b/include/video/omapdss.h
index 069dfca..46f4984 100644
--- a/include/video/omapdss.h
+++ b/include/video/omapdss.h
@@ -1039,4 +1039,7 @@ omapdss_of_get_first_endpoint(const struct device_node *parent);
 struct omap_dss_device *
 omapdss_of_find_source_for_first_ep(struct device_node *node);
 
+void *omapdss_hdmi_get_audio_data(struct device *dev);
+void omapdss_hdmi_set_audio_data(struct device *dev, void *data);
+
 #endif
-- 
1.7.9.5

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux