[alsa-devel] [PATCH 5/5] ASoC: mc13783: Add devicetree support

Mark Brown broonie at kernel.org
Mon Jan 6 16:12:27 CET 2014


On Mon, Jan 06, 2014 at 05:46:21PM +0400, Alexander Shiyan wrote:
> Понедельник,  6 января 2014, 13:28 UTC от Mark Brown <broonie at kernel.org>:

> > This is an incompatible binding change; deprecating is fine but it
> > should still be supported.  Is there not a default set of port
> > assignments that can be used?

> "fsl,mc13xxx-uses-codec" is not used anywhere and even if it was used,
> it would not usable, because we can not get to the codec phandle.
> So I think this change is safe.

Why would it prevent anything getting the CODEC phandle and what do you
mean by that anyway?  A lack of in tree users shouldn't mean anything,
we need to be compatible with DTs shipped with boards.

> > > +	pdev->dev.of_node = of_find_node_by_name(pdev->dev.parent->of_node,
> > > +						 "codec");

> > You shouldn't be messing with the of_node in the struct device, this is
> > managed by the driver model and setting one that wasn't added in sync
> > with everything else can introduce breakage.

> Hmm, probably you are right, but I cannot imagine other way to set of_node...
> Have you other ideas?

The whole problem is that you're trying to set of_node.  Don't do that.

> > > +	if (priv->adc_ssi_port != MC13783_SSI1_PORT &&
> > > +	    priv->adc_ssi_port != MC13783_SSI2_PORT)
> > > +		return -EINVAL;
> > > +	if (priv->dac_ssi_port != MC13783_SSI1_PORT &&
> > > +	    priv->dac_ssi_port != MC13783_SSI2_PORT)
> > > +		return -EINVAL;

> > What about DAC or ADC only systems?

> In this case we should rewrite this codec driver completely from scratch.

What makes you say that?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20140106/8282ff25/attachment.sig>


More information about the Alsa-devel mailing list