Re: [PATCH v2 2/3] ALSA: sparc/dbri: Fix "possible condition with no effect" warning
From: Takashi Iwai
Date: Sun Jul 19 2026 - 04:42:59 EST
On Fri, 17 Jul 2026 11:15:41 +0200,
wangdich9700@xxxxxxx wrote:
>
> From: wangdicheng <wangdicheng@xxxxxxxxxx>
>
> Fix a compiler warning about a condition with no effect:
>
> sound/sparc/dbri.c:1843:1-3: WARNING: possible condition with no effect (if == else)
>
> When DBRI_DEBUG is not defined, dprintk expands to an empty do-while
> statement, making both branches of the if-else no-ops. Guard the entire
> debug block with #ifdef DBRI_DEBUG to eliminate the warning and keep
> the rval reference consistent with its declaration scope.
>
> Signed-off-by: wangdicheng <wangdicheng@xxxxxxxxxx>
Applied to for-next branch. Thanks.
Takashi