From: Randy Dunlap <rdunlap@infradead.org>
To: moderated for non-subscribers <alsa-devel@alsa-project.org>,
LKML <linux-kernel@vger.kernel.org>
Cc: Borislav Petkov <bp@alien8.de>, Takashi Iwai <tiwai@suse.de>,
Mark Brown <broonie@kernel.org>,
Liam Girdwood <lgirdwood@gmail.com>,
"Subhransu S. Prusty" <subhransu.s.prusty@intel.com>,
Jie Yang <yang.jie@linux.intel.com>
Subject: [PATCH] ASoC: intel: add function stub when ACPI is not enabled
Date: Tue, 29 Mar 2016 09:45:00 -0700 [thread overview]
Message-ID: <56FAB10C.502@infradead.org> (raw)
From: Randy Dunlap <rdunlap@infradead.org>
Add function stub for "sst_acpi_find_name_from_hid()"
when CONFIG_ACPI is not enabled so that the driver will build
successfully. This fixes the following build errors:
(loadable module)
ERROR: "sst_acpi_find_name_from_hid" [sound/soc/intel/boards/snd-soc-sst-bytcr-rt5640.ko] undefined!
(or built-in)
bytcr_rt5640.c:(.text+0x26fc52): undefined reference to `sst_acpi_find_name_from_hid'
Reported-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Subhransu S. Prusty <subhransu.s.prusty@intel.com>
Cc: Jie Yang <yang.jie@linux.intel.com>
Cc: alsa-devel@alsa-project.org
---
sound/soc/intel/common/sst-acpi.h | 9 +++++++++
1 file changed, 9 insertions(+)
--- linux-next-20160308.orig/sound/soc/intel/common/sst-acpi.h
+++ linux-next-20160308/sound/soc/intel/common/sst-acpi.h
@@ -12,10 +12,19 @@
*
*/
+#include <linux/kconfig.h>
+#include <linux/stddef.h>
#include <linux/acpi.h>
/* translation fron HID to I2C name, needed for DAI codec_name */
+#if IS_ENABLED(CONFIG_ACPI)
const char *sst_acpi_find_name_from_hid(const u8 hid[ACPI_ID_LEN]);
+#else
+inline const char *sst_acpi_find_name_from_hid(const u8 hid[ACPI_ID_LEN])
+{
+ return NULL;
+}
+#endif
/* acpi match */
struct sst_acpi_mach *sst_acpi_find_machine(struct sst_acpi_mach *machines);
next reply other threads:[~2016-03-29 16:45 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-29 16:45 Randy Dunlap [this message]
2016-03-30 22:28 ` Applied "ASoC: intel: add function stub when ACPI is not enabled" to the asoc tree Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56FAB10C.502@infradead.org \
--to=rdunlap@infradead.org \
--cc=alsa-devel@alsa-project.org \
--cc=bp@alien8.de \
--cc=broonie@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=subhransu.s.prusty@intel.com \
--cc=tiwai@suse.de \
--cc=yang.jie@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.