All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jean-Francois Moine <moinejf@free.fr>
To: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: "devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
	Andrew Jackson <Andrew.Jackson@arm.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Jyri Sarha <jsarha@ti.com>, Mark Brown <broonie@kernel.org>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH v9 1/4] drm/i2c: tda998x: Add DT support for audio
Date: Mon, 12 Jan 2015 18:13:41 +0100	[thread overview]
Message-ID: <20150112181341.4a53ea24@armhf> (raw)
In-Reply-To: <20150112140456.GI12302@n2100.arm.linux.org.uk>

On Mon, 12 Jan 2015 14:04:56 +0000
Russell King - ARM Linux <linux@arm.linux.org.uk> wrote:

> On Mon, Jan 12, 2015 at 02:59:57PM +0100, Philipp Zabel wrote:
> > Am Montag, den 12.01.2015, 12:25 +0000 schrieb Russell King - ARM Linux:
> > > It's not quite that simple, because the SPDIF AP pins are multiplexed
> > > with the I2S pins - and there is variation between chip models and
> > > packages.
> > >
> > > So, it's probably best if port@0 is the video port, and then port@1..n
> > > can describe the audio inputs, including a property which specifies
> > > whether they are I2S or SPDIF, and the value to be programmed into
> > > the AP enable register (which is a bit field of the AP pins which
> > > should be unmasked.)  I guess we can re-use the reg= property for that
> > > value, since video will always be zero.
> > 
> > Note that of_graph_parse_endpoint interprets the port node's reg
> > property as port id. And the unit address part of the node name should
> > match the first address in the reg property.

This is not the case in vexpress-v2p-ca15_a7.dts.

> So that's not going to work very well... because the AP register is a
> bitmask.
> 
> I guess we could specify a node unit and reg, which the code otherwise
> ignores, and specify a philipps,ap-mask = property for the audio ports
> instead.

Also, the video and audio ports must be distinguished. They could be
defined in different port groups.

Example from the Cubox:

	video-ports: ports@0 {
		port {
			tda998x_video: endpoint {
				remote-endpoint = <&lcd0_0>;
				nxp,video-port = <0x230145>;
			};
		};
	};
	audio-ports: ports@1 {
		port@0 {			/* AP1 = I2S */
			tda998x_i2s: endpoint@0 {
				remote-endpoint = <&audio1_i2s>;
				nxp,audio-port = <0x03>;
			};
		};
		port@1 {			 /* AP2 = S/PDIF */
			tda998x_spdif: endpoint@1 {
				remote-endpoint = <&audio1_spdif1>;
				nxp,audio-port = <0x04>;
			};
		};
	};

The port type is identified by the bit AP0.

-- 
Ken ar c'hentañ	|	      ** Breizh ha Linux atav! **
Jef		|		http://moinejf.free.fr/
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

WARNING: multiple messages have this Message-ID (diff)
From: Jean-Francois Moine <moinejf@free.fr>
To: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: Philipp Zabel <p.zabel@pengutronix.de>,
	Andrew Jackson <Andrew.Jackson@arm.com>,
	Jyri Sarha <jsarha@ti.com>, Mark Brown <broonie@kernel.org>,
	Dave Airlie <airlied@gmail.com>,
	"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v9 1/4] drm/i2c: tda998x: Add DT support for audio
Date: Mon, 12 Jan 2015 18:13:41 +0100	[thread overview]
Message-ID: <20150112181341.4a53ea24@armhf> (raw)
In-Reply-To: <20150112140456.GI12302@n2100.arm.linux.org.uk>

On Mon, 12 Jan 2015 14:04:56 +0000
Russell King - ARM Linux <linux@arm.linux.org.uk> wrote:

> On Mon, Jan 12, 2015 at 02:59:57PM +0100, Philipp Zabel wrote:
> > Am Montag, den 12.01.2015, 12:25 +0000 schrieb Russell King - ARM Linux:
> > > It's not quite that simple, because the SPDIF AP pins are multiplexed
> > > with the I2S pins - and there is variation between chip models and
> > > packages.
> > >
> > > So, it's probably best if port@0 is the video port, and then port@1..n
> > > can describe the audio inputs, including a property which specifies
> > > whether they are I2S or SPDIF, and the value to be programmed into
> > > the AP enable register (which is a bit field of the AP pins which
> > > should be unmasked.)  I guess we can re-use the reg= property for that
> > > value, since video will always be zero.
> > 
> > Note that of_graph_parse_endpoint interprets the port node's reg
> > property as port id. And the unit address part of the node name should
> > match the first address in the reg property.

This is not the case in vexpress-v2p-ca15_a7.dts.

