aboutsummaryrefslogtreecommitdiffstats
path: root/sound/soc/intel/common/sst-firmware.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2015-12-23 02:33:52 -0500
committerTakashi Iwai <tiwai@suse.de>2015-12-23 02:33:52 -0500
commitf80e39e0225c01ee68764ef7594c3a29ab5ebabb (patch)
treef5a85085741a173c93fc8f21938528b65ed95e42 /sound/soc/intel/common/sst-firmware.c
parent59c8231089be96165735585694a801ae58ec6c95 (diff)
parent822ad70a2f5c420da5baa9f4354e6b7813ca6da9 (diff)
Merge tag 'asoc-v4.5' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: Updates for v4.5 This is quite a busy release on the driver front with a lot of new drivers being added but comparatively quiet on the core side with only one big change going in and that a fairly straightforward refactoring. - Conversion of the array of DAI links to a list by Mengdong Lin, supporting dynamically adding and removing DAI links. - Some more fixes for the topology code, though it is still not final and ready for enabling in production. We really need to get to the point where that can be done. - A pile of changes for Intel SkyLake drivers which hopefully deliver some useful initial functionality for systems with this chipset, though there is more work still to come. - New drivers for a number of Imagination Technologies IPs. - Lots of new features and cleanups for the Renesas drivers. - ANC support for WM5110. - New driver for Atmel class D speaker drivers. - New drivers for Cirrus CS47L24 and WM1831. - New driver for Dialog DA7128. - New drivers for Realtek RT5659 and RT56156. - New driver for Rockchip RK3036. - New driver for TI PC3168A
Diffstat (limited to 'sound/soc/intel/common/sst-firmware.c')
-rw-r--r--sound/soc/intel/common/sst-firmware.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/sound/soc/intel/common/sst-firmware.c b/sound/soc/intel/common/sst-firmware.c
index 1636a1eeb002..ef4881e7753a 100644
--- a/sound/soc/intel/common/sst-firmware.c
+++ b/sound/soc/intel/common/sst-firmware.c
@@ -51,8 +51,22 @@ struct sst_dma {
51 51
52static inline void sst_memcpy32(volatile void __iomem *dest, void *src, u32 bytes) 52static inline void sst_memcpy32(volatile void __iomem *dest, void *src, u32 bytes)
53{ 53{
54 u32 tmp = 0;
55 int i, m, n;
56 const u8 *src_byte = src;
57
58 m = bytes / 4;
59 n = bytes % 4;
60
54 /* __iowrite32_copy use 32bit size values so divide by 4 */ 61 /* __iowrite32_copy use 32bit size values so divide by 4 */
55 __iowrite32_copy((void *)dest, src, bytes/4); 62 __iowrite32_copy((void *)dest, src, m);
63
64 if (n) {
65 for (i = 0; i < n; i++)
66 tmp |= (u32)*(src_byte + m * 4 + i) << (i * 8);
67 __iowrite32_copy((void *)(dest + m * 4), &tmp, 1);
68 }
69
56} 70}
57 71
58static void sst_dma_transfer_complete(void *arg) 72static void sst_dma_transfer_complete(void *arg)
@@ -1014,8 +1028,8 @@ EXPORT_SYMBOL_GPL(sst_module_runtime_restore);
1014 1028
1015/* register a DSP memory block for use with FW based modules */ 1029/* register a DSP memory block for use with FW based modules */
1016struct sst_mem_block *sst_mem_block_register(struct sst_dsp *dsp, u32 offset, 1030struct sst_mem_block *sst_mem_block_register(struct sst_dsp *dsp, u32 offset,
1017 u32 size, enum sst_mem_type type, struct sst_block_ops *ops, u32 index, 1031 u32 size, enum sst_mem_type type, const struct sst_block_ops *ops,
1018 void *private) 1032 u32 index, void *private)
1019{ 1033{
1020 struct sst_mem_block *block; 1034 struct sst_mem_block *block;
1021 1035