All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel@alsa-project.org, patches@opensource.wolfsonmicro.com,
	Liam Girdwood <lrg@ti.com>
Subject: Re: [PATCH] ASoC: Ensure we generate a driver name
Date: Tue, 20 Sep 2011 14:52:28 +0100	[thread overview]
Message-ID: <20110920135228.GA2974@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <s5hd3ev1gqn.wl%tiwai@suse.de>

On Tue, Sep 20, 2011 at 03:32:48PM +0200, Takashi Iwai wrote:
> Mark Brown wrote:

> > *sigh*  This sort of issue is why I'd prefer to just squash specific
> > characters, especially given that we're just being random about what a
> > valid character is.

> Heh.  Or just use a char *, such as

> 	char *p;
> 	...
> 	for (p = card->snd_card->driver; *p; p++) {
> 		if (*p != '_' && *p != '-' && !isalnum(*p))
> 			*p = '_';
> 	}

I find that a bit less legible, and I do like the ARRAY_SIZE() check for
the warm and fuzzies.  It's more just the listing all the characters
bit.  Anyway, is the last version OK for you?

  reply	other threads:[~2011-09-20 13:52 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-20 12:58 [PATCH] ASoC: Ensure we generate a driver name Mark Brown
2011-09-20 13:11 ` Takashi Iwai
2011-09-20 13:18   ` Mark Brown
2011-09-20 13:32     ` Takashi Iwai
2011-09-20 13:52       ` Mark Brown [this message]
2011-09-20 14:02         ` Takashi Iwai
  -- strict thread matches above, loose matches on Subject: below --
2011-09-20 13:16 Mark Brown
2011-09-21  5:09 ` Scott Jiang
2011-09-21 12:41   ` 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=20110920135228.GA2974@opensource.wolfsonmicro.com \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=lrg@ti.com \
    --cc=patches@opensource.wolfsonmicro.com \
    --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 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.