aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMisael Lopez Cruz <misael.lopez@ti.com>2011-06-10 13:12:51 -0500
committerSimon Wilson <simonwilson@google.com>2011-06-24 11:37:07 -0700
commitcd9a43ddfc4c6bca3f0b8e556b1caf64cbbe8da0 (patch)
treefaf02cfdcc2c1ce3ae44b127ec237b9da88bc886
parenta4efc1ed3c597f92a89263ab8f2d3d0811f5a69e (diff)
downloadkernel_samsung_tuna-cd9a43ddfc4c6bca3f0b8e556b1caf64cbbe8da0.zip
kernel_samsung_tuna-cd9a43ddfc4c6bca3f0b8e556b1caf64cbbe8da0.tar.gz
kernel_samsung_tuna-cd9a43ddfc4c6bca3f0b8e556b1caf64cbbe8da0.tar.bz2
ASoC: ABE HAL: Fix CMEM address for write_gain
Fix CMEM offset used for omap_abe_write_gain(), the address must be aligned to 32-bits. Signed-off-by: Misael Lopez Cruz <misael.lopez@ti.com>
-rw-r--r--sound/soc/omap/abe/abe_gain.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/omap/abe/abe_gain.c b/sound/soc/omap/abe/abe_gain.c
index a3d2b07..a31894d 100644
--- a/sound/soc/omap/abe/abe_gain.c
+++ b/sound/soc/omap/abe/abe_gain.c
@@ -645,14 +645,14 @@ int omap_abe_write_gain(struct omap_abe *abe,
/* CMEM bytes address */
mixer_target = OMAP_ABE_C_1_ALPHA_ADDR;
/* a pair of gains is updated once in the firmware */
- mixer_target += (p + mixer_offset) << 1;
+ mixer_target += ((p + mixer_offset) >> 1) << 2;
/* load the ramp delay data */
omap_abe_mem_write(abe, OMAP_ABE_CMEM, mixer_target,
(u32 *) &alpha, sizeof(alpha));
/* CMEM bytes address */
mixer_target = OMAP_ABE_C_ALPHA_ADDR;
/* a pair of gains is updated once in the firmware */
- mixer_target += (p + mixer_offset) << 1;
+ mixer_target += ((p + mixer_offset) >> 1) << 2;
omap_abe_mem_write(abe, OMAP_ABE_CMEM, mixer_target,
(u32 *) &beta, sizeof(beta));
return 0;