[Freedreno] [RFC PATCH] drm: msm: Add ASoC generic hdmi audio codec support.

Srinivas Kandagatla srinivas.kandagatla at linaro.org
Mon Jun 6 12:39:44 UTC 2016



On 06/06/16 13:23, Jyri Sarha wrote:
> On 06/03/16 16:56, Srinivas Kandagatla wrote:
>> >This patch adds support to generic audio codec via
>> >ASoC hdmi-codec infrastucture which is merged recently.
>> >
> I know nothing about msm HW, but from the hdmi-codec point of view this
> looks like a correct usage. However, the hdmi-codec could probably do
> more to connect the hdmi audio infoframe's channel allocation field and
> ALSA's channel mapping API together.

Yes, that would be nice to get the channel allocation into hdmi-codec.

>
> There looks to be a bug in selecting 44100 sample rate bellow.
>

Thanks for spotting this, yes this looks like a typo, I will fix this in v2.

Thanks,
srini

> BR,
> Jyri
>
>> >Signed-off-by: Srinivas Kandagatla<srinivas.kandagatla at linaro.org>
>> >---
>> >  drivers/gpu/drm/msm/Kconfig     |   1 +
>> >  drivers/gpu/drm/msm/hdmi/hdmi.c | 120 +++++++++++++++++++++++++++++++++++++++-
>> >  drivers/gpu/drm/msm/hdmi/hdmi.h |  14 +++++
>> >  3 files changed, 134 insertions(+), 1 deletion(-)
>>
>> >diff --git a/drivers/gpu/drm/msm/hdmi/hdmi.c b/drivers/gpu/drm/msm/hdmi/hdmi.c
>> >index 51b9ea5..3281496 100644
>> >--- a/drivers/gpu/drm/msm/hdmi/hdmi.c
>> >+++ b/drivers/gpu/drm/msm/hdmi/hdmi.c
>> >@@ -19,6 +19,7 @@
>> >  #include <linux/of_irq.h>
>> >  #include <linux/of_gpio.h>
>> >
>> >+#include <sound/hdmi-codec.h>
>> >  #include "hdmi.h"
>> >
>> >  void msm_hdmi_set_mode(struct hdmi *hdmi, bool power_on)
>> >@@ -434,6 +435,114 @@ static int msm_hdmi_get_gpio(struct device_node *of_node, const char *name)
>> >  	return gpio;
...
>> >+	case 32000:
>> >+		rate = HDMI_SAMPLE_RATE_32KHZ;
>> >+		break;
>> >+	case 44100:
>> >+		rate = HDMI_SAMPLE_RATE_48KHZ;
>> >+		break;
> This looks like a bug...
>


More information about the Freedreno mailing list