From: Takashi Iwai Subject: Re: [for 2.6.34][PATCH] ALSA: pcm_lib - fix xrun functionality Date: Fri, 26 Mar 2010 15:29:56 +0100 Message-ID: References: <1269612445-14245-1-git-send-email-jhnikula@gmail.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 7CE8E103821 for ; Fri, 26 Mar 2010 15:29:56 +0100 (CET) In-Reply-To: <1269612445-14245-1-git-send-email-jhnikula@gmail.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Jarkko Nikula Cc: alsa-devel@alsa-project.org, Pavel Machek List-Id: alsa-devel@alsa-project.org At Fri, 26 Mar 2010 16:07:25 +0200, Jarkko Nikula wrote: > > The commit 4d96eb255c53ab5e39b37fd4d484ea3dc39ab456 broke the interrupt > time xrun functionality (stream stop etc.) if the CONFIG_SND_PCM_XRUN_DEBUG > is not set. This is because the xrun() is null defined without it. > > Fix this by letting the function xrun() to be always defined as it was > before. Thanks, that's likely the problem Pavel has seen, but never reproduced on Jaroslav or my machine. Applied now to sound git tree. Takashi > Signed-off-by: Jarkko Nikula > Cc: Jaroslav Kysela > --- > sound/core/pcm_lib.c | 6 ++++-- > 1 files changed, 4 insertions(+), 2 deletions(-) > > diff --git a/sound/core/pcm_lib.c b/sound/core/pcm_lib.c > index b546ac2..a2ff861 100644 > --- a/sound/core/pcm_lib.c > +++ b/sound/core/pcm_lib.c > @@ -148,6 +148,9 @@ static void pcm_debug_name(struct snd_pcm_substream *substream, > > #define xrun_debug(substream, mask) \ > ((substream)->pstr->xrun_debug & (mask)) > +#else > +#define xrun_debug(substream, mask) 0 > +#endif > > #define dump_stack_on_xrun(substream) do { \ > if (xrun_debug(substream, XRUN_DEBUG_STACK)) \ > @@ -169,6 +172,7 @@ static void xrun(struct snd_pcm_substream *substream) > } > } > > +#ifdef CONFIG_SND_PCM_XRUN_DEBUG > #define hw_ptr_error(substream, fmt, args...) \ > do { \ > if (xrun_debug(substream, XRUN_DEBUG_BASIC)) { \ > @@ -255,8 +259,6 @@ static void xrun_log_show(struct snd_pcm_substream *substream) > > #else /* ! CONFIG_SND_PCM_XRUN_DEBUG */ > > -#define xrun_debug(substream, mask) 0 > -#define xrun(substream) do { } while (0) > #define hw_ptr_error(substream, fmt, args...) do { } while (0) > #define xrun_log(substream, pos) do { } while (0) > #define xrun_log_show(substream) do { } while (0) > -- > 1.7.0 >