aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorDima Zavin <dima@android.com>2011-09-12 11:43:34 -0700
committerDima Zavin <dima@android.com>2011-09-12 11:43:34 -0700
commit5d9e2fcd0efd6fcdd98f734406046c5bcba80b40 (patch)
tree48a1434005a5f364c5d91ac93e2163ac2968f994 /sound
parent410ad9441e0d5b831d2ebb054c638915c1988ba2 (diff)
parentb0ed5170e36453c714e7a16b309126c3709ec02a (diff)
downloadkernel_samsung_tuna-5d9e2fcd0efd6fcdd98f734406046c5bcba80b40.zip
kernel_samsung_tuna-5d9e2fcd0efd6fcdd98f734406046c5bcba80b40.tar.gz
kernel_samsung_tuna-5d9e2fcd0efd6fcdd98f734406046c5bcba80b40.tar.bz2
Merge branch 'linux-omap-3.0' into android-omap-3.0
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/Kconfig3
-rw-r--r--sound/soc/codecs/Makefile2
-rw-r--r--sound/soc/codecs/omap-hdmi-codec.c409
-rw-r--r--sound/soc/codecs/twl6040.c8
-rw-r--r--sound/soc/omap/Kconfig12
-rw-r--r--sound/soc/omap/Makefile4
-rw-r--r--sound/soc/omap/abe/abe_dat.c10
-rw-r--r--sound/soc/omap/abe/abe_define.h10
-rw-r--r--sound/soc/omap/abe/abe_dm_addr.h18
-rw-r--r--sound/soc/omap/abe/abe_firmware.c840
-rw-r--r--sound/soc/omap/abe/abe_functionsid.h3
-rw-r--r--sound/soc/omap/abe/abe_ini.c1
-rw-r--r--sound/soc/omap/abe/abe_initxxx_labels.h10
-rw-r--r--sound/soc/omap/abe/abe_main.h1
-rw-r--r--sound/soc/omap/abe/abe_sm_addr.h2
-rw-r--r--sound/soc/omap/abe/abe_taskid.h3
-rw-r--r--sound/soc/omap/abe/abe_typedef.h10
-rw-r--r--sound/soc/omap/omap-abe-dsp.c82
-rw-r--r--sound/soc/omap/omap-abe-dsp.h3
-rw-r--r--sound/soc/omap/omap-abe.c11
-rw-r--r--sound/soc/omap/omap-hdmi.c158
-rw-r--r--sound/soc/omap/omap-hdmi.h36
-rw-r--r--sound/soc/omap/omap4-hdmi-card.c129
-rwxr-xr-x[-rw-r--r--]sound/soc/omap/sdp4430.c30
24 files changed, 1338 insertions, 457 deletions
diff --git a/sound/soc/codecs/Kconfig b/sound/soc/codecs/Kconfig
index 0fb6ebe..40e3a82 100644
--- a/sound/soc/codecs/Kconfig
+++ b/sound/soc/codecs/Kconfig
@@ -243,6 +243,9 @@ config SND_SOC_TWL6040
select TWL6040_CODEC
tristate
+config SND_SOC_OMAP_HDMI_CODEC
+ tristate
+
config SND_SOC_UDA134X
tristate
diff --git a/sound/soc/codecs/Makefile b/sound/soc/codecs/Makefile
index fd85584..04e7b26 100644
--- a/sound/soc/codecs/Makefile
+++ b/sound/soc/codecs/Makefile
@@ -36,6 +36,7 @@ snd-soc-tlv320aic32x4-objs := tlv320aic32x4.o
snd-soc-tlv320dac33-objs := tlv320dac33.o
snd-soc-twl4030-objs := twl4030.o
snd-soc-twl6040-objs := twl6040.o
+snd-soc-omap-hdmi-codec-objs := omap-hdmi-codec.o
snd-soc-uda134x-objs := uda134x.o
snd-soc-uda1380-objs := uda1380.o
snd-soc-wl1273-objs := wl1273.o
@@ -128,6 +129,7 @@ obj-$(CONFIG_SND_SOC_TVL320AIC32X4) += snd-soc-tlv320aic32x4.o
obj-$(CONFIG_SND_SOC_TLV320DAC33) += snd-soc-tlv320dac33.o
obj-$(CONFIG_SND_SOC_TWL4030) += snd-soc-twl4030.o
obj-$(CONFIG_SND_SOC_TWL6040) += snd-soc-twl6040.o
+obj-$(CONFIG_SND_SOC_OMAP_HDMI_CODEC) += snd-soc-omap-hdmi-codec.o
obj-$(CONFIG_SND_SOC_UDA134X) += snd-soc-uda134x.o
obj-$(CONFIG_SND_SOC_UDA1380) += snd-soc-uda1380.o
obj-$(CONFIG_SND_SOC_WL1273) += snd-soc-wl1273.o
diff --git a/sound/soc/codecs/omap-hdmi-codec.c b/sound/soc/codecs/omap-hdmi-codec.c
new file mode 100644
index 0000000..8d89eed
--- /dev/null
+++ b/sound/soc/codecs/omap-hdmi-codec.c
@@ -0,0 +1,409 @@
+/*
+ * ALSA SoC HMDI codec driver
+ *
+ * Author: Ricardo Neri <ricardo.neri@ti.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * version 2 as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA
+ *
+ */
+
+#include <linux/module.h>
+#include <linux/moduleparam.h>
+#include <linux/init.h>
+#include <linux/delay.h>
+#include <linux/pm.h>
+#include <linux/gpio.h>
+#include <linux/platform_device.h>
+#include <linux/slab.h>
+
+#include <sound/core.h>
+#include <sound/pcm.h>
+#include <sound/pcm_params.h>
+#include <sound/soc.h>
+#include <sound/initval.h>
+#include <sound/tlv.h>
+
+#include <plat/omap_hwmod.h>
+#include <video/omapdss.h>
+#include <video/hdmi_ti_4xxx_ip.h>
+
+#include "../../../drivers/video/omap2/dss/dss_features.h"
+#include "../../../drivers/video/omap2/dss/dss.h"
+
+#define HDMI_WP 0x0
+#define HDMI_CORE_SYS 0x400
+#define HDMI_CORE_AV 0x900
+#define HDMI_PLLCTRL 0x200
+#define HDMI_PHY 0x300
+
+/* codec private data */
+struct hdmi_data {
+ struct hdmi_audio_format audio_fmt;
+ struct hdmi_audio_dma audio_dma;
+ struct hdmi_core_audio_config audio_core_cfg;
+ struct hdmi_core_infoframe_audio aud_if_cfg;
+ struct hdmi_ip_data ip_data;
+ struct omap_hwmod *oh;
+};
+
+static int hdmi_audio_hw_params(struct snd_pcm_substream *substream,
+ struct snd_pcm_hw_params *params,
+ struct snd_soc_dai *dai)
+{
+ struct snd_soc_pcm_runtime *rtd = substream->private_data;
+ struct snd_soc_codec *codec = rtd->codec;
+ struct platform_device *pdev = to_platform_device(codec->dev);
+ struct hdmi_data *priv = snd_soc_codec_get_drvdata(codec);
+ struct hdmi_audio_format *audio_format = &priv->audio_fmt;
+ struct hdmi_audio_dma *audio_dma = &priv->audio_dma;
+ struct hdmi_core_audio_config *core_cfg = &priv->audio_core_cfg;
+ struct hdmi_core_infoframe_audio *aud_if_cfg = &priv->aud_if_cfg;
+ int err, n, cts, channels_nr, channel_alloc;
+ enum hdmi_core_audio_sample_freq sample_freq;
+ u32 pclk = omapdss_hdmi_get_pixel_clock();
+
+
+ switch (params_format(params)) {
+ case SNDRV_PCM_FORMAT_S16_LE:
+ core_cfg->i2s_cfg.word_max_length =
+ HDMI_AUDIO_I2S_MAX_WORD_20BITS;
+ core_cfg->i2s_cfg.word_length =
+ HDMI_AUDIO_I2S_CHST_WORD_16_BITS;
+ core_cfg->i2s_cfg.in_length_bits =
+ HDMI_AUDIO_I2S_INPUT_LENGTH_16;
+ core_cfg->i2s_cfg.justification = HDMI_AUDIO_JUSTIFY_LEFT;
+ audio_format->samples_per_word = HDMI_AUDIO_ONEWORD_TWOSAMPLES;
+ audio_format->sample_size = HDMI_AUDIO_SAMPLE_16BITS;
+ audio_format->justification = HDMI_AUDIO_JUSTIFY_LEFT;
+ audio_dma->transfer_size = 0x10;
+ break;
+ case SNDRV_PCM_FORMAT_S24_LE:
+ core_cfg->i2s_cfg.word_max_length =
+ HDMI_AUDIO_I2S_MAX_WORD_24BITS;
+ core_cfg->i2s_cfg.word_length =
+ HDMI_AUDIO_I2S_CHST_WORD_24_BITS;
+ core_cfg->i2s_cfg.in_length_bits =
+ HDMI_AUDIO_I2S_INPUT_LENGTH_24;
+ audio_format->samples_per_word = HDMI_AUDIO_ONEWORD_ONESAMPLE;
+ audio_format->sample_size = HDMI_AUDIO_SAMPLE_24BITS;
+ audio_format->justification = HDMI_AUDIO_JUSTIFY_RIGHT;
+ core_cfg->i2s_cfg.justification = HDMI_AUDIO_JUSTIFY_RIGHT;
+ audio_dma->transfer_size = 0x20;
+ break;
+ default:
+ return -EINVAL;
+ }
+
+
+ switch (params_rate(params)) {
+ case 32000:
+ sample_freq = HDMI_AUDIO_FS_32000;
+ break;
+ case 44100:
+ sample_freq = HDMI_AUDIO_FS_44100;
+ break;
+ case 48000:
+ sample_freq = HDMI_AUDIO_FS_48000;
+ break;
+ default:
+ return -EINVAL;
+ }
+
+ err = hdmi_ti_4xxx_config_audio_acr(&priv->ip_data, params_rate(params),
+ &n, &cts, pclk);
+ if (err < 0)
+ return err;
+
+ /* Audio wrapper config */
+ audio_format->type = HDMI_AUDIO_TYPE_LPCM;
+ audio_format->sample_order = HDMI_AUDIO_SAMPLE_LEFT_FIRST;
+ /* Disable start/stop signals of IEC 60958 blocks */
+ audio_format->en_sig_blk_strt_end = HDMI_AUDIO_BLOCK_SIG_STARTEND_OFF;
+
+ audio_dma->block_size = 0xC0;
+ audio_dma->mode = HDMI_AUDIO_TRANSF_DMA;
+ audio_dma->fifo_threshold = 0x20; /* in number of samples */
+
+ hdmi_ti_4xxx_wp_audio_config_dma(&priv->ip_data, audio_dma);
+ hdmi_ti_4xxx_wp_audio_config_format(&priv->ip_data, audio_format);
+
+ /*
+ * I2S config
+ */
+ core_cfg->i2s_cfg.en_high_bitrate_aud = false;
+ /* Only used with high bitrate audio */
+ core_cfg->i2s_cfg.cbit_order = false;
+ /* Serial data and word select should change on sck rising edge */
+ core_cfg->i2s_cfg.sck_edge_mode = HDMI_AUDIO_I2S_SCK_EDGE_RISING;
+ core_cfg->i2s_cfg.vbit = HDMI_AUDIO_I2S_VBIT_FOR_PCM;
+ /* Set I2S word select polarity */
+ core_cfg->i2s_cfg.ws_polarity = HDMI_AUDIO_I2S_WS_POLARITY_LOW_IS_LEFT;
+ core_cfg->i2s_cfg.direction = HDMI_AUDIO_I2S_MSB_SHIFTED_FIRST;
+ /* Set serial data to word select shift. See Phillips spec. */
+ core_cfg->i2s_cfg.shift = HDMI_AUDIO_I2S_FIRST_BIT_SHIFT;
+
+ /* Core audio config */
+ core_cfg->freq_sample = sample_freq;
+ core_cfg->n = n;
+ core_cfg->cts = cts;
+ if (dss_has_feature(FEAT_HDMI_CTS_SWMODE)) {
+ core_cfg->aud_par_busclk = 0;
+ core_cfg->cts_mode = HDMI_AUDIO_CTS_MODE_SW;
+ core_cfg->use_mclk = cpu_is_omap446x();
+ } else {
+ core_cfg->aud_par_busclk = (((128 * 31) - 1) << 8);
+ core_cfg->cts_mode = HDMI_AUDIO_CTS_MODE_HW;
+ core_cfg->use_mclk = true;
+ core_cfg->mclk_mode = HDMI_AUDIO_MCLK_128FS;
+ }
+ core_cfg->en_spdif = false;
+ /* Use sample frequency from channel status word */
+ core_cfg->fs_override = true;
+ /* Enable ACR packets */
+ core_cfg->en_acr_pkt = true;
+ /* Disable direct streaming digital audio */
+ core_cfg->en_dsd_audio = false;
+ /* Use parallel audio interface */
+ core_cfg->en_parallel_aud_input = true;
+
+ /* Number of channels */
+ channels_nr = params_channels(params);
+
+ switch (channels_nr) {
+ case 2:
+ core_cfg->layout = HDMI_AUDIO_LAYOUT_2CH;
+ channel_alloc = 0x0;
+ audio_format->stereo_channels = HDMI_AUDIO_STEREO_ONECHANNEL;
+ audio_format->active_chnnls_msk = 0x03;
+ /* Enable one of the four available serial data channels */
+ core_cfg->i2s_cfg.active_sds = HDMI_AUDIO_I2S_SD0_EN;
+ break;
+ case 6:
+ core_cfg->layout = HDMI_AUDIO_LAYOUT_8CH;
+ channel_alloc = 0xB;
+ audio_format->stereo_channels = HDMI_AUDIO_STEREO_FOURCHANNELS;
+ audio_format->active_chnnls_msk = 0x3f;
+ /* Enable all of the four available serial data channels */
+ core_cfg->i2s_cfg.active_sds = HDMI_AUDIO_I2S_SD0_EN |
+ HDMI_AUDIO_I2S_SD1_EN | HDMI_AUDIO_I2S_SD2_EN |
+ HDMI_AUDIO_I2S_SD3_EN;
+ break;
+ case 8:
+ core_cfg->layout = HDMI_AUDIO_LAYOUT_8CH;
+ channel_alloc = 0x13;
+ audio_format->stereo_channels = HDMI_AUDIO_STEREO_FOURCHANNELS;
+ audio_format->active_chnnls_msk = 0xff;
+ /* Enable all of the four available serial data channels */
+ core_cfg->i2s_cfg.active_sds = HDMI_AUDIO_I2S_SD0_EN |
+ HDMI_AUDIO_I2S_SD1_EN | HDMI_AUDIO_I2S_SD2_EN |
+ HDMI_AUDIO_I2S_SD3_EN;
+ break;
+ default:
+ dev_err(&pdev->dev, "Unsupported number of channels\n");
+ return -EINVAL;
+ }
+
+ hdmi_ti_4xxx_core_audio_config(&priv->ip_data, core_cfg);
+ hdmi_ti_4xxx_wp_audio_config_format(&priv->ip_data, audio_format);
+
+ /*
+ * Configure packet
+ * info frame audio see doc CEA861-D page 74
+ */
+ aud_if_cfg->db1_coding_type = HDMI_INFOFRAME_AUDIO_DB1CT_FROM_STREAM;
+ aud_if_cfg->db1_channel_count = channels_nr;
+ aud_if_cfg->db2_sample_freq = HDMI_INFOFRAME_AUDIO_DB2SF_FROM_STREAM;
+ aud_if_cfg->db2_sample_size = HDMI_INFOFRAME_AUDIO_DB2SS_FROM_STREAM;
+ aud_if_cfg->db4_channel_alloc = channel_alloc;
+ aud_if_cfg->db5_downmix_inh = false;
+ aud_if_cfg->db5_lsv = 0;
+
+ hdmi_ti_4xxx_core_audio_infoframe_config(&priv->ip_data, aud_if_cfg);
+ return 0;
+}
+
+static int hdmi_audio_trigger(struct snd_pcm_substream *substream, int cmd,
+ struct snd_soc_dai *dai)
+{
+ struct snd_soc_pcm_runtime *rtd = substream->private_data;
+ struct snd_soc_codec *codec = rtd->codec;
+ struct hdmi_data *priv = snd_soc_codec_get_drvdata(codec);
+ int err = 0;
+
+ switch (cmd) {
+ case SNDRV_PCM_TRIGGER_START:
+ case SNDRV_PCM_TRIGGER_RESUME:
+ case SNDRV_PCM_TRIGGER_PAUSE_RELEASE:
+ /*
+ * switch to no-idle to avoid DSS_L3_ICLK clock
+ * to be shutdown during audio activity (as per TRM)
+ */
+ omap_hwmod_set_slave_idlemode(priv->oh,
+ HWMOD_IDLEMODE_NO);
+ hdmi_ti_4xxx_audio_enable(&priv->ip_data, 1);
+ break;
+
+ case SNDRV_PCM_TRIGGER_STOP:
+ case SNDRV_PCM_TRIGGER_SUSPEND:
+ case SNDRV_PCM_TRIGGER_PAUSE_PUSH:
+ hdmi_ti_4xxx_audio_enable(&priv->ip_data, 0);
+ /*
+ * switch back to smart-idle & wakeup capable
+ * after audio activity stops
+ */
+ omap_hwmod_set_slave_idlemode(priv->oh,
+ HWMOD_IDLEMODE_SMART_WKUP);
+ break;
+ default:
+ err = -EINVAL;
+ }
+ return err;
+}
+
+static int hdmi_audio_startup(struct snd_pcm_substream *substream,
+ struct snd_soc_dai *dai)
+{
+ if (!omapdss_hdmi_get_mode()) {
+ pr_err("Current video settings do not support audio.\n");
+ return -EIO;
+ }
+ return 0;
+}
+static int hdmi_probe(struct snd_soc_codec *codec)
+{
+ struct hdmi_data *priv;
+ struct platform_device *pdev = to_platform_device(codec->dev);
+ struct resource *hdmi_rsrc;
+
+ priv = kzalloc(sizeof(struct hdmi_data), GFP_KERNEL);
+ if (priv == NULL)
+ return -ENOMEM;
+
+ snd_soc_codec_set_drvdata(codec, priv);
+
+
+ hdmi_rsrc = platform_get_resource(pdev, IORESOURCE_MEM, 0);
+
+ if (!hdmi_rsrc) {
+ dev_err(&pdev->dev, "Cannot obtain IORESOURCE_MEM HDMI\n");
+ return -EINVAL;
+ }
+
+
+ priv->oh = omap_hwmod_lookup("dss_hdmi");
+
+ if (!priv->oh) {
+ dev_err(&pdev->dev, "can't find omap_hwmod for hdmi\n");
+ return -ENODEV;
+ }
+
+ /* Base address taken from platform */
+ priv->ip_data.base_wp = ioremap(hdmi_rsrc->start,
+ resource_size(hdmi_rsrc));
+
+ if (!priv->ip_data.base_wp) {
+ dev_err(&pdev->dev, "can't ioremap WP\n");
+ return -ENOMEM;
+ }
+
+ priv->ip_data.hdmi_core_sys_offset = HDMI_CORE_SYS;
+ priv->ip_data.hdmi_core_av_offset = HDMI_CORE_AV;
+ priv->ip_data.hdmi_pll_offset = HDMI_PLLCTRL;
+ priv->ip_data.hdmi_phy_offset = HDMI_PHY;
+
+ return 0;
+}
+
+static int hdmi_remove(struct snd_soc_codec *codec)
+{
+ struct hdmi_data *priv = snd_soc_codec_get_drvdata(codec);
+ iounmap(priv->ip_data.base_wp);
+ kfree(priv);
+ return 0;
+}
+
+
+static struct snd_soc_codec_driver hdmi_audio_codec_drv = {
+ .probe = hdmi_probe,
+ .remove = hdmi_remove,
+};
+
+static struct snd_soc_dai_ops hdmi_audio_codec_ops = {
+ .hw_params = hdmi_audio_hw_params,
+ .trigger = hdmi_audio_trigger,
+ .startup = hdmi_audio_startup,
+};
+
+static struct snd_soc_dai_driver hdmi_codec_dai_drv = {
+ .name = "hdmi-audio-codec",
+ .playback = {
+ .channels_min = 2,
+ .channels_max = 8,
+ .rates = SNDRV_PCM_RATE_32000 |
+ SNDRV_PCM_RATE_44100 | SNDRV_PCM_RATE_48000,
+ .formats = SNDRV_PCM_FMTBIT_S16_LE |
+ SNDRV_PCM_FMTBIT_S24_LE,
+ },
+ .ops = &hdmi_audio_codec_ops,
+};
+
+static __devinit int hdmi_codec_probe(struct platform_device *pdev)
+{
+ int r;
+
+ /* Register ASoC codec DAI */
+ r = snd_soc_register_codec(&pdev->dev, &hdmi_audio_codec_drv,
+ &hdmi_codec_dai_drv, 1);
+ if (r) {
+ dev_err(&pdev->dev, "can't register ASoC HDMI audio codec\n");
+ return r;
+ }
+
+ return 0;
+}
+
+static int __devexit hdmi_codec_remove(struct platform_device *pdev)
+{
+ snd_soc_unregister_codec(&pdev->dev);
+ return 0;
+}
+
+
+static struct platform_driver hdmi_codec_driver = {
+ .probe = hdmi_codec_probe,
+ .remove = __devexit_p(hdmi_codec_remove),
+ .driver = {
+ .name = "omap-hdmi-codec",
+ .owner = THIS_MODULE,
+ },
+};
+
+
+static int __init hdmi_codec_init(void)
+{
+ return platform_driver_register(&hdmi_codec_driver);
+}
+module_init(hdmi_codec_init);
+
+static void __exit hdmi_codec_exit(void)
+{
+ platform_driver_unregister(&hdmi_codec_driver);
+}
+module_exit(hdmi_codec_exit);
+
+
+MODULE_AUTHOR("Ricardo Neri <ricardo.neri@ti.com>");
+MODULE_DESCRIPTION("ASoC HDMI codec driver");
+MODULE_LICENSE("GPL");
diff --git a/sound/soc/codecs/twl6040.c b/sound/soc/codecs/twl6040.c
index 25e8f43..508a122 100644
--- a/sound/soc/codecs/twl6040.c
+++ b/sound/soc/codecs/twl6040.c
@@ -316,6 +316,10 @@ static void twl6040_init_vio_regs(struct snd_soc_codec *codec)
case TWL6040_REG_ACCCTL:
case TWL6040_REG_STATUS:
continue;
+ case TWL6040_REG_HSOTRIM:
+ case TWL6040_REG_HFOTRIM:
+ twl6040_read_reg_volatile(codec, reg);
+ continue;
default:
break;
}
@@ -816,14 +820,14 @@ static int twl6040_power_mode_event(struct snd_soc_dapm_widget *w,
if (SND_SOC_DAPM_EVENT_ON(event)) {
priv->non_lp++;
- if (!strcmp(w->name, "Earphone Driver")) {
+ if (!strcmp(w->name, "Earphone Enable")) {
/* Earphone doesn't support low power mode */
priv->power_mode_forced = 1;
ret = headset_power_mode(codec, 1);
}
} else {
priv->non_lp--;
- if (!strcmp(w->name, "Earphone Driver")) {
+ if (!strcmp(w->name, "Earphone Enable")) {
priv->power_mode_forced = 0;
ret = headset_power_mode(codec, priv->headset_mode);
}
diff --git a/sound/soc/omap/Kconfig b/sound/soc/omap/Kconfig
index 9498fda..ffcfeee 100644
--- a/sound/soc/omap/Kconfig
+++ b/sound/soc/omap/Kconfig
@@ -20,6 +20,9 @@ config SND_OMAP_SOC_MCPDM
config SND_OMAP_SOC_ABE
tristate
+config SND_OMAP_SOC_HDMI
+ tristate
+
config SND_OMAP_SOC_N810
tristate "SoC Audio support for Nokia N810"
depends on SND_OMAP_SOC && MACH_NOKIA_N810 && I2C
@@ -116,6 +119,15 @@ config SND_OMAP_SOC_SDP4430
Say Y if you want to add support for SoC audio on Texas Instruments
SDP4430 or PandaBoard.
+config SND_OMAP_SOC_OMAP4_HDMI
+ tristate "SoC Audio support for Texas Instruments OMAP4 HDMI"
+ depends on SND_OMAP_SOC && OMAP4_DSS_HDMI && OMAP2_DSS && ARCH_OMAP4
+ select SND_OMAP_SOC_HDMI
+ select SND_SOC_OMAP_HDMI_CODEC
+ help
+ Say Y if you want to add support for SoC HDMI audio on Texas Instruments
+ OMAP4 chips
+
config SND_OMAP_SOC_OMAP3_PANDORA
tristate "SoC Audio support for OMAP3 Pandora"
depends on TWL4030_CORE && SND_OMAP_SOC && MACH_OMAP3_PANDORA
diff --git a/sound/soc/omap/Makefile b/sound/soc/omap/Makefile
index b66a476..f1deddc 100644
--- a/sound/soc/omap/Makefile
+++ b/sound/soc/omap/Makefile
@@ -5,6 +5,7 @@ snd-soc-omap-mcbsp-objs := omap-mcbsp.o
snd-soc-omap-mcpdm-objs := omap-mcpdm.o
snd-soc-omap-abe-objs := omap-abe.o
snd-soc-omap-abe-dsp-objs := omap-abe-dsp.o
+snd-soc-omap-hdmi-objs := omap-hdmi.o
obj-$(CONFIG_SND_OMAP_SOC) += snd-soc-omap.o
obj-$(CONFIG_SND_OMAP_SOC_MCASP) += snd-soc-omap-mcasp.o
@@ -12,6 +13,7 @@ obj-$(CONFIG_SND_OMAP_SOC_MCBSP) += snd-soc-omap-mcbsp.o
obj-$(CONFIG_SND_OMAP_SOC_MCPDM) += snd-soc-omap-mcpdm.o
obj-$(CONFIG_SND_OMAP_SOC_ABE) += snd-soc-omap-abe.o
obj-$(CONFIG_SND_OMAP_SOC_ABE_DSP) += snd-soc-omap-abe-dsp.o abe/
+obj-$(CONFIG_SND_OMAP_SOC_HDMI) += snd-soc-omap-hdmi.o
# OMAP Machine Support
snd-soc-n810-objs := n810.o
@@ -27,6 +29,7 @@ snd-soc-omap3pandora-objs := omap3pandora.o
snd-soc-omap3beagle-objs := omap3beagle.o
snd-soc-zoom2-objs := zoom2.o
snd-soc-igep0020-objs := igep0020.o
+snd-soc-omap4-hdmi-objs := omap4-hdmi-card.o
obj-$(CONFIG_SND_OMAP_SOC_N810) += snd-soc-n810.o
obj-$(CONFIG_SND_OMAP_SOC_RX51) += snd-soc-rx51.o
@@ -42,3 +45,4 @@ obj-$(CONFIG_SND_OMAP_SOC_OMAP3_PANDORA) += snd-soc-omap3pandora.o
obj-$(CONFIG_SND_OMAP_SOC_OMAP3_BEAGLE) += snd-soc-omap3beagle.o
obj-$(CONFIG_SND_OMAP_SOC_ZOOM2) += snd-soc-zoom2.o
obj-$(CONFIG_SND_OMAP_SOC_IGEP0020) += snd-soc-igep0020.o
+obj-$(CONFIG_SND_OMAP_SOC_OMAP4_HDMI) += snd-soc-omap4-hdmi.o
diff --git a/sound/soc/omap/abe/abe_dat.c b/sound/soc/omap/abe/abe_dat.c
index 62ec791..0111bae 100644
--- a/sound/soc/omap/abe/abe_dat.c
+++ b/sound/soc/omap/abe/abe_dat.c
@@ -71,7 +71,7 @@ const abe_port_t abe_port_init[LAST_PORT_ID] = {
reseted at start Port Name for the debug trace */
/* DMIC */ {
OMAP_ABE_PORT_ACTIVITY_IDLE, {96000, SIX_MSB},
- NODRIFT, NOCALLBACK, 0, (DMIC_ITER/6),
+ NODRIFT, NOCALLBACK, 1, (DMIC_ITER/6),
{
SNK_P, DMIC_PORT_PROT,
{{dmem_dmic, dmem_dmic_size, DMIC_ITER} }
@@ -205,7 +205,7 @@ const abe_port_t abe_port_init[LAST_PORT_ID] = {
{0, 0}, {0}, "BT_VX_DL"},
/* PDM_DL */ {
OMAP_ABE_PORT_ACTIVITY_IDLE, {96000, SIX_MSB},
- NODRIFT, NOCALLBACK, 0, (MCPDM_DL_ITER/6),
+ NODRIFT, NOCALLBACK, 1, (MCPDM_DL_ITER/6),
{SRC_P, MCPDMDL_PORT_PROT, {{dmem_mcpdm,
dmem_mcpdm_size} } },
{0, 0},
@@ -236,7 +236,7 @@ const abe_port_t abe_port_init[LAST_PORT_ID] = {
{0, 0}, {0}, "MM_EXT_IN"},
/* PCM3_TX */ {
OMAP_ABE_PORT_ACTIVITY_IDLE, {48000, STEREO_MSB},
- NODRIFT, NOCALLBACK, 0, 1,
+ NODRIFT, NOCALLBACK, 1, 1,
{
SRC_P, TDM_SERIAL_PORT_PROT, {{
(MCBSP3_DMA_TX *
@@ -249,7 +249,7 @@ const abe_port_t abe_port_init[LAST_PORT_ID] = {
{0, 0}, {0}, "TDM_OUT"},
/* PCM3_RX */ {
OMAP_ABE_PORT_ACTIVITY_IDLE, {48000, STEREO_MSB},
- NODRIFT, NOCALLBACK, 0, 1,
+ NODRIFT, NOCALLBACK, 1, 1,
{
SRC_P, TDM_SERIAL_PORT_PROT, {{
(MCBSP3_DMA_RX *
@@ -262,7 +262,7 @@ const abe_port_t abe_port_init[LAST_PORT_ID] = {
{0, 0}, {0}, "TDM_IN"},
/* SCHD_DBG_PORT */ {
OMAP_ABE_PORT_ACTIVITY_IDLE, {48000, MONO_MSB},
- NODRIFT, NOCALLBACK, 0, 1,
+ NODRIFT, NOCALLBACK, 1, 1,
{
SRC_P, DMAREQ_PORT_PROT, {{
(CBPr_DMA_RTX7 *
diff --git a/sound/soc/omap/abe/abe_define.h b/sound/soc/omap/abe/abe_define.h
index 41b700a..412fea8 100644
--- a/sound/soc/omap/abe/abe_define.h
+++ b/sound/soc/omap/abe/abe_define.h
@@ -57,7 +57,6 @@
*/
#ifndef _ABE_DEFINE_H_
#define _ABE_DEFINE_H_
-
#define ATC_DESCRIPTOR_NUMBER 64
#define PROCESSING_SLOTS 25
#define TASK_POOL_LENGTH 136
@@ -98,8 +97,8 @@
#define OUTPUT_SCALE_SHIFTM2 5160
#define NTAPS_SRC_44P1 24
#define NTAPS_SRC_44P1_M4 96
-#define NTAPS_SRC_44P1_THR 48
-#define NTAPS_SRC_44P1_THRM4 192
+#define NTAPS_SRC_44P1_THR 60
+#define NTAPS_SRC_44P1_THRM4 240
#define DRIFT_COUNTER_44P1M1 443
#define NB_OF_PHASES_SRC44P1 12
#define NB_OF_PHASES_SRC44P1M1 11
@@ -115,6 +114,7 @@
#define ASRC_BT_UL_FIR_L 19
#define ASRC_BT_DL_FIR_L 19
#define SRC44P1_COEF_ADDR 1466
-#define NTAPS_P_SRC_44P1_M4 144
-
+#define NTAPS_P_SRC_44P1_M4 192
+#define MAX_SMEM_CHECK 32
+#define SATURATION_EQ 9780
#endif /* _ABE_DEFINE_H_ */
diff --git a/sound/soc/omap/abe/abe_dm_addr.h b/sound/soc/omap/abe/abe_dm_addr.h
index a9c67a1..0e3fd57 100644
--- a/sound/soc/omap/abe/abe_dm_addr.h
+++ b/sound/soc/omap/abe/abe_dm_addr.h
@@ -100,12 +100,12 @@
#define OMAP_ABE_D_MCUIRQFIFO_ADDR 0x6B0
#define OMAP_ABE_D_MCUIRQFIFO_SIZE 0x40
#define OMAP_ABE_D_PINGPONGDESC_ADDR 0x6F0
-#define OMAP_ABE_D_PINGPONGDESC_SIZE 0x18
-#define OMAP_ABE_D_PP_MCU_IRQ_ADDR 0x708
+#define OMAP_ABE_D_PINGPONGDESC_SIZE 0x20
+#define OMAP_ABE_D_PP_MCU_IRQ_ADDR 0x710
#define OMAP_ABE_D_PP_MCU_IRQ_SIZE 0x2
-#define OMAP_ABE_D_SRC44P1_MMDL_STRUCT_ADDR 0x70C
+#define OMAP_ABE_D_SRC44P1_MMDL_STRUCT_ADDR 0x714
#define OMAP_ABE_D_SRC44P1_MMDL_STRUCT_SIZE 0x12
-#define OMAP_ABE_D_SRC44P1_TONES_STRUCT_ADDR 0x720
+#define OMAP_ABE_D_SRC44P1_TONES_STRUCT_ADDR 0x728
#define OMAP_ABE_D_SRC44P1_TONES_STRUCT_SIZE 0x12
#define OMAP_ABE_D_CTRLPORTFIFO_ADDR 0x740
#define OMAP_ABE_D_CTRLPORTFIFO_SIZE 0x10
@@ -143,8 +143,10 @@
#define OMAP_ABE_D_TRACEBUFOFFSET_SIZE 0x2
#define OMAP_ABE_D_TRACEBUFLENGTH_ADDR 0x8BC
#define OMAP_ABE_D_TRACEBUFLENGTH_SIZE 0x2
-#define OMAP_ABE_D_PEMPTY_ADDR 0x8C0
-#define OMAP_ABE_D_PEMPTY_SIZE 0x54
+#define OMAP_ABE_D_MAXTASKBYTESINSLOT_SAVED_ADDR 0x8C0
+#define OMAP_ABE_D_MAXTASKBYTESINSLOT_SAVED_SIZE 0x4
+#define OMAP_ABE_D_PEMPTY_ADDR 0x8C4
+#define OMAP_ABE_D_PEMPTY_SIZE 0x50
#define OMAP_ABE_D_ECHO_REF_48_16_WRAP_ADDR 0x914
#define OMAP_ABE_D_ECHO_REF_48_16_WRAP_SIZE 0x8
#define OMAP_ABE_D_ECHO_REF_48_8_WRAP_ADDR 0x91C
@@ -183,6 +185,10 @@
#define OMAP_ABE_D_HW_TEST_SIZE 0x28
#define OMAP_ABE_D_TRACEBUFADR_HAL_ADDR 0x126C
#define OMAP_ABE_D_TRACEBUFADR_HAL_SIZE 0x4
+#define OMAP_ABE_D_CHECK_LIST_SMEM_ADDR 0x1270
+#define OMAP_ABE_D_CHECK_LIST_SMEM_SIZE 0x80
+#define OMAP_ABE_D_CHECK_LIST_IDX_ADDR 0x12F0
+#define OMAP_ABE_D_CHECK_LIST_IDX_SIZE 0x2
#define OMAP_ABE_D_DEBUG_FW_TASK_ADDR 0x1400
#define OMAP_ABE_D_DEBUG_FW_TASK_SIZE 0x100
#define OMAP_ABE_D_DEBUG_FIFO_ADDR 0x1500
diff --git a/sound/soc/omap/abe/abe_firmware.c b/sound/soc/omap/abe/abe_firmware.c
index 0c8d06a..010eacc 100644
--- a/sound/soc/omap/abe/abe_firmware.c
+++ b/sound/soc/omap/abe/abe_firmware.c
@@ -1,9 +1,9 @@
0xabeabe00,
0x00000000,
-0x000187fc,
+0x00018804,
0x00000d8c,
0x00000001,
-0x00009460,
+0x00009492,
0x00000006,
0x20314c44,
0x61757145,
@@ -872,13 +872,13 @@
0x0033fbf6,
0xffdd34fa,
0x000fea26,
-0x00009460,
+0x00009492,
0x00002000,
0x00001b80,
0x00010000,
-0x00004c68,
+0x00004c70,
0x1600200f,
-0x0a000940,
+0x0a000960,
0x08200000,
0x08200000,
0x07800000,
@@ -901,31 +901,31 @@
0x014000ef,
0x144000e4,
0x9e000000,
-0x0a200e10,
+0x0a200e30,
0x9e000040,
-0x0a200e10,
+0x0a200e30,
0x9e000080,
-0x0a200e10,
+0x0a200e30,
0x9e0000c0,
-0x0a200e10,
+0x0a200e30,
0x9e080000,
-0x0a200e10,
+0x0a200e30,
0x9e080100,
-0x0a200e10,
+0x0a200e30,
0x9e080200,
-0x0a200e10,
+0x0a200e30,
0x9e080300,
-0x0a200e10,
+0x0a200e30,
0x9e080400,
-0x0a200e10,
+0x0a200e30,
0x9e080500,
-0x0a200e10,
+0x0a200e30,
0x9e080600,
-0x0a200e10,
+0x0a200e30,
0x9e080700,
-0x0a200e10,
+0x0a200e30,
0x9c050800,
-0x0a200e10,
+0x0a200e30,
0x16000010,
0x16000001,
0x17000102,
@@ -969,8 +969,10 @@
0x9f040040,
0x9c0c07b0,
0x9f03fc10,
+0x07800000,
0x9f092060,
0x9f082070,
+0x07800000,
0x98800520,
0x07800000,
0x9d0c8158,
@@ -979,7 +981,7 @@
0x07800000,
0x07800000,
0x9c03b660,
-0x0a000690,
+0x0a0006b0,
0x9d0c8118,
0x07800000,
0x9c0c07b0,
@@ -990,7 +992,7 @@
0x9c0c07b0,
0x9f092060,
0x9f082070,
-0x98800670,
+0x98800690,
0x07800000,
0x9d0c8118,
0x08200000,
@@ -1027,24 +1029,24 @@
0x08200000,
0x16006906,
0x00000068,
-0x16003fc5,
+0x16008c05,
0x01000058,
0x160069ca,
0x000000a9,
-0x16003fc6,
+0x16008c06,
0x00000068,
0x0400089b,
0x4000009c,
0x1600694e,
0x410000ec,
0x0600000c,
-0x1601270d,
-0x0a800a40,
-0x0a200750,
+0x16012f2d,
+0x0a800a60,
+0x0a200770,
0x04800299,
0x410000a9,
0x05c00b90,
-0x4ac009d0,
+0x4ac009f0,
0x04a01085,
0x16006a04,
0x40000047,
@@ -1057,7 +1059,7 @@
0x04a00111,
0x410000e1,
0x06000001,
-0x4aa00c20,
+0x4aa00c40,
0x16006a4d,
0x400000d6,
0x16004fc9,
@@ -1069,7 +1071,7 @@
0x010002d7,
0x16006906,
0x00000068,
-0x16003fc5,
+0x16008c05,
0x01000058,
0x1600c005,
0x16007541,
@@ -1084,8 +1086,8 @@
0x08400000,
0x01000004,
0x9d140550,
-0x0a800980,
-0x0a000c20,
+0x0a8009a0,
+0x0a000c40,
0x048006ff,
0x013ffafb,
0x013ffcfc,
@@ -1093,10 +1095,10 @@
0x04a0020b,
0x004002bc,
0x0600000c,
-0x1601270d,
-0x0a800dc0,
-0x0a200750,
-0x0a000d60,
+0x16012f2d,
+0x0a800de0,
+0x0a200770,
+0x0a000d80,
0x003ffefe,
0x003ffcfc,
0x003ffafb,
@@ -1132,12 +1134,13 @@
0x07800000,
0x07800000,
0x9d088118,
-0x98800f50,
+0x98800f70,
0x08200000,
0x9f158048,
0x9f040040,
0x9c0c07b0,
0x9f03fc10,
+0x07800000,
0x9f092020,
0x9f082030,
0x9c0c07b0,
@@ -1146,19 +1149,19 @@
0x07800000,
0x07800000,
0x9d188148,
-0x98801010,
+0x98801030,
0x08200000,
0x9f158048,
0x9c0c07b0,
-0x9f092020,
-0x9f082030,
-0x9c0c07b0,
0x9f092060,
0x9f082070,
+0x9c0c07b0,
+0x9f092020,
+0x9f082030,
0x07800000,
-0x9d188108,
0x9d188148,
-0x988010f0,
+0x9d188108,
+0x98801120,
0x08200000,
0x9f158048,
0x9c0c07b0,
@@ -1170,7 +1173,7 @@
0x07800000,
0x9d1e8148,
0x9d1e8108,
-0x988011b0,
+0x988011e0,
0x08200000,
0x9f158018,
0x9f040010,
@@ -1182,21 +1185,21 @@
0x9f092060,
0x9f082070,
0x9d1e8108,
-0x98801270,
+0x988012a0,
0x08200000,
0x9c080048,
0x9f1d0010,
0x07800000,
0x07800000,
0x9d0c8118,
-0x98801330,
+0x98801360,
0x08200000,
0x9c180028,
0x9f1d0010,
0x07800000,
0x07800000,
0x9d0c8108,
-0x988013a0,
+0x988013d0,
0x08200000,
0x9c180068,
0x9c180028,
@@ -1204,7 +1207,7 @@
0x07800000,
0x07800000,
0x9d0c8148,
-0x98801410,
+0x98801440,
0x08200000,
0x9c1e0048,
0x9c1e0008,
@@ -1212,14 +1215,14 @@
0x07800000,
0x07800000,
0x9d0c8148,
-0x98801490,
+0x988014c0,
0x08200000,
0x9c1e0008,
0x9f1d0010,
0x07800000,
0x07800000,
0x9d0c8108,
-0x98801510,
+0x98801540,
0x08200000,
0x160004a4,
0x160004b5,
@@ -1243,7 +1246,7 @@
0x07800000,
0x07800000,
0x9d0c8518,
-0x988015f0,
+0x98801620,
0x9d032340,
0x9d032c50,
0x9d033560,
@@ -1282,7 +1285,7 @@
0x07800000,
0x9d180108,
0x9d180148,
-0x988017c0,
+0x988017f0,
0x9d032440,
0x9d032d50,
0x9d033660,
@@ -1296,7 +1299,7 @@
0x9d188108,
0x9f158038,
0x07800000,
-0x98801a00,
+0x98801a30,
0x9d188108,
0x08200000,
0x9e088100,
@@ -1318,7 +1321,7 @@
0x07800000,
0x07800000,
0x9d0c8118,
-0x98801b80,
+0x98801bb0,
0x08200000,
0x08200000,
0x08200000,
@@ -1348,23 +1351,23 @@
0x9f0020b0,
0x9f0400d0,
0x05800560,
-0x0a801da0,
+0x0a801dd0,
0x9c0c0510,
-0x0a001db0,
+0x0a001de0,
0x9c0c0618,
0x16000014,
0x9d0c81e8,
0x9d0c8148,
-0x0a801e20,
+0x0a801e50,
0x9c0c05b0,
0x9c0c0510,
-0x0a001e40,
+0x0a001e70,
0x9c0c06b8,
0x9c0c0618,
0x07800000,
0x9d0c81e8,
0x9d0c8148,
-0x98801c20,
+0x98801c50,
0x9d180750,
0x08200000,
0x9d019220,
@@ -1373,17 +1376,23 @@
0x413ffefe,
0x16000040,
0x9c010910,
-0x0a204610,
+0x0a204740,
0x14400040,
0x9c030810,
0x16000171,
0x9c009f30,
0x9c019220,
-0x0a204110,
-0x9c009830,
+0x0a204240,
0x003ffefe,
+0x9c009830,
0x048ffeff,
0x08200000,
+0x40800907,
+0x160000bd,
+0x05800370,
+0x9e088000,
+0x0ba00000,
+0x0a002090,
0x40001807,
0x160000bd,
0x05800370,
@@ -1398,17 +1407,17 @@
0x05800570,
0x17800566,
0x04000677,
-0x04a09076,
+0x04a0c076,
0x05800560,
0x16000184,
-0x4ac021e0,
-0x04a0c077,
+0x4ac02270,
+0x04a0f077,
0x160003d6,
0x05800570,
0x9d02b060,
-0x0ac02130,
-0x01801005,
-0x0a002170,
+0x0ac021c0,
+0x01001005,
+0x0a002200,
0x9c1800a8,
0x9d02b060,
0x07800000,
@@ -1416,7 +1425,7 @@
0x07800000,
0x9c02b060,
0x9d0c8118,
-0x98802140,
+0x988021d0,
0x07800000,
0x08200000,
0x01000015,
@@ -1424,13 +1433,23 @@
0x9e0f0450,
0x9e0f0140,
0x08200000,
+0x40800907,
+0x160000bd,
+0x05800370,
+0x9e088000,
+0x0ba00000,
+0x048002ff,
+0x41001003,
+0x14400073,
+0x013ffefe,
+0x0a0023f0,
0x40001807,
0x160000bd,
0x05800370,
0x9e088000,
0x0ba00000,
0x048002ff,
-0x41801003,
+0x41001003,
0x14400073,
0x013ffefe,
0x9e088200,
@@ -1440,16 +1459,16 @@
0x05800570,
0x17800566,
0x04000677,
-0x04a09076,
+0x04a0c076,
0x05800560,
0x00000212,
-0x4ac027c0,
-0x04a0c077,
+0x4ac028f0,
+0x04a0f077,
0x05800570,
0x00000413,
-0x4ac023d0,
+0x4ac02500,
0x04800816,
-0x01801005,
+0x01001005,
0x00001017,
0x9e0e0760,
0xdc029e30,
@@ -1465,7 +1484,7 @@
0x16000184,
0x00000010,
0x9d029020,
-0x0a002500,
+0x0a002630,
0x9d0c8118,
0x9d029020,
0x9f0608b0,
@@ -1479,16 +1498,16 @@
0x05800050,
0x9f040070,
0x9f1185b2,
-0x0ae02650,
+0x0ae02780,
0xdd100380,
0x05800350,
0x9e0f0450,
-0x4ae02680,
+0x4ae027b0,
0x160000b0,
0x9f0304b0,
0x9d029020,
0x9d100380,
-0x4a002500,
+0x4a002630,
0x16001bb3,
0x9d100380,
0x9c1800a8,
@@ -1496,7 +1515,7 @@
0x9f1d8010,
0x9f138612,
0x9f1f8012,
-0x988024d0,
+0x98802600,
0x07800000,
0x9d0c8118,
0x04800814,
@@ -1520,7 +1539,7 @@
0x9e0f0250,
0x9e0f0450,
0x9e0f0040,
-0x0a0026e0,
+0x0a002810,
0x40000024,
0x048002ff,
0x41000224,
@@ -1529,7 +1548,7 @@
0x04000400,
0x9e0f0150,
0x01000025,
-0x0a202bb0,
+0x0a202ce0,
0x403ffefe,
0x16000007,
0x9e0f0170,
@@ -1545,7 +1564,7 @@
0x04000400,
0x9e0f0150,
0x01000025,
-0x0a2034f0,
+0x0a203620,
0x403ffefe,
0x16000007,
0x9e0f0170,
@@ -1555,7 +1574,7 @@
0x413ffefe,
0x16000005,
0x01000025,
-0x0a202bb0,
+0x0a202ce0,
0x40000024,
0x16000005,
0x403ffefe,
@@ -1568,7 +1587,7 @@
0x16000005,
0x01000025,
0x01800dc5,
-0x0a2034f0,
+0x0a203620,
0x40000024,
0x16000005,
0x403ffefe,
@@ -1593,25 +1612,25 @@
0x9c180674,
0x9c180650,
0x058001a0,
-0x0aa030b0,
+0x0aa031e0,
0x04800144,
0x04400044,
0x05800040,
-0x0aa02df0,
+0x0aa02f20,
0x05800160,
-0x0ac02d90,
+0x0ac02ec0,
0x9e090000,
0x07800000,
0x07800000,
0x9e0d0500,
0x9d040508,
-0x0a002f80,
+0x0a0030b0,
0x9d040008,
0x9e090000,
0x07800000,
0x9d040008,
0x9e0d0500,
-0x0a002f80,
+0x0a0030b0,
0x9d040008,
0x9e090000,
0x07800000,
@@ -1620,18 +1639,18 @@
0x1280010a,
0x048001a9,
0x05800940,
-0x0aa02f80,
+0x0aa030b0,
0x05800160,
0x40000628,
0x160ffff9,
-0x0ac02f10,
+0x0ac03040,
0x05800180,
-0x0ae02f80,
+0x0ae030b0,
0x160ffff6,
0x160ffff7,
-0x0a002f50,
+0x0a003080,
0x05800810,
-0x0ae02f80,
+0x0ae030b0,
0x16000016,
0x16000007,
0x9d044690,
@@ -1639,10 +1658,10 @@
0x9d180674,
0x05800160,
0x9d180654,
-0x0ac02ff0,
+0x0ac03120,
0x0420040a,
0x04a001ab,
-0x4a003020,
+0x4a003150,
0x044000bb,
0x0480014b,
0x044000bb,
@@ -1654,24 +1673,24 @@
0x12000288,
0x12000299,
0x9e0e8280,
-0xca0031c0,
+0xca0032f0,
0x1e0e8390,
0xdd040604,
0x05800160,
-0x0ac03160,
+0x0ac03290,
0x9d040008,
0x9e090000,
0x07800000,
0x05800040,
0x9e0d0500,
-0x0aa031c0,
+0x0aa032f0,
0x9d040508,
-0x0a0031c0,
+0x0a0032f0,
0x9e090000,
0x05800040,
0x9d040008,
0x9e0d0500,
-0x0a8031c0,
+0x0a8032f0,
0x9d040508,
0x9c1d06c4,
0xdc1d0644,
@@ -1684,7 +1703,7 @@
0x9d108700,
0x00000cc9,
0x06000008,
-0x0aa033c0,
+0x0aa034f0,
0xdc1d0684,
0x14400005,
0xdc1d0604,
@@ -1695,16 +1714,16 @@
0xdd108700,
0x160ffff8,
0x05800540,
-0x0aa03380,
+0x0aa034b0,
0x05800160,
-0x0ac03370,
+0x0ac034a0,
0x01000027,
-0x0a003380,
+0x0a0034b0,
0x01000028,
0x9e088000,
0xa0054dba,
0xa005c81a,
-0x0a003450,
+0x0a003580,
0x9e088000,
0xa0054dba,
0xa005c81a,
@@ -1717,7 +1736,7 @@
0x9d0446a0,
0x9e0f0070,
0x9d0c8118,
-0x98802c50,
+0x98802d80,
0x003ffefb,
0x003ffcfa,
0x003ffaf9,
@@ -1741,26 +1760,26 @@
0x9c180674,
0x9c180650,
0x058001a0,
-0x4aa03a20,
+0x4aa03b50,
0x160000f7,
0x04800144,
0x04400744,
0x05800740,
-0x0aa03740,
+0x0aa03870,
0x05800160,
-0x0ac036e0,
+0x0ac03810,
0x9e090000,
0x07800000,
0x07800000,
0x9e0d0500,
0x9d040508,
-0x0a0038e0,
+0x0a003a10,
0x9d040008,
0x9e090000,
0x07800000,
0x9d040008,
0x9e0d0500,
-0x0a0038e0,
+0x0a003a10,
0x9d040008,
0x9e090000,
0x160000f7,
@@ -1769,19 +1788,19 @@
0x1280017a,
0x048001a9,
0x05800940,
-0x0aa038e0,
+0x0aa03a10,
0x05800160,
0x00000ec8,
0x40000688,
0x160ffff9,
-0x0ac03870,
+0x0ac039a0,
0x05800810,
-0x0ae038e0,
+0x0ae03a10,
0x160ffff6,
0x160ffff7,
-0x0a0038b0,
+0x0a0039e0,
0x05800180,
-0x0ae038e0,
+0x0ae03a10,
0x16000016,
0x16000007,
0x9d044690,
@@ -1789,11 +1808,11 @@
0x9d180674,
0x05800160,
0x9d180654,
-0x4ac03960,
+0x4ac03a90,
0x160000f7,
0x0420047a,
0x04a001ab,
-0x4a003990,
+0x4a003ac0,
0x044007bb,
0x0480014b,
0x044007bb,
@@ -1805,27 +1824,27 @@
0x12000288,
0x12000299,
0x9e0e8280,
-0xca003b30,
+0xca003c60,
0x1e0e8390,
0xdd040604,
0x05800160,
-0x0ac03ad0,
+0x0ac03c00,
0x9d040008,
0x9e090000,
0x07800000,
0x060000f4,
0x9e0d0500,
-0x0aa03b30,
+0x0aa03c60,
0x9d040508,
-0x0a003b30,
+0x0a003c60,
0x9e090000,
0x060000f4,
0x9d040008,
0x9e0d0500,
-0x0a803b30,
+0x0a803c60,
0x9d040508,
0x060000f4,
-0x0aa03db0,
+0x0aa03ee0,
0x9c1d0600,
0x9f065060,
0x9f020830,
@@ -1835,16 +1854,16 @@
0x9f065060,
0x9f020c30,
0x0600000a,
-0x0a803db0,
+0x0a803ee0,
0x9f095010,
0x00800dcb,
0x16000028,
0x0600000a,
-0x0aa03db0,
+0x0aa03ee0,
0x0600000b,
-0x0a803d20,
+0x0a803e50,
0x0600000d,
-0x0aa03db0,
+0x0aa03ee0,
0x9d044480,
0x9d044780,
0x9c100480,
@@ -1854,9 +1873,9 @@
0x9d044680,
0x9d108480,
0x9d108700,
-0x0a003e30,
+0x0a003f60,
0x058000d0,
-0x0aa03db0,
+0x0aa03ee0,
0x9d044490,
0x9c100700,
0x9d044790,
@@ -1878,7 +1897,7 @@
0x07800000,
0x00800cc9,
0x06000008,
-0x0aa03fe0,
+0x0aa04110,
0xdc1d0684,
0x160000f5,
0xdc1d0604,
@@ -1889,16 +1908,16 @@
0xdd108700,
0x160ffff8,
0x05800540,
-0x0aa03fa0,
+0x0aa040d0,
0x05800160,
-0x0ac03f90,
+0x0ac040c0,
0x01000027,
-0x0a003fa0,
+0x0a0040d0,
0x01000028,
0x9e088000,
0xa0054dba,
0xa005c81a,
-0x0a004070,
+0x0a0041a0,
0x9e088000,
0xa0054dba,
0xa005c81a,
@@ -1911,7 +1930,7 @@
0x9d0446a0,
0x9e0f0070,
0x9d0c8118,
-0x98803590,
+0x988036c0,
0x003ffefb,
0x003ffcfa,
0x003ffaf9,
@@ -1929,7 +1948,7 @@
0x9d0c8318,
0x9d0c81b8,
0x9d0c02b8,
-0x98804160,
+0x98804290,
0x07800000,
0xa00602ba,
0x07800000,
@@ -1954,7 +1973,7 @@
0x07800000,
0x9d0c8318,
0x9d0c02b8,
-0x98804290,
+0x988043c0,
0x9c0c0018,
0xa00602ba,
0x07800000,
@@ -1979,7 +1998,7 @@
0x9d0c8298,
0x9d0c8338,
0x9d0c8198,
-0x98804470,
+0x988045a0,
0x07800000,
0xa00602ba,
0xa006821a,
@@ -1994,9 +2013,9 @@
0xdd040008,
0x06000001,
0x04a00111,
-0x0aa04590,
+0x0aa046c0,
0x9d0c8118,
-0x98804570,
+0x988046a0,
0x08200000,
0x9c0c02b0,
0x9c0c0018,
@@ -2006,8 +2025,8 @@
0xdd0c81b8,
0x06000005,
0x04a00155,
-0x0aa04660,
-0x98804620,
+0x0aa04790,
+0x98804750,
0x08200000,
0x9c039e30,
0x07800000,
@@ -2031,7 +2050,7 @@
0x9d0c8318,
0x9d0c81b8,
0x9d0c02b8,
-0x98804740,
+0x98804870,
0x9c0c0510,
0xa00602ba,
0x07800000,
@@ -2055,7 +2074,7 @@
0x07800000,
0x07800000,
0x9d0c81b8,
-0x98804960,
+0x98804a90,
0x1440001d,
0x9d0c8218,
0x04a001dd,
@@ -2063,7 +2082,7 @@
0x07800000,
0x07800000,
0x9d0c81b8,
-0x988049e0,
+0x98804b10,
0x08200000,
0x9f160028,
0x9f168298,
@@ -2073,7 +2092,7 @@
0x07800000,
0x9f160028,
0x9f168298,
-0x98804a80,
+0x98804bb0,
0x9d0c8128,
0x08200000,
0x9f160020,
@@ -2088,7 +2107,7 @@
0x07800000,
0x9d0c8108,
0x9d0c8258,
-0x98804af0,
+0x98804c20,
0x08200000,
0x9f160020,
0x9f168098,
@@ -2101,7 +2120,7 @@
0x07800000,
0x07800000,
0x9d0c8118,
-0x98804bd0,
+0x98804d00,
0x08200000,
0x9d008810,
0x1280020d,
@@ -2125,7 +2144,7 @@
0x9d0c87b8,
0x9d1082c8,
0x9d108288,
-0x98804d00,
+0x98804e30,
0x08200000,
0x00000003,
0x00000205,
@@ -2138,22 +2157,25 @@
0x07800000,
0x07800000,
0x9d0c8128,
-0x98804e80,
+0x98804fb0,
0x08200000,
+0x00001007,
0x048002ff,
0x013ffefe,
+0x06000007,
0x00801605,
-0x16012ac3,
+0x16013343,
+0x0a805170,
0x12000155,
0x0200035e,
0x0b200000,
0x00800405,
-0x16012ac3,
+0x16013343,
0x12000155,
0x0200035e,
0x0b200000,
0x00801705,
-0x16012ac3,
+0x16013343,
0x12000155,
0x0200035e,
0x0b200000,
@@ -2161,11 +2183,11 @@
0x048ffeff,
0x07800000,
0x08200000,
-0x048004ff,
+0x00800b03,
0x16000181,
+0x048004ff,
0x40800a0d,
0x04000101,
-0x00800b03,
0x00000212,
0x00000017,
0x9e0e0420,
@@ -2173,7 +2195,7 @@
0xdc180404,
0x06000003,
0x9c180480,
-0x0aa054c0,
+0x0aa05620,
0x9c052b20,
0x9c042820,
0x9c023970,
@@ -2182,38 +2204,38 @@
0x40800503,
0x0600000d,
0x9d01b060,
-0x4a805220,
+0x4a805380,
0x0400033d,
0x04200427,
0x04200d77,
0x05800750,
-0x0ae05220,
+0x0ae05380,
0x16000006,
0x16000145,
-0x0a0054a0,
+0x0a005600,
0x160fffd6,
0x05800420,
-0x0ae053a0,
+0x0ae05500,
0x160fffe6,
0x04000344,
0x05800420,
-0x0ae05490,
+0x0ae055f0,
0x160ffff6,
0x04000344,
0x05800420,
-0x0ae05490,
+0x0ae055f0,
0x16000006,
0x04000344,
0x05800420,
-0x0ae05490,
+0x0ae055f0,
0x16000016,
0x04000344,
0x05800420,
-0x0ae05490,
+0x0ae055f0,
0x16000026,
0x04000344,
0x05800420,
-0x0ae05490,
+0x0ae055f0,
0x16000036,
0x013ffcf6,
0x12000132,
@@ -2232,7 +2254,7 @@
0x003ffcf6,
0x00800715,
0x01000606,
-0x0a0058d0,
+0x0a005a30,
0x9c042b20,
0x9c052920,
0x9c023870,
@@ -2244,43 +2266,43 @@
0x160fffb6,
0x00800503,
0x05800420,
-0x0ae057d0,
+0x0ae05930,
0x160fffc6,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x160fffd6,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x160fffe6,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x160ffff6,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x16000006,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x16000016,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x16000026,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x16000036,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x16000046,
0x04000344,
0x05800420,
-0x0ae058b0,
+0x0ae05a10,
0x16000056,
0x013ffcf6,
0x12000232,
@@ -2298,7 +2320,7 @@
0x003ffcf6,
0x01000606,
0x00800715,
-0x16012ac6,
+0x16013346,
0x413ffefe,
0x12000155,
0x00000202,
@@ -2323,7 +2345,7 @@
0x06000005,
0x40800f02,
0x04c07f77,
-0x4a805b20,
+0x4a805c80,
0x04500273,
0x00800a02,
0x9e088100,
@@ -2374,55 +2396,58 @@
0x9d0c810c,
0x9d0c815c,
0x9d0c81ac,
-0x98805d30,
-0x0aa05cb0,
+0x98805e90,
+0x0aa05e10,
0x9e0f0120,
0x08200000,
-0x4080070d,
-0x048002ff,
+0x00001004,
+0x0080070d,
+0x06000004,
0x00800203,
-0x00800905,
-0x40000e04,
+0x0b800000,
+0x40800905,
+0x048002ff,
+0x40001604,
0x040003dd,
0x413ffefe,
0x06000004,
0x9c03a950,
-0x4aa05ed0,
+0x4aa06060,
0x144000d2,
-0x0a206190,
-0x40000e04,
+0x0a206320,
+0x40001604,
0x1440002d,
0x06000004,
-0x0a806010,
+0x0a8061a0,
0x05800d40,
-0x0ae05f10,
-0x0a206040,
-0x0a005fc0,
+0x0ae060a0,
+0x0a2061d0,
+0x0a006150,
0x042004d2,
0x1440004d,
-0x0a206040,
-0x0a206190,
+0x0a2061d0,
+0x0a206320,
0x06000002,
-0x0a805fc0,
+0x0a806150,
0x1440002d,
-0x00000e04,
+0x00001604,
0x05800d40,
-0x0ac06010,
-0x0a206040,
+0x0ac061a0,
+0x0a2061d0,
0x003ffefe,
0x40800905,
0x048ffeff,
0x9d03a950,
0x08200000,
0x04a0012d,
-0x0a201a60,
-0x0a005fc0,
+0x0a201a90,
+0x0a006150,
0x16014246,
0x40800605,
0x048002ff,
0x413ffefe,
0x144000d3,
-0x16012ace,
+0x1601334e,
0x9e0e0260,
0x12000155,
0x420005ee,
@@ -2431,45 +2456,45 @@
0x9e088000,
0x403ffefe,
0x16000006,
-0x40000e05,
+0x40001605,
0x048ffeff,
0x9e0e8040,
0x9e0f0060,
0x04200355,
-0x01000e05,
+0x01001605,
0x08200000,
0x40800b0d,
0x16000246,
0x40000403,
0x04c001d7,
0x06000007,
-0x4a806280,
+0x4a806410,
0x16000017,
-0x00001604,
+0x00001e04,
0x06000004,
-0x0a8063a0,
-0x40001405,
+0x0a806530,
+0x40001c05,
0x048001dd,
-0x01000e04,
-0x01000c05,
-0x0a0062f0,
-0x00001204,
+0x01001604,
+0x01001405,
+0x0a006480,
+0x00001a04,
0x06000004,
-0x0a8063a0,
-0x40001005,
+0x0a806530,
+0x40001805,
0x048001dd,
-0x01000e04,
-0x01000c05,
+0x01001604,
+0x01001405,
0x9e0e8050,
0x41800b0d,
0x16000005,
0x40800a04,
0x05c00630,
-0x0a806390,
+0x0a806520,
0x12000233,
0x9e0e0530,
0x9d140550,
-0x0a0063a0,
+0x0a006530,
0x01800017,
0x08200000,
0x048008ff,
@@ -2495,13 +2520,13 @@
0x01c00127,
0x01c0012b,
0x9c018201,
-0x988064a0,
+0x98806630,
0x04800633,
0x1440001d,
0x00000034,
0x04802833,
0x01c00124,
-0x98806550,
+0x988066e0,
0x16002102,
0x9e0e0220,
0x16000806,
@@ -2515,14 +2540,14 @@
0x16000005,
0x16000006,
0x06000008,
-0x0aa06690,
+0x0aa06820,
0x16000015,
0x000002a8,
0x06000009,
-0x0aa066d0,
+0x0aa06860,
0x16000016,
0x000002b9,
-0x16007082,
+0x16007102,
0x410000a8,
0x12000166,
0x410000b9,
@@ -2531,12 +2556,12 @@
0x16006a4d,
0x41800027,
0x06000004,
-0x0aa067c0,
+0x0aa06950,
0x06000005,
-0x0aa06840,
+0x0aa069d0,
0x06000001,
-0x0aa068d0,
-0x0a0069c0,
+0x0aa06a60,
+0x0a006b50,
0x160000a8,
0x400000d6,
0x12000c88,
@@ -2544,7 +2569,7 @@
0x07800000,
0x06000005,
0x9d180078,
-0x0a8068b0,
+0x0a806a40,
0x160000c8,
0x400000d6,
0x12000c88,
@@ -2553,7 +2578,7 @@
0x07800000,
0x9d180078,
0x06000001,
-0x0a806940,
+0x0a806ad0,
0x160000d8,
0x400000d6,
0x12000c88,
@@ -2576,7 +2601,7 @@
0x06000000,
0x40000049,
0x16006a82,
-0x4a806a60,
+0x4a806bf0,
0x16000005,
0x04200959,
0x05800590,
@@ -2716,6 +2741,73 @@
0x003ff8f8,
0x048ff8ff,
0x08200000,
+0x16000023,
+0x16012f01,
+0x160003c5,
+0x00000010,
+0x04800200,
+0x9c01aa50,
+0x04c03f00,
+0x16012704,
+0x01000010,
+0x04000400,
+0x00000005,
+0x07800000,
+0x07800000,
+0x9c00a850,
+0x07800000,
+0x07800000,
+0x9e088000,
+0x9f038490,
+0x07800000,
+0x12800266,
+0x04c0ff6d,
+0x9c0c0018,
+0x9f0b0010,
+0x9f092080,
+0x07800000,
+0x9f092090,
+0x988075d0,
+0x9c0c0330,
+0x9f03fc30,
+0x07800000,
+0x07800000,
+0x9f0920e0,
+0x07800000,
+0x07800000,
+0x06000004,
+0x0a807820,
+0x00000010,
+0x04800200,
+0x9c01aa50,
+0x04c03f00,
+0x16012704,
+0x04000400,
+0x00000005,
+0x07800000,
+0x07800000,
+0x9c00a850,
+0x07800000,
+0x07800000,
+0x9e088000,
+0x9f038490,
+0x07800000,
+0x12800266,
+0x04c0ff6d,
+0x9f038410,
+0x07800000,
+0x07800000,
+0x9d0c8018,
+0x98807800,
+0x00000010,
+0x04800200,
+0x04c03f00,
+0x07800000,
+0x01000010,
+0x04a00133,
+0x06000003,
+0x0aa07490,
+0x08200000,
0x00000004,
0x00000405,
0x00000806,
@@ -2728,20 +2820,20 @@
0x07800000,
0x06000033,
0x9e0e8220,
-0x0aa07410,
+0x0aa079d0,
0x9c1d0004,
0x9c1d0044,
0x07800000,
0x9d0c0210,
-0x0a0074c0,
+0x0a007a80,
0x06000023,
-0x0aa07470,
+0x0aa07a30,
0x9c1d0004,
0x9d040004,
0x9d100200,
-0x0a0074c0,
+0x0a007a80,
0x06000043,
-0x0aa074c0,
+0x0aa07a80,
0x9c180024,
0x9d040004,
0x9d180200,
@@ -2749,99 +2841,7 @@
0x05c00740,
0x17800644,
0x01000004,
-0x0a007330,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
+0x0a0078f0,
0x00000000,
0x00000000,
0x00000000,
@@ -3083,7 +3083,7 @@
0x00000000,
0x00001000,
0x00001000,
-0x000000a6,
+0x0000004d,
0x000000a8,
0x00001000,
0x00001000,
@@ -3096,6 +3096,8 @@
0x00001000,
0x003c1000,
0x00001001,
+0x00001000,
+0x0000004d,
0x00000000,
0x00000000,
0x00000000,
@@ -3114,9 +3116,7 @@
0x00000000,
0x00000000,
0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
+0x00001001,
0x00001001,
0x00001000,
0x00001051,
@@ -4841,7 +4841,7 @@
0x00000000,
0x00000000,
0x00000000,
-0x00009460,
+0x00009492,
0x00000000,
0x00000000,
0x00000000,
@@ -5136,6 +5136,8 @@
0x00000000,
0x00000000,
0x00000000,
+0x00000000,
+0x00000000,
0x00a0000c,
0x003c00a1,
0x00000000,
@@ -5189,8 +5191,6 @@
0x00000000,
0x00000000,
0x00000000,
-0x00000000,
-0x00000000,
0x0000000a,
0x7fff7fff,
0x7fff7fff,
@@ -5362,11 +5362,11 @@
0x0001012a,
0x00910001,
0x00000000,
-0x004d0003,
+0x00ab0003,
0x0001008e,
0x00900001,
0x00000000,
-0x004d0003,
+0x00ab0003,
0x0001008f,
0x00910001,
0x00000000,
@@ -5455,7 +5455,7 @@
0x00950078,
0x00000000,
0x00270000,
-0x008b004d,
+0x008b00ab,
0x00920073,
0x00000000,
0x008e0000,
@@ -5463,7 +5463,7 @@
0x00930075,
0x00000000,
0x00270000,
-0x0089004d,
+0x008900ab,
0x00940076,
0x00000000,
0x008f0000,
@@ -5803,7 +5803,7 @@
0x01390001,
0x00000000,
0x00a7001c,
-0x00a60008,
+0x004d0008,
0x009e009c,
0x00000000,
0x00a9001c,
@@ -5811,24 +5811,24 @@
0x009f009d,
0x00000000,
0x00a7001d,
-0x00a60008,
+0x004d0008,
0x009e009c,
0x00000000,
0x00a9001d,
0x00a80025,
0x009f009d,
0x00000000,
+0x00a7001e,
+0x004d0008,
+0x00ac009c,
0x00000000,
+0x00a7001f,
+0x004d0008,
+0x00ac009c,
0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
+0x00010020,
+0x00010001,
+0x00000001,
0x00000000,
0x00000000,
0x00000000,
@@ -5865,66 +5865,66 @@
0x00000000,
0x00000000,
0x00003000,
-0x04a40411,
-0x045704af,
-0x00620461,
-0x004d0038,
-0x04e204bd,
-0x044204ca,
-0x04ef05dd,
-0x00e7063b,
-0x01ea01be,
-0x00d10424,
-0x028402a2,
-0x06b9072f,
-0x02ae046c,
-0x04900292,
-0x01fb0223,
-0x00f50002,
-0x010f0101,
-0x0127011b,
-0x013a0133,
-0x01490151,
-0x01580141,
-0x019a0173,
-0x01bb0003,
-0x01bd01bc,
-0x050405bc,
-0x000001a6,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
+0x0041008a,
+0x003300d3,
+0x003600d8,
+0x003900d9,
+0x010500da,
+0x0105007d,
+0x0060007e,
+0x0060007e,
+0x010b007d,
+0x010b0082,
+0x01080081,
+0x01080082,
+0x00030081,
+0x00030134,
+0x00030079,
+0x0024007a,
+0x00240134,
+0x00240079,
+0x0107007a,
+0x01070085,
+0x01090086,
+0x01090085,
+0x002a0086,
+0x002f002b,
+0x0050006f,
+0x00300096,
+0x00510071,
+0x00ab0098,
+0x00ab008b,
+0x008d008c,
+0x008d008b,
+0x008d008c,
+0x04240000,
+0x04c204b7,
+0x0474046a,
+0x00380064,
+0x04d0004d,
+0x04dd04f5,
+0x05f30455,
+0x06540502,
+0x01c100e9,
+0x043701ed,
+0x02b500d3,
+0x078b0297,
+0x047f06d2,
+0x02a502c1,
+0x023604a3,
+0x022c0204,
+0x074801fe,
+0x00f70002,
+0x01120103,
+0x012a011e,
+0x013d0136,
+0x014c0154,
+0x015b0144,
+0x019d0176,
+0x01be0003,
+0x01c001bf,
+0x051a05d2,
+0x000001a9,
0x00000000,
0x00000000,
0x00000000,
@@ -21224,7 +21224,7 @@
0x00000000,
0x00043318,
0x00000000,
-0x0004630c,
+0x0008c860,
0x000b0019,
0x00000000,
0x000b0009,
@@ -21385,9 +21385,9 @@
0x0005ba01,
0x00000000,
0x0005ba01,
-0x000c0364,
+0x00140364,
0x00000007,
-0x002003b4,
+0x002803b4,
0x00000007,
0x00000000,
0x0006da02,
@@ -21412,6 +21412,9 @@
0x00050c01,
0x00083918,
0x00000000,
+0x0004630c,
+0x001406f0,
+0x00000007,
0x00000000,
0x00000000,
0x00000000,
@@ -21448,11 +21451,8 @@
0x00000000,
0x00000000,
0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
-0x00000000,
+0x00098d01,
+0x00098d01,
0x00000000,
0x00072706,
0x00028300,
@@ -21479,7 +21479,7 @@
0x0006fb00,
0x00019000,
0x00071400,
-0x00023000,
+0x00023100,
0x00071512,
0x00ea00cd,
0x000026ff,
@@ -21693,7 +21693,7 @@
0x00000000,
0x00000000,
0x00100020,
-0x000806f0,
+0x001006f0,
0x00000007,
0x000009bc,
0x00000000,
@@ -25959,3 +25959,5 @@
0x00000000,
0x000049cc,
0x000049cc,
+0x00700000,
+0x00900000,
diff --git a/sound/soc/omap/abe/abe_functionsid.h b/sound/soc/omap/abe/abe_functionsid.h
index db21988..2973ab7 100644
--- a/sound/soc/omap/abe/abe_functionsid.h
+++ b/sound/soc/omap/abe/abe_functionsid.h
@@ -90,6 +90,9 @@
#define C_ABE_FW_FUNCTION_FIR6 27
#define C_ABE_FW_FUNCTION_SRC44P1 28
#define C_ABE_FW_FUNCTION_SRC44P1_1211 29
+#define C_ABE_FW_FUNCTION_SRC44P1_PP 30
+#define C_ABE_FW_FUNCTION_SRC44P1_1211_PP 31
+#define C_ABE_FW_FUNCTION_CHECK_IIR 32
/*
* COPY function ID definitions
*/
diff --git a/sound/soc/omap/abe/abe_ini.c b/sound/soc/omap/abe/abe_ini.c
index ab92cf1..6943bb1 100644
--- a/sound/soc/omap/abe/abe_ini.c
+++ b/sound/soc/omap/abe/abe_ini.c
@@ -345,6 +345,7 @@ void omap_abe_build_scheduler_table(struct omap_abe *abe)
abe->MultiFrame[22][4] = ABE_TASK_ID(C_ABE_FW_TASK_MM_EXT_IN_SPLIT);
abe->MultiFrame[23][0] = ABE_TASK_ID(C_ABE_FW_TASK_GAIN_UPDATE);
+ abe->MultiFrame[23][2] = ABE_TASK_ID(C_ABE_FW_TASK_CHECK_IIR);
omap_abe_mem_write(abe, OMAP_ABE_DMEM, OMAP_ABE_D_MULTIFRAME_ADDR,
(u32 *) abe->MultiFrame, sizeof(abe->MultiFrame));
diff --git a/sound/soc/omap/abe/abe_initxxx_labels.h b/sound/soc/omap/abe/abe_initxxx_labels.h
index 66f1856..11ef3d0 100644
--- a/sound/soc/omap/abe/abe_initxxx_labels.h
+++ b/sound/soc/omap/abe/abe_initxxx_labels.h
@@ -134,7 +134,7 @@
#define DMIC0_96_labelID 74
#define DMIC1_96_labelID 75
#define DMIC2_96_labelID 76
-#define UL_MIC_48K_labelID 77
+#define MM_DL_44P1_WPTR_labelID 77
#define EQ_DL_48K_labelID 78
#define EQ_48K_labelID 79
#define McPDM_Out1_labelID 80
@@ -223,13 +223,13 @@
#define TONES_44P1_XK_labelID 163
#define SRC_44P1_MULFAC1_2_labelID 164
#define A00_labelID 165
-#define MM_DL_44P1_WPTR_labelID 166
+#define MM_DL_44P1_WPTR1_labelID 166
#define MM_DL_44P1_RPTR_labelID 167
#define TONES_44P1_WPTR_labelID 168
#define TONES_44P1_RPTR_labelID 169
#define C_0DB_SAT_labelID 170
-#define AC_labelID 171
-#define AD_labelID 172
+#define UL_MIC_48K_labelID 171
+#define MM_DL_44P1_PP_REGS_labelID 172
#define AE_labelID 173
#define AF_labelID 174
#define AG_labelID 175
@@ -248,7 +248,7 @@
#define AT_labelID 188
#define AU_labelID 189
#define AV_labelID 190
-#define AW_labelID 191
+#define SaturationMinMaxEQ_labelID 191
#define pVIBRA1_p0_labelID 192
#define pVIBRA1_p1_labelID 193
#define pVIBRA1_p23_labelID 194
diff --git a/sound/soc/omap/abe/abe_main.h b/sound/soc/omap/abe/abe_main.h
index fa88384..2762ac0 100644
--- a/sound/soc/omap/abe/abe_main.h
+++ b/sound/soc/omap/abe/abe_main.h
@@ -656,6 +656,7 @@ u32 abe_connect_serial_port(u32 id, abe_data_format_t *f,
u32 abe_read_port_address(u32 port, abe_dma_t *dma2);
void abe_add_subroutine(u32 *id, abe_subroutine2 f, u32 nparam, u32 *params);
u32 abe_read_next_ping_pong_buffer(u32 port, u32 *p, u32 *n);
+void abe_write_pdmdl_offset(u32 path, u32 offset_left, u32 offset_right);
u32 abe_reset_vx_ul_src_filters(void);
u32 abe_reset_mic_ul_src_filters(void);
u32 abe_reset_vx_dl_src_filters(void);
diff --git a/sound/soc/omap/abe/abe_sm_addr.h b/sound/soc/omap/abe/abe_sm_addr.h
index a9e28ac..8a0d37f 100644
--- a/sound/soc/omap/abe/abe_sm_addr.h
+++ b/sound/soc/omap/abe/abe_sm_addr.h
@@ -351,3 +351,5 @@
#define OMAP_ABE_S_TONES_44P1_XK_SIZE 0x10
#define OMAP_ABE_S_SRC_44P1_MULFAC1_ADDR 0x4C60
#define OMAP_ABE_S_SRC_44P1_MULFAC1_SIZE 0x8
+#define OMAP_ABE_S_SATURATION_EQ_ADDR 0x4C68
+#define OMAP_ABE_S_SATURATION_EQ_SIZE 0x8
diff --git a/sound/soc/omap/abe/abe_taskid.h b/sound/soc/omap/abe/abe_taskid.h
index b72c3a5..8f91aa4 100644
--- a/sound/soc/omap/abe/abe_taskid.h
+++ b/sound/soc/omap/abe/abe_taskid.h
@@ -184,4 +184,7 @@
#define C_ABE_FW_TASK_SRC44P1_TONES 124
#define C_ABE_FW_TASK_SRC44P1_MMDL_1211 125
#define C_ABE_FW_TASK_SRC44P1_TONES_1211 126
+#define C_ABE_FW_TASK_SRC44P1_MMDL_PP 127
+#define C_ABE_FW_TASK_SRC44P1_MMDL_1211_PP 128
+#define C_ABE_FW_TASK_CHECK_IIR 129
#endif /* _ABE_TASKID_H_ */
diff --git a/sound/soc/omap/abe/abe_typedef.h b/sound/soc/omap/abe/abe_typedef.h
index 59d7221..943968e 100644
--- a/sound/soc/omap/abe/abe_typedef.h
+++ b/sound/soc/omap/abe/abe_typedef.h
@@ -215,7 +215,15 @@ struct ABE_SPingPongDescriptor {
u8 atc_irq_data;
/* 11: ping/pong buffer flag */
u8 counter;
- /* 12: current Base address of the working buffer */
+ /* 12: reseved */
+ u16 dummy1;
+ /* 14: reseved */
+ u16 dummy2;
+ /* 16 For 12/11 in case of 44.1 mode (same address as SIO desc)*/
+ u16 split_addr1;
+ /* 18: reseved */
+ u16 dummy3;
+ /* 20: current Base address of the working buffer */
u16 workbuff_BaseAddr;
/* 14: samples left in the working buffer */
u16 workbuff_Samples;
diff --git a/sound/soc/omap/omap-abe-dsp.c b/sound/soc/omap/omap-abe-dsp.c
index bb46477..fa6964c 100644
--- a/sound/soc/omap/omap-abe-dsp.c
+++ b/sound/soc/omap/omap-abe-dsp.c
@@ -61,6 +61,9 @@
#include "abe/abe_main.h"
#include "abe/port_mgr.h"
+#define OMAP_ABE_HS_DC_OFFSET_STEP (1800 / 8)
+#define OMAP_ABE_HF_DC_OFFSET_STEP (4600 / 8)
+
static const char *abe_memory_bank[5] = {
"dmem",
"cmem",
@@ -120,6 +123,14 @@ struct abe_data {
int irq;
int opp;
unsigned long opp_freqs[OMAP_ABE_OPP_COUNT];
+
+ /* DC offset cancellation */
+ int power_mode;
+ u32 dc_hsl;
+ u32 dc_hsr;
+ u32 dc_hfl;
+ u32 dc_hfr;
+
int active;
/* coefficients */
@@ -265,6 +276,48 @@ void abe_dsp_shutdown(void)
}
EXPORT_SYMBOL_GPL(abe_dsp_shutdown);
+void abe_dsp_set_hs_offset(int left, int right, int mult)
+{
+ /* TODO: do not use abe global structure */
+ if (the_abe == NULL)
+ return;
+
+ if (left >= 8)
+ left -= 16;
+ the_abe->dc_hsl = OMAP_ABE_HS_DC_OFFSET_STEP * left * mult;
+
+ if (right >= 8)
+ right -= 16;
+ the_abe->dc_hsr = OMAP_ABE_HS_DC_OFFSET_STEP * right * mult;
+}
+EXPORT_SYMBOL(abe_dsp_set_hs_offset);
+
+void abe_dsp_set_hf_offset(int left, int right)
+{
+ /* TODO: do not use abe global structure */
+ if (the_abe == NULL)
+ return;
+
+ if (left >= 8)
+ left -= 16;
+ the_abe->dc_hfl = OMAP_ABE_HF_DC_OFFSET_STEP * left;
+
+ if (right >= 8)
+ right -= 16;
+ the_abe->dc_hfr = OMAP_ABE_HF_DC_OFFSET_STEP * right;
+}
+EXPORT_SYMBOL(abe_dsp_set_hf_offset);
+
+void abe_dsp_set_power_mode(int mode)
+{
+ if (the_abe == NULL)
+ return;
+
+ /* TODO: do not use abe global structure */
+ the_abe->power_mode = mode;
+}
+EXPORT_SYMBOL(abe_dsp_set_power_mode);
+
/*
* These TLV settings will need fine tuned for each individual control
*/
@@ -623,7 +676,7 @@ static int volume_put_sdt_mixer(struct snd_kcontrol *kcontrol,
pm_runtime_get_sync(the_abe->dev);
abe_write_mixer(MIXSDT, abe_val_to_gain(ucontrol->value.integer.value[0]),
- RAMP_0MS, mc->reg);
+ RAMP_5MS, mc->reg);
pm_runtime_put_sync(the_abe->dev);
return 1;
@@ -637,7 +690,7 @@ static int volume_put_audul_mixer(struct snd_kcontrol *kcontrol,
pm_runtime_get_sync(the_abe->dev);
abe_write_mixer(MIXAUDUL, abe_val_to_gain(ucontrol->value.integer.value[0]),
- RAMP_0MS, mc->reg);
+ RAMP_5MS, mc->reg);
pm_runtime_put_sync(the_abe->dev);
return 1;
@@ -651,7 +704,7 @@ static int volume_put_vxrec_mixer(struct snd_kcontrol *kcontrol,
pm_runtime_get_sync(the_abe->dev);
abe_write_mixer(MIXVXREC, abe_val_to_gain(ucontrol->value.integer.value[0]),
- RAMP_0MS, mc->reg);
+ RAMP_5MS, mc->reg);
pm_runtime_put_sync(the_abe->dev);
return 1;
@@ -665,7 +718,7 @@ static int volume_put_dl1_mixer(struct snd_kcontrol *kcontrol,
pm_runtime_get_sync(the_abe->dev);
abe_write_mixer(MIXDL1, abe_val_to_gain(ucontrol->value.integer.value[0]),
- RAMP_0MS, mc->reg);
+ RAMP_5MS, mc->reg);
pm_runtime_put_sync(the_abe->dev);
return 1;
@@ -679,7 +732,7 @@ static int volume_put_dl2_mixer(struct snd_kcontrol *kcontrol,
pm_runtime_get_sync(the_abe->dev);
abe_write_mixer(MIXDL2, abe_val_to_gain(ucontrol->value.integer.value[0]),
- RAMP_0MS, mc->reg);
+ RAMP_5MS, mc->reg);
pm_runtime_put_sync(the_abe->dev);
return 1;
@@ -694,10 +747,10 @@ static int volume_put_gain(struct snd_kcontrol *kcontrol,
pm_runtime_get_sync(the_abe->dev);
abe_write_gain(mc->reg,
abe_val_to_gain(ucontrol->value.integer.value[0]),
- RAMP_20MS, mc->shift);
+ RAMP_5MS, mc->shift);
abe_write_gain(mc->reg,
-12000 + (ucontrol->value.integer.value[1] * 100),
- RAMP_20MS, mc->rshift);
+ RAMP_5MS, mc->rshift);
pm_runtime_put_sync(the_abe->dev);
return 1;
@@ -2093,6 +2146,14 @@ static int aess_restore_context(struct abe_data *abe)
abe_set_router_configuration(UPROUTE, 0, (u32 *)abe->router);
+ /* DC offset cancellation setting */
+ if (abe->power_mode)
+ abe_write_pdmdl_offset(1, abe->dc_hsl * 2, abe->dc_hsr * 2);
+ else
+ abe_write_pdmdl_offset(1, abe->dc_hsl, abe->dc_hsr);
+
+ abe_write_pdmdl_offset(2, abe->dc_hfl, abe->dc_hfr);
+
for (i = 0; i < abe->hdr.num_equ; i++)
abe_dsp_set_equalizer(i, abe->equ_profile[i]);
@@ -2455,6 +2516,13 @@ static int abe_resume(struct snd_soc_dai *dai)
abe_set_router_configuration(UPROUTE, 0, (u32 *)abe->router);
+ if (abe->power_mode)
+ abe_write_pdmdl_offset(1, abe->dc_hsl * 2, abe->dc_hsr * 2);
+ else
+ abe_write_pdmdl_offset(1, abe->dc_hsl, abe->dc_hsr);
+
+ abe_write_pdmdl_offset(2, abe->dc_hfl, abe->dc_hfr);
+
for (i = 0; i < abe->hdr.num_equ; i++)
abe_dsp_set_equalizer(i, abe->equ_profile[i]);
diff --git a/sound/soc/omap/omap-abe-dsp.h b/sound/soc/omap/omap-abe-dsp.h
index 5dae62a..8462290 100644
--- a/sound/soc/omap/omap-abe-dsp.h
+++ b/sound/soc/omap/omap-abe-dsp.h
@@ -170,5 +170,8 @@ void abe_dsp_pm_get(void);
void abe_dsp_pm_put(void);
int abe_add_opp_req(struct device *dev, int opp);
int abe_remove_opp_req(struct device *dev);
+void abe_dsp_set_power_mode(int mode);
+void abe_dsp_set_hs_offset(int left, int right, int mult);
+void abe_dsp_set_hf_offset(int left, int right);
#endif /* End of __OMAP_ABE_DSP_H__ */
diff --git a/sound/soc/omap/omap-abe.c b/sound/soc/omap/omap-abe.c
index 316173a..6d2fd97 100644
--- a/sound/soc/omap/omap-abe.c
+++ b/sound/soc/omap/omap-abe.c
@@ -746,24 +746,23 @@ static void playback_trigger(struct snd_pcm_substream *substream,
unmute_fe_port(substream, dai, stream);
break;
case SNDRV_PCM_TRIGGER_PAUSE_PUSH:
+ /* mute FE port */
+ mute_fe_port(substream, dai, stream);
+
/* disable Frontend sDMA */
disable_fe_port(substream, dai, stream);
snd_soc_dsp_platform_trigger(substream, cmd, fe->platform);
-
- /* mute FE port */
- mute_fe_port(substream, dai, stream);
break;
case SNDRV_PCM_TRIGGER_STOP:
/* does this trigger() apply to the FE ? */
if (snd_soc_dsp_is_trigger_for_fe(fe, stream)) {
+ /* mute FE port */
+ mute_fe_port(substream, dai, stream);
/* disable the transfer */
disable_fe_port(substream, dai, stream);
snd_soc_dsp_platform_trigger(substream, cmd, fe->platform);
-
- /* mute FE port */
- mute_fe_port(substream, dai, stream);
}
/* disable BE ports */
diff --git a/sound/soc/omap/omap-hdmi.c b/sound/soc/omap/omap-hdmi.c
new file mode 100644
index 0000000..69dd059
--- /dev/null
+++ b/sound/soc/omap/omap-hdmi.c
@@ -0,0 +1,158 @@
+/*
+ * omap-hdmi.c
+ *
+ * OMAP ALSA SoC DAI driver for HDMI audio on OMAP4 processors.
+ * Copyright (C) 2010-2011 Texas Instruments Incorporated - http://www.ti.com/
+ * Authors: Jorge Candelaria <jorge.candelaria@ti.com>
+ * Ricardo Neri <ricardo.neri@ti.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * version 2 as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA
+ *
+ */
+
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/device.h>
+#include <sound/core.h>
+#include <sound/pcm.h>
+#include <sound/pcm_params.h>
+#include <sound/initval.h>
+#include <sound/soc.h>
+
+#include <plat/dma.h>
+#include "omap-pcm.h"
+#include "omap-hdmi.h"
+
+#define DRV_NAME "hdmi-audio-dai"
+
+static struct omap_pcm_dma_data omap_hdmi_dai_dma_params = {
+ .name = "HDMI playback",
+ .sync_mode = OMAP_DMA_SYNC_PACKET,
+};
+
+static int omap_hdmi_dai_startup(struct snd_pcm_substream *substream,
+ struct snd_soc_dai *dai)
+{
+ int err;
+ /*
+ * Make sure that the period bytes are multiple of the DMA packet size.
+ * Largest packet size we use is 32 32-bit words = 128 bytes
+ */
+ err = snd_pcm_hw_constraint_step(substream->runtime, 0,
+ SNDRV_PCM_HW_PARAM_PERIOD_BYTES, 128);
+ if (err < 0)
+ return err;
+
+ return 0;
+}
+
+static int omap_hdmi_dai_hw_params(struct snd_pcm_substream *substream,
+ struct snd_pcm_hw_params *params,
+ struct snd_soc_dai *dai)
+{
+ int err = 0;
+
+ switch (params_format(params)) {
+ case SNDRV_PCM_FORMAT_S16_LE:
+ omap_hdmi_dai_dma_params.packet_size = 16;
+ break;
+ case SNDRV_PCM_FORMAT_S24_LE:
+ omap_hdmi_dai_dma_params.packet_size = 32;
+ break;
+ default:
+ err = -EINVAL;
+ }
+
+ omap_hdmi_dai_dma_params.data_type = OMAP_DMA_DATA_TYPE_S32;
+
+ snd_soc_dai_set_dma_data(dai, substream,
+ &omap_hdmi_dai_dma_params);
+
+ return err;
+}
+
+static struct snd_soc_dai_ops omap_hdmi_dai_ops = {
+ .startup = omap_hdmi_dai_startup,
+ .hw_params = omap_hdmi_dai_hw_params,
+};
+
+static struct snd_soc_dai_driver omap_hdmi_dai = {
+ .playback = {
+ .channels_min = 2,
+ .channels_max = 8,
+ .rates = OMAP_HDMI_RATES,
+ .formats = OMAP_HDMI_FORMATS,
+ },
+ .ops = &omap_hdmi_dai_ops,
+};
+
+static __devinit int omap_hdmi_probe(struct platform_device *pdev)
+{
+ int ret;
+ struct resource *hdmi_rsrc;
+
+ hdmi_rsrc = platform_get_resource(pdev, IORESOURCE_MEM, 0);
+ if (!hdmi_rsrc) {
+ dev_err(&pdev->dev, "Cannot obtain IORESOURCE_MEM HDMI\n");
+ return -EINVAL;
+ }
+
+ omap_hdmi_dai_dma_params.port_addr = hdmi_rsrc->start
+ + OMAP_HDMI_AUDIO_DMA_PORT;
+
+ hdmi_rsrc = platform_get_resource(pdev, IORESOURCE_DMA, 0);
+ if (!hdmi_rsrc) {
+ dev_err(&pdev->dev, "Cannot obtain IORESOURCE_DMA HDMI\n");
+ return -EINVAL;
+ }
+
+ omap_hdmi_dai_dma_params.dma_req = hdmi_rsrc->start;
+
+ ret = snd_soc_register_dai(&pdev->dev, &omap_hdmi_dai);
+ return ret;
+}
+
+static int __devexit omap_hdmi_remove(struct platform_device *pdev)
+{
+ snd_soc_unregister_dai(&pdev->dev);
+ return 0;
+}
+
+static struct platform_driver hdmi_dai_driver = {
+ .driver = {
+ .name = DRV_NAME,
+ .owner = THIS_MODULE,
+ },
+ .probe = omap_hdmi_probe,
+ .remove = __devexit_p(omap_hdmi_remove),
+};
+
+static int __init hdmi_dai_init(void)
+{
+ return platform_driver_register(&hdmi_dai_driver);
+}
+module_init(hdmi_dai_init);
+
+static void __exit hdmi_dai_exit(void)
+{
+ platform_driver_unregister(&hdmi_dai_driver);
+}
+module_exit(hdmi_dai_exit);
+
+MODULE_AUTHOR("Jorge Candelaria <jorge.candelaria@ti.com>");
+MODULE_AUTHOR("Ricardo Neri <ricardo.neri@ti.com>");
+MODULE_DESCRIPTION("OMAP HDMI SoC Interface");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:" DRV_NAME);
diff --git a/sound/soc/omap/omap-hdmi.h b/sound/soc/omap/omap-hdmi.h
new file mode 100644
index 0000000..34c298d
--- /dev/null
+++ b/sound/soc/omap/omap-hdmi.h
@@ -0,0 +1,36 @@
+/*
+ * omap-hdmi.h
+ *
+ * Definitions for OMAP ALSA SoC DAI driver for HDMI audio on OMAP4 processors.
+ * Copyright (C) 2010-2011 Texas Instruments Incorporated - http://www.ti.com/
+ * Authors: Jorge Candelaria <jorge.candelaria@ti.com>
+ * Ricardo Neri <ricardo.neri@ti.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * version 2 as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA
+ *
+ */
+
+#ifndef __OMAP_HDMI_H__
+#define __OMAP_HDMI_H__
+
+#define OMAP_HDMI_AUDIO_DMA_PORT 0x8c
+
+#define OMAP_HDMI_RATES (SNDRV_PCM_RATE_32000 | \
+ SNDRV_PCM_RATE_44100 | SNDRV_PCM_RATE_48000)
+
+#define OMAP_HDMI_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | \
+ SNDRV_PCM_FMTBIT_S24_LE)
+
+#endif
diff --git a/sound/soc/omap/omap4-hdmi-card.c b/sound/soc/omap/omap4-hdmi-card.c
new file mode 100644
index 0000000..86c4832
--- /dev/null
+++ b/sound/soc/omap/omap4-hdmi-card.c
@@ -0,0 +1,129 @@
+/*
+ * omap4-hdmi-card.c
+ *
+ * OMAP ALSA SoC machine driver for TI OMAP4 HDMI
+ * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
+ * Author: Ricardo Neri <ricardo.neri@ti.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * version 2 as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA
+ *
+ */
+
+#include <sound/pcm.h>
+#include <sound/soc.h>
+#include <asm/mach-types.h>
+#include <video/omapdss.h>
+
+#define DRV_NAME "omap4-hdmi-audio"
+
+static int omap4_hdmi_dai_hw_params(struct snd_pcm_substream *substream,
+ struct snd_pcm_hw_params *params)
+{
+ int i;
+ struct omap_overlay_manager *mgr = NULL;
+ struct device *dev = substream->pcm->card->dev;
+
+ /* Find DSS HDMI device */
+ for (i = 0; i < omap_dss_get_num_overlay_managers(); i++) {
+ mgr = omap_dss_get_overlay_manager(i);
+ if (mgr && mgr->device
+ && mgr->device->type == OMAP_DISPLAY_TYPE_HDMI)
+ break;
+ }
+
+ if (i == omap_dss_get_num_overlay_managers()) {
+ dev_err(dev, "HDMI display device not found!\n");
+ return -ENODEV;
+ }
+
+ /* Make sure HDMI is power-on to avoid L3 interconnect errors */
+ if (mgr->device->state != OMAP_DSS_DISPLAY_ACTIVE) {
+ dev_err(dev, "HDMI display is not active!\n");
+ return -EIO;
+ }
+
+ return 0;
+}
+
+static struct snd_soc_ops omap4_hdmi_dai_ops = {
+ .hw_params = omap4_hdmi_dai_hw_params,
+};
+
+static struct snd_soc_dai_link omap4_hdmi_dai = {
+ .name = "HDMI",
+ .stream_name = "HDMI",
+ .cpu_dai_name = "hdmi-audio-dai",
+ .platform_name = "omap-pcm-audio",
+ .codec_name = "omap-hdmi-codec",
+ .codec_dai_name = "hdmi-audio-codec",
+ .ops = &omap4_hdmi_dai_ops,
+};
+
+static struct snd_soc_card snd_soc_omap4_hdmi = {
+ .name = "OMAP4HDMI",
+ .dai_link = &omap4_hdmi_dai,
+ .num_links = 1,
+};
+
+static __devinit int omap4_hdmi_probe(struct platform_device *pdev)
+{
+ struct snd_soc_card *card = &snd_soc_omap4_hdmi;
+ int ret;
+
+ card->dev = &pdev->dev;
+
+ ret = snd_soc_register_card(card);
+ if (ret) {
+ dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);
+ card->dev = NULL;
+ return ret;
+ }
+ return 0;
+}
+
+static int __devexit omap4_hdmi_remove(struct platform_device *pdev)
+{
+ struct snd_soc_card *card = platform_get_drvdata(pdev);
+
+ snd_soc_unregister_card(card);
+ card->dev = NULL;
+ return 0;
+}
+
+static struct platform_driver omap4_hdmi_driver = {
+ .driver = {
+ .name = "omap4-hdmi-audio",
+ .owner = THIS_MODULE,
+ },
+ .probe = omap4_hdmi_probe,
+ .remove = __devexit_p(omap4_hdmi_remove),
+};
+
+static int __init omap4_hdmi_init(void)
+{
+ return platform_driver_register(&omap4_hdmi_driver);
+}
+module_init(omap4_hdmi_init);
+
+static void __exit omap4_hdmi_exit(void)
+{
+ platform_driver_unregister(&omap4_hdmi_driver);
+}
+module_exit(omap4_hdmi_exit);
+
+MODULE_AUTHOR("Ricardo Neri <ricardo.neri@ti.com>");
+MODULE_DESCRIPTION("OMAP4 HDMI machine ASoC driver");
+MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:" DRV_NAME);
diff --git a/sound/soc/omap/sdp4430.c b/sound/soc/omap/sdp4430.c
index 5079f1e..30ff72b 100644..100755
--- a/sound/soc/omap/sdp4430.c
+++ b/sound/soc/omap/sdp4430.c
@@ -37,6 +37,7 @@
#include "omap-mcpdm.h"
#include "omap-abe.h"
+#include "omap-abe-dsp.h"
#include "omap-pcm.h"
#include "omap-mcbsp.h"
#include "../codecs/twl6040.h"
@@ -247,6 +248,7 @@ static int sdp4430_set_power_mode(struct snd_kcontrol *kcontrol,
return 0;
twl6040_power_mode = ucontrol->value.integer.value[0];
+ abe_dsp_set_power_mode(twl6040_power_mode);
return 1;
}
@@ -321,8 +323,10 @@ static void sdp4430_mcpdm_twl6040_post(struct snd_pcm_substream *substream)
static int sdp4430_twl6040_init(struct snd_soc_pcm_runtime *rtd)
{
struct snd_soc_codec *codec = rtd->codec;
+ struct twl6040 *twl6040 = codec->control_data;
struct snd_soc_dapm_context *dapm = &codec->dapm;
- int ret;
+ int hsotrim, left_offset, right_offset, mode, ret;
+
/* Add SDP4430 specific controls */
ret = snd_soc_add_controls(codec, sdp4430_controls,
@@ -373,6 +377,20 @@ static int sdp4430_twl6040_init(struct snd_soc_pcm_runtime *rtd)
else
snd_soc_jack_report(&hs_jack, SND_JACK_HEADSET, SND_JACK_HEADSET);
+ /* DC offset cancellation computation */
+ hsotrim = snd_soc_read(codec, TWL6040_REG_HSOTRIM);
+ right_offset = (hsotrim & TWL6040_HSRO) >> TWL6040_HSRO_OFFSET;
+ left_offset = hsotrim & TWL6040_HSLO;
+
+ if (twl6040_get_icrev(twl6040) < TWL6040_REV_1_3)
+ /* For ES under ES_1.3 HS step is 2 mV */
+ mode = 2;
+ else
+ /* For ES_1.3 HS step is 1 mV */
+ mode = 1;
+
+ abe_dsp_set_hs_offset(left_offset, right_offset, mode);
+
/* don't wait before switching of HS power */
rtd->pmdown_time = 0;
@@ -381,6 +399,16 @@ static int sdp4430_twl6040_init(struct snd_soc_pcm_runtime *rtd)
static int sdp4430_twl6040_dl2_init(struct snd_soc_pcm_runtime *rtd)
{
+ struct snd_soc_codec *codec = rtd->codec;
+ int hfotrim, left_offset, right_offset;
+
+ /* DC offset cancellation computation */
+ hfotrim = snd_soc_read(codec, TWL6040_REG_HFOTRIM);
+ right_offset = (hfotrim & TWL6040_HFRO) >> TWL6040_HFRO_OFFSET;
+ left_offset = hfotrim & TWL6040_HFLO;
+
+ abe_dsp_set_hf_offset(left_offset, right_offset);
+
/* don't wait before switching of HF power */
rtd->pmdown_time = 0;