tegra_audio: add default implementation for tegra_is_voice_call_active()
Mayuresh Kulkarni [Mon, 26 Mar 2012 12:48:54 +0000 (17:48 +0530)]
- mods kernel do not enable audio related configs in kernel
- tegra_is_voice_call_active() is defined only when audio
related configs are enabled
- this commit adds a default implementation for tegra_is_voice_call_active()
which can be called from generic pm code in mach-tegra
- it also makes the default implementation inline

Bug 924817

Signed-off-by: Mayuresh Kulkarni <mkulkarni@nvidia.com>
Reviewed-on: http://git-master/r/92312
(cherry picked from commit 1b7507db6f2266d5cac10fcd4b3e7b06f6d2f3bd)

Change-Id: I286237b838c39cf5c7784c014459bdcaf50c31ef
Reviewed-on: http://git-master/r/94394
Tested-by: Mayuresh Kulkarni <mkulkarni@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

include/linux/tegra_audio.h

index 6416cd0..904dde9 100644 (file)
@@ -75,6 +75,13 @@ struct dam_srate {
 #define I2S_LOOPBACK   _IOW(TEGRA_AUDIO_MAGIC, 17, unsigned int *)
 #define I2S_MODE_I2S   _IOW(TEGRA_AUDIO_MAGIC, 18, unsigned int *)
 
+#ifdef CONFIG_SND_SOC_TEGRA
 extern bool tegra_is_voice_call_active();
+#else
+inline bool tegra_is_voice_call_active()
+{
+       return false;
+}
+#endif
 
 #endif/*_CPCAP_AUDIO_H*/