Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Vinod Koul <vinod.koul@intel.com>
To: alsa-devel@alsa-project.org
Cc: tiwai@suse.de, patches.audio@intel.com,
	liam.r.girdwood@linux.intel.com,
	Vinod Koul <vinod.koul@intel.com>,
	broonie@kernel.org, Jeeja KP <jeeja.kp@intel.com>
Subject: [PATCH v2 1/2] ALSA: hda: add snd_adsp_enable module flag
Date: Thu, 18 Jun 2015 12:08:24 +0530	[thread overview]
Message-ID: <1434609505-776-2-git-send-email-vinod.koul@intel.com> (raw)
In-Reply-To: <1434609505-776-1-git-send-email-vinod.koul@intel.com>

Some Intel HDA controllers sport a DSP. These systems can also be
enabled with ASoC HDA driver as well. So add a flag in hda-core to
enable/disable aDSP. This flag for now is false, and should be true
once the ASoC based systems mature.  The integrators/OS vendors can
configure this flag based on system preference.

Signed-off-by: Jeeja KP <jeeja.kp@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
---
 include/sound/hdaudio.h  | 11 +++++++++++
 sound/hda/hda_bus_type.c |  6 ++++++
 2 files changed, 17 insertions(+)

diff --git a/include/sound/hdaudio.h b/include/sound/hdaudio.h
index 4caf1fde8a4f..7c4dd26abd4e 100644
--- a/include/sound/hdaudio.h
+++ b/include/sound/hdaudio.h
@@ -13,6 +13,17 @@
 #include <sound/hda_verbs.h>
 #include <drm/i915_component.h>
 
+/*
+ * snd_adsp_enable: exported HD-A aDSP enable configuration.
+ *
+ * Some Intel HDA controllers sport a DSP, for these platform we can bypass
+ * aDSP and use as regular HDA controller or enable aDSP and use aDSP
+ * along with I2S codecs etc.
+ * hdac_adsp_enable would enable the aDSP based HDA controller if the
+ * platform supports it
+ */
+extern bool snd_adsp_enable;
+
 /* codec node id */
 typedef u16 hda_nid_t;
 
diff --git a/sound/hda/hda_bus_type.c b/sound/hda/hda_bus_type.c
index 89c2711baaaf..8fb4e8b1398e 100644
--- a/sound/hda/hda_bus_type.c
+++ b/sound/hda/hda_bus_type.c
@@ -10,6 +10,12 @@
 MODULE_DESCRIPTION("HD-audio bus");
 MODULE_LICENSE("GPL");
 
+bool snd_adsp_enable = false;
+EXPORT_SYMBOL_GPL(snd_adsp_enable);
+
+module_param(snd_adsp_enable, bool, 0444);
+MODULE_PARM_DESC(snd_adsp_enable, "HD-A aDSP enable configuration");
+
 /**
  * hdac_get_device_id - gets the hdac device id entry
  * @hdev: HD-audio core device
-- 
1.9.1

  reply	other threads:[~2015-06-18  6:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-18  6:38 [PATCH v2 0/2] ALSA: hda: add module flag snd_adsp_enable Vinod Koul
2015-06-18  6:38 ` Vinod Koul [this message]
2015-06-18  6:38 ` [PATCH v2 2/2] ALSA: hda: use snd_adsp_enable in HDA driver Vinod Koul
2015-06-19 11:37 ` [PATCH v2 0/2] ALSA: hda: add module flag snd_adsp_enable Takashi Iwai
2015-06-22 10:58   ` Vinod Koul

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=1434609505-776-2-git-send-email-vinod.koul@intel.com \
    --to=vinod.koul@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=jeeja.kp@intel.com \
    --cc=liam.r.girdwood@linux.intel.com \
    --cc=patches.audio@intel.com \
    --cc=tiwai@suse.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox