diff options
author | Eliot Blennerhassett <eblennerhassett@audioscience.com> | 2011-07-22 20:36:25 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-07-24 07:34:32 -0400 |
commit | acb03d440b8a723181e1d45e3517e43cb0792f8a (patch) | |
tree | 19b93ccf3a036032c1d49ad6b5248c4a4dd6a480 /sound/pci | |
parent | 8f398ae72fc7e03356fc1ee6b54beef79ba6be6a (diff) |
ALSA: Make snd_pcm_debug_name usable outside pcm_lib
Formatting a PCM name is useful for module debug too.
Add snd_prefix when making function public.
[minor coding-style fixes by tiwai]
Signed-off-by: Eliot Blennerhassett <eblennerhassett@audioscience.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/asihpi/asihpi.c | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/sound/pci/asihpi/asihpi.c b/sound/pci/asihpi/asihpi.c index b941d2541dda..eae62ebbd295 100644 --- a/sound/pci/asihpi/asihpi.c +++ b/sound/pci/asihpi/asihpi.c | |||
@@ -41,31 +41,10 @@ | |||
41 | #include <sound/tlv.h> | 41 | #include <sound/tlv.h> |
42 | #include <sound/hwdep.h> | 42 | #include <sound/hwdep.h> |
43 | 43 | ||
44 | |||
45 | MODULE_LICENSE("GPL"); | 44 | MODULE_LICENSE("GPL"); |
46 | MODULE_AUTHOR("AudioScience inc. <support@audioscience.com>"); | 45 | MODULE_AUTHOR("AudioScience inc. <support@audioscience.com>"); |
47 | MODULE_DESCRIPTION("AudioScience ALSA ASI5000 ASI6000 ASI87xx ASI89xx"); | 46 | MODULE_DESCRIPTION("AudioScience ALSA ASI5000 ASI6000 ASI87xx ASI89xx"); |
48 | 47 | ||
49 | #if defined CONFIG_SND_DEBUG | ||
50 | /* copied from pcm_lib.c, hope later patch will make that version public | ||
51 | and this copy can be removed */ | ||
52 | static inline void | ||
53 | snd_pcm_debug_name(struct snd_pcm_substream *substream, char *buf, size_t size) | ||
54 | { | ||
55 | snprintf(buf, size, "pcmC%dD%d%c:%d", | ||
56 | substream->pcm->card->number, | ||
57 | substream->pcm->device, | ||
58 | substream->stream ? 'c' : 'p', | ||
59 | substream->number); | ||
60 | } | ||
61 | #else | ||
62 | static inline void | ||
63 | snd_pcm_debug_name(struct snd_pcm_substream *substream, char *buf, size_t size) | ||
64 | { | ||
65 | *buf = 0; | ||
66 | } | ||
67 | #endif | ||
68 | |||
69 | #if defined CONFIG_SND_DEBUG_VERBOSE | 48 | #if defined CONFIG_SND_DEBUG_VERBOSE |
70 | /** | 49 | /** |
71 | * snd_printddd - very verbose debug printk | 50 | * snd_printddd - very verbose debug printk |