From: linux@audioscience.com
To: patch@alsa-project.org
Cc: tiwai@suse.de,
Eliot Blennerhassett <eblennerhassett@audioscience.com>,
alsa-devel@alsa-project.org
Subject: [snd-asihpi 6/8] Define pcm_debug_name if CONFIG_SND_DEBUG
Date: Fri, 01 Apr 2011 15:59:50 +1300 [thread overview]
Message-ID: <1301626792-13705-7-git-send-email-linux@audioscience.com> (raw)
In-Reply-To: <1301626792-13705-1-git-send-email-linux@audioscience.com>
From: Eliot Blennerhassett <eblennerhassett@audioscience.com>
Signed-off-by: Eliot Blennerhassett <eblennerhassett@audioscience.com>
---
pci/asihpi/asihpi.c | 31 ++++++++++++++++---------------
1 files changed, 16 insertions(+), 15 deletions(-)
diff --git a/pci/asihpi/asihpi.c b/pci/asihpi/asihpi.c
index d5258aa..eac7b08 100644
--- a/pci/asihpi/asihpi.c
+++ b/pci/asihpi/asihpi.c
@@ -47,18 +47,7 @@ MODULE_LICENSE("GPL");
MODULE_AUTHOR("AudioScience inc. <support@audioscience.com>");
MODULE_DESCRIPTION("AudioScience ALSA ASI5000 ASI6000 ASI87xx ASI89xx");
-#if defined CONFIG_SND_DEBUG_VERBOSE
-/**
- * snd_printddd - very verbose debug printk
- * @format: format string
- *
- * Works like snd_printk() for debugging purposes.
- * Ignored when CONFIG_SND_DEBUG_VERBOSE is not set.
- * Must set snd module debug parameter to 3 to enable at runtime.
- */
-#define snd_printddd(format, args...) \
- __snd_printk(3, __FILE__, __LINE__, format, ##args)
-
+#if defined CONFIG_SND_DEBUG
/* copied from pcm_lib.c, hope later patch will make that version public
and this copy can be removed */
static void pcm_debug_name(struct snd_pcm_substream *substream,
@@ -71,12 +60,24 @@ static void pcm_debug_name(struct snd_pcm_substream *substream,
substream->number);
}
#define DEBUG_NAME(substream, name) char name[16]; pcm_debug_name(substream, name, sizeof(name))
-
#else
-#define snd_printddd(format, args...) do { } while (0)
#define pcm_debug_name(s, n, l) do { } while (0)
#define DEBUG_NAME(name, substream) do { } while (0)
+#endif
+#if defined CONFIG_SND_DEBUG_VERBOSE
+/**
+ * snd_printddd - very verbose debug printk
+ * @format: format string
+ *
+ * Works like snd_printk() for debugging purposes.
+ * Ignored when CONFIG_SND_DEBUG_VERBOSE is not set.
+ * Must set snd module debug parameter to 3 to enable at runtime.
+ */
+#define snd_printddd(format, args...) \
+ __snd_printk(3, __FILE__, __LINE__, format, ##args)
+#else
+#define snd_printddd(format, args...) do { } while (0)
#endif
static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX; /* index 0-MAX */
@@ -857,7 +858,7 @@ static void snd_card_asihpi_timer_function(unsigned long data)
unsigned int xfer1, xfer2;
char *pd = &s->runtime->dma_area[buf_ofs];
- if (card->can_dma) {
+ if (card->can_dma) { /* buffer wrap is handled at lower level */
xfer1 = xfercount;
xfer2 = 0;
} else {
--
1.7.0.4
next prev parent reply other threads:[~2011-04-01 2:59 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-01 2:59 [snd-asihpi 0/8] Updates to snd-asihpi driver linux
2011-04-01 2:59 ` [snd-asihpi 1/8] Clock source is neither capture nor playback. Add spaces to control name string for consistency linux
2011-04-01 13:09 ` Takashi Iwai
2011-04-04 23:58 ` Eliot Blennerhassett
2011-04-05 5:22 ` Takashi Iwai
2011-04-01 2:59 ` [snd-asihpi 2/8] Debug print full substream ID. Other minor debug print updates linux
2011-04-01 2:59 ` [snd-asihpi 3/8] More forgiving handling of card playback drained status linux
2011-04-01 2:59 ` [snd-asihpi 4/8] Allow older non DMA capable cards to use MMAP. Emulate the DMA using read and write functions, get rid of copy & silence callbacks that were used only by older cards linux
2011-04-01 2:59 ` [snd-asihpi 5/8] Remove 2 unused functions linux
2011-04-01 2:59 ` linux [this message]
2011-04-01 2:59 ` [snd-asihpi 7/8] Replace subsys_delete_adapter with adapter_delete This allows some special-case code to be removed linux
2011-04-01 2:59 ` [snd-asihpi 8/8] Minor cleanups including %pR to print resource linux
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=1301626792-13705-7-git-send-email-linux@audioscience.com \
--to=linux@audioscience.com \
--cc=alsa-devel@alsa-project.org \
--cc=eblennerhassett@audioscience.com \
--cc=patch@alsa-project.org \
--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;
as well as URLs for NNTP newsgroup(s).