[alsa-devel] [PATCH v9 6/7] drm/i2c: tda998x: Register ASoC hdmi-codec and add audio DT binding

Rob Herring robh at kernel.org
Fri Apr 1 20:37:06 CEST 2016


On Thu, Mar 31, 2016 at 04:36:03PM +0300, Jyri Sarha wrote:
> Register ASoC HDMI codec for audio functionality and adds device tree
> binding for audio configuration.
> 
> With the registered HDMI codec the tda998x node can be used like a
> regular codec node in ASoC card configurations. HDMI audio info-frame
> and audio stream header is generated by the ASoC HDMI codec. The codec
> also applies constraints for available sample-rates based on Edid Like
> Data from the display. The device tree binding document has been
> updated [1].
> 
> Part of this patch has been inspired by Jean Francoise's "drm/i2c: tda998x:
> Add support of a DT graph of ports"-patch [2]. There may still be some
> identical lines left from the original patch and some of the ideas
> have come from there.
> 
> [1] Documentation/devicetree/bindings/display/bridge/tda998x.txt
> [2] http://mailman.alsa-project.org/pipermail/alsa-devel/2015-July/095255.html
> 
> Signed-off-by: Jyri Sarha <jsarha at ti.com>
> ---
>  .../devicetree/bindings/display/bridge/tda998x.txt |  18 ++
>  drivers/gpu/drm/i2c/Kconfig                        |   1 +
>  drivers/gpu/drm/i2c/tda998x_drv.c                  | 198 ++++++++++++++++++++-
>  include/drm/i2c/tda998x.h                          |   4 +-
>  include/dt-bindings/display/tda998x.h              |   7 +
>  5 files changed, 223 insertions(+), 5 deletions(-)
>  create mode 100644 include/dt-bindings/display/tda998x.h
> 
> diff --git a/Documentation/devicetree/bindings/display/bridge/tda998x.txt b/Documentation/devicetree/bindings/display/bridge/tda998x.txt
> index e178e6b..24cc246 100644
> --- a/Documentation/devicetree/bindings/display/bridge/tda998x.txt
> +++ b/Documentation/devicetree/bindings/display/bridge/tda998x.txt
> @@ -21,8 +21,19 @@ Optional properties:
>    - video-ports: 24 bits value which defines how the video controller
>  	output is wired to the TDA998x input - default: <0x230145>
>  
> +  - audio-ports: array of 8-bit values, 2 values per one DAI[1].

This should have nxp prefix. With that,

Acked-by: Rob Herring <robh at kernel.org>


> +	The first value defines the DAI type: TDA998x_SPDIF or TDA998x_I2S[2].
> +	The second value defines the tda998x AP_ENA reg content when the DAI
> +	in question is used. The implementation allows one or two DAIs. If two
> +	DAIs are defined, they must be of different type.
> +
> +[1] Documentation/sound/alsa/soc/DAI.txt
> +[2] include/dt-bindings/display/tda998x.h
> +
>  Example:
>  
> +#include <dt-bindings/display/tda998x.h>
> +
>  	tda998x: hdmi-encoder {
>  		compatible = "nxp,tda998x";
>  		reg = <0x70>;
> @@ -30,4 +41,11 @@ Example:
>  		interrupts = <27 2>;		/* falling edge */
>  		pinctrl-0 = <&pmx_camera>;
>  		pinctrl-names = "default";
> +		video-ports = <0x230145>;
> +
> +		#sound-dai-cells = <2>;
> +			     /*	DAI-format	AP_ENA reg value */
> +		audio-ports = <	TDA998x_SPDIF	0x04
> +				TDA998x_I2S	0x03>;
> +
>  	};


More information about the Alsa-devel mailing list