> So that's not going to work very well... because the AP register is a
> bitmask.
> 
> I guess we could specify a node unit and reg, which the code otherwise
> ignores, and specify a philipps,ap-mask = property for the audio ports
> instead.

Also, the video and audio ports must be distinguished. They could be
defined in different port groups.

Example from the Cubox:

	video-ports: ports@0 {
		port {
			tda998x_video: endpoint {
				remote-endpoint = <&lcd0_0>;
				nxp,video-port = <0x230145>;
			};
		};
	};
	audio-ports: ports@1 {
		port@0 {			/* AP1 = I2S */
			tda998x_i2s: endpoint@0 {
				remote-endpoint = <&audio1_i2s>;
				nxp,audio-port = <0x03>;
			};
		};
		port@1 {			 /* AP2 = S/PDIF */
			tda998x_spdif: endpoint@1 {
				remote-endpoint = <&audio1_spdif1>;
				nxp,audio-port = <0x04>;
			};
		};
	};

The port type is identified by the bit AP0.

-- 
Ken ar c'hentañ	|	      ** Breizh ha Linux atav! **
Jef		|		http://moinejf.free.fr/

  reply	other threads:[~2015-01-12 17:13 UTC|newest]

Thread overview: 115+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-07 11:06 [PATCH v9 0/4] ASoC: tda998x: add a codec to the HDMI transmitter Jean-Francois Moine
2015-01-07 11:06 ` Jean-Francois Moine
2015-01-07  9:10 ` [PATCH v9 1/4] drm/i2c: tda998x: Add DT support for audio Jean-Francois Moine
2015-01-07  9:10   ` Jean-Francois Moine
2015-01-07 14:39   ` Andrew Jackson
2015-01-07 14:39     ` Andrew Jackson
2015-01-07 17:08     ` Jean-Francois Moine
2015-01-07 17:08       ` Jean-Francois Moine
2015-01-07 17:18       ` Andrew Jackson
2015-01-07 17:18         ` Andrew Jackson
2015-01-07 17:33         ` Mark Brown
     [not found]   ` <0084acea5a3475a77531d6a77483f36d3469111a.1420628786.git.moinejf-GANU6spQydw@public.gmane.org>
2015-01-08 14:53     ` Jyri Sarha
2015-01-08 14:53       ` Jyri Sarha
     [not found]       ` <54AE99F5.1010404-l0cyMroinI0@public.gmane.org>
