From: Jyri Sarha <jsarha@ti.com>
To: Mark Brown <broonie@kernel.org>
Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org,
Lars-Peter Clausen <lars@metafoo.de>,
kuninori.morimoto.gx@renesas.com, moinejf@free.fr,
peter.ujfalusi@ti.com, liam.r.girdwood@linux.intel.com,
bcousson@baylibre.com
Subject: Re: [PATCH 2/2] ASoC: simple-card: Add support for samplerate and samplewidth constraints
Date: Wed, 4 Mar 2015 09:56:24 +0200 [thread overview]
Message-ID: <54F6BAA8.2010803@ti.com> (raw)
In-Reply-To: <20150303153431.GA21293@sirena.org.uk>
On 03/03/2015 05:34 PM, Mark Brown wrote:
> On Tue, Mar 03, 2015 at 02:00:31PM +0200, Jyri Sarha wrote:
>> On 03/03/2015 01:30 PM, Mark Brown wrote:
>
>>> ...this is more the point. Perhaps the constraints language needs
>>> improvement here?
>
>> Improving constraint functionality would certainly help, however the way
>> that code works is beyond my understanding and I do not believe such an
>> improvement would be coming from anybody else any time soon either.
>
> It's probably worth putting together a description of the constraint and
> asking people like Takashi who understand the code - ideally it'd be
> easy to implement but I suspect you're right about timescales.
>
Now that Lars-Peter pointed me to the right direction, it seems there is
a proper way to deal with issue after all.
>>> The trouble with this sort of interface is that it's a quick and dirty
>>> way for people to bodge around things rather than actually fixing them
>>> properly. Of course sometimes fixing things properly is really hard and
>>> that means we want a temporary bodge but having to put them in DT is
>>> really unfortunate.
>
>> I agree with that. However, the simple-card binding goes already now quite a
>> bit beyond just describing the hardware. The binding for instance decides
>> the configuration that is going to be used over the dai-link. These
>> constraints could be seen as an extension to that configuration.
>
>> I am wondering if there would be some better way to select the dai-link
>> configuration than writing it to DT or creating a custom machine driver for
>> each setup.
>
Continuing this tought. I wonder if it would be better to introduce a
new compatible match for each new card, with some clever way to manage
the accumulating matches in the code, and hard code DAI-link
configurations for each match. This way the old configurations would not
be carved to stone in the old dtbs.
>> But about this patch. Should I just give it up, or would you be willing to
>> apply it if I improve the description more and add a warning against using
>> these properties to work around driver bugs to the binding document?
>
> I'm not totally against the idea so it's worth continuing. Just not
> happy either but computer.
>
> It just occurred to me that we may be able to sidestep the issue by
> calling them "suggested rates/widths" so the implementation can ignore
> them later. That's a *tiny* bit gross but does sidestep the ABI issues.
>
As there is a proper way to deal with this, I'll look into that first.
However, if there still is a need for these properties I am happy to
finish the patch.
Best regards,
Jyri
next prev parent reply other threads:[~2015-03-04 7:56 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-02 14:14 [PATCH 0/2] simple-card: Add samplerate and samplewidth constraints Jyri Sarha
[not found] ` <cover.1425303942.git.jsarha-l0cyMroinI0@public.gmane.org>
2015-03-02 14:14 ` [PATCH 1/2] ASoC: simple-card: Remove trailing whitespace Jyri Sarha
[not found] ` <c7817be105a96bcbf71202c5497982f59a45a8eb.1425303942.git.jsarha-l0cyMroinI0@public.gmane.org>
2015-03-03 15:34 ` Mark Brown
2015-03-02 14:14 ` [PATCH 2/2] ASoC: simple-card: Add support for samplerate and samplewidth constraints Jyri Sarha
[not found] ` <9d01aa0d0bf48d8b41d5086a7e6c9ec08c2b9c48.1425303942.git.jsarha-l0cyMroinI0@public.gmane.org>
2015-03-02 19:35 ` [alsa-devel] " Pierre-Louis Bossart
2015-03-03 10:01 ` Jyri Sarha
2015-03-02 19:58 ` [alsa-devel] " Lars-Peter Clausen
2015-03-03 10:09 ` Jyri Sarha
[not found] ` <54F5884A.1090702-l0cyMroinI0@public.gmane.org>
2015-03-03 11:30 ` [alsa-devel] " Mark Brown
[not found] ` <20150303113041.GM21293-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2015-03-03 12:00 ` Jyri Sarha
2015-03-03 15:31 ` Lars-Peter Clausen
2015-03-04 7:48 ` Jyri Sarha
2015-03-10 15:25 ` Jyri Sarha
2015-03-03 15:34 ` Mark Brown
2015-03-04 7:56 ` Jyri Sarha [this message]
2015-03-04 18:42 ` Mark Brown
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=54F6BAA8.2010803@ti.com \
--to=jsarha@ti.com \
--cc=alsa-devel@alsa-project.org \
--cc=bcousson@baylibre.com \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=lars@metafoo.de \
--cc=liam.r.girdwood@linux.intel.com \
--cc=moinejf@free.fr \
--cc=peter.ujfalusi@ti.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).