Skip to content

Commit

Permalink
ALSA: pcxhr: "fix" PCXHR_REG_TO_PORT definition
Browse files Browse the repository at this point in the history
The following preprocessor directive is non-compliant:

	#undef PCXHR_REG_TO_PORT(x)

gcc warns about extra tokens but nobody sees them as they are under if
branch which is never parsed.

Make it an #error, it is not clear to me what the author meant.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Link: https://lore.kernel.org/r/YUCCv47sm4zf9OVO@localhost.localdomain
Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
Alexey Dobriyan authored and Takashi Iwai committed Sep 16, 2021
1 parent ad7cc2d commit be83038
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sound/pci/pcxhr/pcxhr_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
#define PCXHR_DSP 2

#if (PCXHR_DSP_OFFSET_MAX > PCXHR_PLX_OFFSET_MIN)
#undef PCXHR_REG_TO_PORT(x)
#error PCXHR_REG_TO_PORT(x)
#else
#define PCXHR_REG_TO_PORT(x) ((x)>PCXHR_DSP_OFFSET_MAX ? PCXHR_PLX : PCXHR_DSP)
#endif
Expand Down

0 comments on commit be83038

Please sign in to comment.