2015-01-08 16:42         ` Jean-Francois Moine
2015-01-08 16:42           ` Jean-Francois Moine
2015-01-08 20:04           ` Mark Brown
2015-01-08 20:04             ` Mark Brown
2015-01-09  9:25             ` Andrew Jackson
2015-01-09  9:25               ` Andrew Jackson
2015-01-09 10:13           ` Jyri Sarha
2015-01-09 10:13             ` Jyri Sarha
2015-01-09 11:30             ` Jean-Francois Moine
2015-01-09 11:30               ` Jean-Francois Moine
2015-01-09 11:45               ` Russell King - ARM Linux
2015-01-09 11:45                 ` Russell King - ARM Linux
2015-01-09 12:54                 ` Jean-Francois Moine
2015-01-09 12:54                   ` Jean-Francois Moine
2015-01-09 13:07                   ` Russell King - ARM Linux
2015-01-09 13:07                     ` Russell King - ARM Linux
     [not found]                     ` <20150109130725.GN12302-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
2015-01-09 13:58                       ` Andrew Jackson
2015-01-09 13:58                         ` Andrew Jackson
2015-01-09 14:57                         ` Russell King - ARM Linux
2015-01-09 17:38                           ` Jean-Francois Moine
2015-01-09 17:38                             ` Jean-Francois Moine
2015-01-09 20:01                             ` Russell King - ARM Linux
2015-01-09 20:01                               ` Russell King - ARM Linux
     [not found]                               ` <20150109200127.GD12302-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
2015-01-10 15:47                                 ` [alsa-devel] " Jean-Francois Moine
2015-01-10 15:47                                   ` Jean-Francois Moine
2015-01-12  9:25                               ` Philipp Zabel
2015-01-12  9:25                                 ` Philipp Zabel
2015-01-12 12:25                                 ` Russell King - ARM Linux
2015-01-12 13:59                                   ` Philipp Zabel
2015-01-12 13:59                                     ` Philipp Zabel
2015-01-12 14:04                                     ` Russell King - ARM Linux
2015-01-12 14:04                                       ` Russell King - ARM Linux
2015-01-12 17:13                                       ` Jean-Francois Moine [this message]
2015-01-12 17:13                                         ` Jean-Francois Moine
2015-01-12 17:57                                         ` Russell King - ARM Linux
2015-01-12 17:57                                           ` Russell King - ARM Linux
2015-01-12 19:14                                           ` Jean-Francois Moine
2015-01-12 19:14                                             ` Jean-Francois Moine
2015-01-13 12:21                                           ` Philipp Zabel
2015-01-13 12:21                                             ` Philipp Zabel
2015-01-13 12:27                                             ` Russell King - ARM Linux
2015-01-13 12:27                                               ` Russell King - ARM Linux
2015-01-13 15:54                                               ` Jean-Francois Moine
2015-01-13 15:54                                                 ` Jean-Francois Moine
2015-01-13 16:03                                                 ` Russell King - ARM Linux
2015-01-13 16:03                                                   ` Russell King - ARM Linux
2015-01-13 19:02                                                   ` Jean-Francois Moine
2015-01-13 19:02                                                     ` Jean-Francois Moine
2015-01-13 19:26                                                     ` Russell King - ARM Linux
2015-01-13 19:26                                                       ` Russell King - ARM Linux
2015-01-13 19:41                                                       ` Jyri Sarha
2015-01-13 19:41                                                         ` Jyri Sarha
2015-01-13 19:54                                                         ` Russell King - ARM Linux
2015-01-13 19:54                                                           ` Russell King - ARM Linux
2015-01-14  7:55                                                           ` Jean-Francois Moine
2015-01-14  7:55                                                             ` Jean-Francois Moine
2015-01-14 12:12                                                             ` Russell King - ARM Linux
2015-01-14 12:12                                                               ` Russell King - ARM Linux
2015-01-14 10:46                                                           ` Philipp Zabel
2015-01-14 10:46                                                             ` Philipp Zabel
2015-01-14 12:50                                                             ` Mark Brown
2015-01-14 12:50                                                               ` Mark Brown
2015-01-14 14:23                                                               ` Russell King - ARM Linux
2015-01-14 14:23                                                                 ` Russell King - ARM Linux
2015-01-07 10:00 ` [PATCH v9 2/4] drm/i2c: tda998x: Change drvdata for audio extension Jean-Francois Moine
2015-01-07 10:00   ` Jean-Francois Moine
2015-01-07 10:51 ` [PATCH v9 3/4] ASoC: tda998x: add a codec to the HDMI transmitter Jean-Francois Moine
2015-01-07 15:10   ` Andrew Jackson
2015-01-07 15:10     ` Andrew Jackson
2015-01-07 15:41     ` Russell King - ARM Linux
2015-01-07 15:41       ` Russell King - ARM Linux
2015-01-07 18:02       ` Jean-Francois Moine
2015-01-09 10:24         ` Jyri Sarha
2015-01-09 10:24           ` Jyri Sarha
2015-01-09 11:15           ` Jean-Francois Moine
2015-01-09 11:15             ` Jean-Francois Moine
2015-01-09 11:19           ` Russell King - ARM Linux
2015-01-09 11:19             ` Russell King - ARM Linux
2015-01-09 11:45             ` Jean-Francois Moine
2015-01-09 11:45               ` Jean-Francois Moine
2015-01-09 11:48               ` Russell King - ARM Linux
2015-01-09 11:48                 ` Russell King - ARM Linux
2015-01-07 17:34     ` Mark Brown
2015-01-07 17:34       ` Mark Brown
2015-01-08 14:55   ` Jyri Sarha
2015-01-08 14:55     ` Jyri Sarha
2015-01-09 17:39   ` Andrew Jackson
2015-01-09 17:39     ` Andrew Jackson
     [not found]     ` <54B0123C.9070800-5wv7dgnIgG8@public.gmane.org>
2015-01-09 17:54       ` Mark Brown
2015-01-09 17:54         ` Mark Brown
2015-01-13  9:24     ` Jean-Francois Moine
2015-01-13  9:24       ` Jean-Francois Moine
2015-01-11 21:03   ` Jyri Sarha
2015-01-11 21:03     ` Jyri Sarha
2015-01-13  7:41     ` Jean-Francois Moine
2015-01-13  7:41       ` Jean-Francois Moine
2015-01-07 11:01 ` [PATCH v9 4/4] drm/i2c: tda998x: set cts_n according to the sample width Jean-Francois Moine
2015-01-08 14:53 ` [PATCH v9 0/4] ASoC: tda998x: add a codec to the HDMI transmitter Jyri Sarha
2015-01-08 14:53   ` Jyri Sarha
2015-01-08 20:05   ` Mark Brown
2015-01-09 10:15     ` Jyri Sarha
2015-01-09 10:15       ` Jyri Sarha

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150112181341.4a53ea24@armhf \
    --to=moinejf@free.fr \
    --cc=Andrew.Jackson@arm.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jsarha@ti.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.