From 2308f4add3de9f6c9c9f02e49461e94d84bb200a Mon Sep 17 00:00:00 2001
From: Joe Perches <joe@perches.com>
Date: Sun, 12 Jun 2011 13:02:43 -0700
Subject: [PATCH] ALSA: hda - Fix beep_device compilation warnings
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Using static inline functions can reduce compilation messages
and macro misuse.

 sound/pci/hda/patch_conexant.c: In function ‘patch_cxt5045’:
 sound/pci/hda/patch_conexant.c:1232:3: warning: statement with no effect

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
 sound/pci/hda/hda_beep.h | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/sound/pci/hda/hda_beep.h b/sound/pci/hda/hda_beep.h
index f1de1bac042c..4967eabe774e 100644
--- a/sound/pci/hda/hda_beep.h
+++ b/sound/pci/hda/hda_beep.h
@@ -50,7 +50,12 @@ int snd_hda_enable_beep_device(struct hda_codec *codec, int enable);
 int snd_hda_attach_beep_device(struct hda_codec *codec, int nid);
 void snd_hda_detach_beep_device(struct hda_codec *codec);
 #else
-#define snd_hda_attach_beep_device(...)		0
-#define snd_hda_detach_beep_device(...)
+static inline int snd_hda_attach_beep_device(struct hda_codec *codec, int nid)
+{
+	return 0;
+}
+void snd_hda_detach_beep_device(struct hda_codec *codec)
+{
+}
 #endif
 #endif
-- 
GitLab