AsoC: Make snd_soc_read() and snd_soc_write() functions

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Linux Kernel Mailing List
Date: Friday, June 12, 2009 - 12:00 pm

Gitweb:     http://git.kernel.org/linus/5c82f56736e4c3a9eaf53c94366b056c8622d79e
Commit:     5c82f56736e4c3a9eaf53c94366b056c8622d79e
Parent:     6943c92e87c4aa2a6d7a1f4dbd79cf4a0b5fd67b
Author:     Mark Brown <broonie@opensource.wolfsonmicro.com>
AuthorDate: Fri May 22 09:41:30 2009 +0100
Committer:  Mark Brown <broonie@opensource.wolfsonmicro.com>
CommitDate: Fri May 22 10:22:38 2009 +0100

    AsoC: Make snd_soc_read() and snd_soc_write() functions
    
    Should be no impact on the generated code but it helps the compiler
    print clearer messages.
    
    Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
---
 include/sound/soc.h |   17 +++++++++++++----
 1 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/include/sound/soc.h b/include/sound/soc.h
index 2af3213..cf6111d 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -214,10 +214,6 @@ void snd_soc_jack_free_gpios(struct snd_soc_jack *jack, int count,
 			struct snd_soc_jack_gpio *gpios);
 #endif
 
-/* codec IO */
-#define snd_soc_read(codec, reg) codec->read(codec, reg)
-#define snd_soc_write(codec, reg, value) codec->write(codec, reg, value)
-
 /* codec register bit access */
 int snd_soc_update_bits(struct snd_soc_codec *codec, unsigned short reg,
 				unsigned short mask, unsigned short value);
@@ -507,6 +503,19 @@ struct soc_enum {
 	void *dapm;
 };
 
+/* codec IO */
+static inline unsigned int snd_soc_read(struct snd_soc_codec *codec,
+					unsigned int reg)
+{
+	return codec->read(codec, reg);
+}
+
+static inline unsigned int snd_soc_write(struct snd_soc_codec *codec,
+					 unsigned int reg, unsigned int val)
+{
+	return codec->write(codec, reg, val);
+}
+
 #include <sound/soc-dai.h>
 
 #endif
--
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
AsoC: Make snd_soc_read() and snd_soc_write() functions, Linux Kernel Mailing ..., (Fri Jun 12, 12:00 pm)