mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Nikesh Oswal <nikesh@opensource.wolfsonmicro.com>
Cc: lgirdwood@gmail.com, perex@perex.cz, tiwai@suse.de,
	alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
	patches@opensource.wolfsonmicro.com
Subject: Re: [PATCH v4] ASOC: dapm: add code to configure dai link parameters
Date: Sat, 6 Sep 2014 15:16:34 +0100	[thread overview]
Message-ID: <20140906141634.GF2601@sirena.org.uk> (raw)
In-Reply-To: <1409561813-24753-1-git-send-email-nikesh@opensource.wolfsonmicro.com>

[-- Attachment #1: Type: text/plain, Size: 1318 bytes --]

On Mon, Sep 01, 2014 at 09:56:53AM +0100, Nikesh Oswal wrote:
> dai-link params for codec-codec links were fixed. The fixed
> link between codec and another chip which may be another codec,
> baseband, bluetooth codec etc may require run time configuaration
> changes. This change provides an optional alsa control to select
> one of the params from a list of params.

As I'm fairly sure I've told you several times now please use subject
lines matching the style for the subsystem - if your commit logs look
different to all the other commit logs that's probably not a good sign.
In this specific case "ASOC" and "ASoC" are not the same thing.

> +	for (count = 0 ; count < num_params; count++) {
> +		w_param_text[count] = kmemdup((void *)(config->stream_name),
> +			strlen(config->stream_name) + 1, GFP_KERNEL);
> +		if (!w_param_text[count]) {
> +			ret = -ENOMEM;
> +			goto  outfree_w_param;
> +		}
> +		config++;
> +	}

This will happily create values with a completely empty name if the user
didn't specify one.  This doesn't seem great - it's going to be an easy
mistake to make and fail to notice.  I'd at least expect a warning here.

> +	w_param_enum[0].items = num_params;
> +	w_param_enum[0].texts = (const char * const *) w_param_text;

Why the casts?  This tends to be a sign that something is wrong.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

      reply	other threads:[~2014-09-06 14:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-01  8:56 Nikesh Oswal
2014-09-06 14:16 ` Mark Brown [this message]

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=20140906141634.GF2601@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nikesh@opensource.wolfsonmicro.com \
    --cc=patches@opensource.wolfsonmicro.com \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.de \
    /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

Powered by JetHome