From 163d2089d226ab184469f53561f1a63f151757c3 Mon Sep 17 00:00:00 2001 From: Vinod Koul Date: Thu, 16 Oct 2014 20:00:13 +0530 Subject: ASoC: Intel: mrfld - add the dsp sst driver The SST driver is the missing piece in our driver stack not upstreamed, so push it now :) This driver currently supports PCI device on Merrifield. Future updates will bring support for ACPI device as well as future update to PCI devices as well In subsequent patches support is added for DSP loading using memcpy, pcm operations and compressed ops. Signed-off-by: Subhransu S. Prusty Signed-off-by: Vinod Koul Signed-off-by: Mark Brown --- arch/x86/include/asm/platform_sst_audio.h | 34 +++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) (limited to 'arch/x86') diff --git a/arch/x86/include/asm/platform_sst_audio.h b/arch/x86/include/asm/platform_sst_audio.h index 0a4e140..268a96ae 100644 --- a/arch/x86/include/asm/platform_sst_audio.h +++ b/arch/x86/include/asm/platform_sst_audio.h @@ -16,6 +16,9 @@ #include +#define MAX_NUM_STREAMS_MRFLD 25 +#define MAX_NUM_STREAMS MAX_NUM_STREAMS_MRFLD + enum sst_audio_task_id_mrfld { SST_TASK_ID_NONE = 0, SST_TASK_ID_SBA = 1, @@ -73,6 +76,37 @@ struct sst_platform_data { unsigned int strm_map_size; }; +struct sst_info { + u32 iram_start; + u32 iram_end; + bool iram_use; + u32 dram_start; + u32 dram_end; + bool dram_use; + u32 imr_start; + u32 imr_end; + bool imr_use; + u32 mailbox_start; + bool use_elf; + bool lpe_viewpt_rqd; + unsigned int max_streams; + u32 dma_max_len; + u8 num_probes; +}; + +struct sst_lib_dnld_info { + unsigned int mod_base; + unsigned int mod_end; + unsigned int mod_table_offset; + unsigned int mod_table_size; + bool mod_ddr_dnld; +}; + +struct sst_platform_info { + const struct sst_info *probe_data; + const struct sst_ipc_info *ipc_info; + const struct sst_lib_dnld_info *lib_info; +}; int add_sst_platform_device(void); #endif -- cgit v1.1 From 43c5e23197a187a6f4dade97f3bd23e35636ab1f Mon Sep 17 00:00:00 2001 From: "Subhransu S. Prusty" Date: Fri, 24 Oct 2014 13:49:47 +0530 Subject: ASoC: Intel: mrfld - Define ipc_info structure This will be used to abstract the differances in ipc offsets for different chips. Signed-off-by: Subhransu S. Prusty Signed-off-by: Vinod Koul Signed-off-by: Mark Brown --- arch/x86/include/asm/platform_sst_audio.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'arch/x86') diff --git a/arch/x86/include/asm/platform_sst_audio.h b/arch/x86/include/asm/platform_sst_audio.h index 268a96ae..6021dee 100644 --- a/arch/x86/include/asm/platform_sst_audio.h +++ b/arch/x86/include/asm/platform_sst_audio.h @@ -102,6 +102,11 @@ struct sst_lib_dnld_info { bool mod_ddr_dnld; }; +struct sst_ipc_info { + int ipc_offset; + unsigned int mbox_recv_off; +}; + struct sst_platform_info { const struct sst_info *probe_data; const struct sst_ipc_info *ipc_info; -- cgit v1.1 From 9a80e8f597f3bde0e1d4a4abb021d475520005a5 Mon Sep 17 00:00:00 2001 From: "Subhransu S. Prusty" Date: Fri, 24 Oct 2014 13:49:48 +0530 Subject: ASoC: Intel: mrfld: Define sst_res_info for acpi To query resources in ACPI systems we need to define a data structure. This would be set as platform_info for the devices. Signed-off-by: Subhransu S. Prusty Signed-off-by: Vinod Koul Signed-off-by: Mark Brown --- arch/x86/include/asm/platform_sst_audio.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'arch/x86') diff --git a/arch/x86/include/asm/platform_sst_audio.h b/arch/x86/include/asm/platform_sst_audio.h index 6021dee..7249e6d 100644 --- a/arch/x86/include/asm/platform_sst_audio.h +++ b/arch/x86/include/asm/platform_sst_audio.h @@ -102,6 +102,27 @@ struct sst_lib_dnld_info { bool mod_ddr_dnld; }; +struct sst_res_info { + unsigned int shim_offset; + unsigned int shim_size; + unsigned int shim_phy_addr; + unsigned int ssp0_offset; + unsigned int ssp0_size; + unsigned int dma0_offset; + unsigned int dma0_size; + unsigned int dma1_offset; + unsigned int dma1_size; + unsigned int iram_offset; + unsigned int iram_size; + unsigned int dram_offset; + unsigned int dram_size; + unsigned int mbox_offset; + unsigned int mbox_size; + unsigned int acpi_lpe_res_index; + unsigned int acpi_ddr_index; + unsigned int acpi_ipc_irq_index; +}; + struct sst_ipc_info { int ipc_offset; unsigned int mbox_recv_off; @@ -110,7 +131,9 @@ struct sst_ipc_info { struct sst_platform_info { const struct sst_info *probe_data; const struct sst_ipc_info *ipc_info; + const struct sst_res_info *res_info; const struct sst_lib_dnld_info *lib_info; + const char *platform; }; int add_sst_platform_device(void); #endif -- cgit v1.1