Commit Graph

474 Commits

Author SHA1 Message Date
Liam Girdwood b0f8e5d5c2 dma: dw-dma: use 32 bit words for non peripheral copies.
DW-DMA is more optimal using 32bit data size when transferring between
memories. Set configuration to always use 32 bit mode for non peripheral
copies from memory to memory.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-09 12:29:08 +00:00
Keyon Jie 1532dfdad4 apl-ssp: use external clock for APL at the moment
We only enable external Audio Cardinal 24.576MHz clock for SSP
at the moment.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-09 12:23:35 +00:00
Rander Wang 1edc69c7c0 dma: dw-dma: refine GPDMA on CNL
All GPDMA share the same irq on cannonlake, this is different with
appololake.The change is:probe GPDMA array when initilized, set the
array to the irq function; check the interrupt status of GPDMA array
in irq function, process the correct GPDMA that produces interrupt.

Signed-off-by: Rander Wang <rander.wang@intel.com>
2018-02-09 08:49:07 +00:00
Rander Wang 019637ab25 ipc: return msg to empty list
DSP and host communicate each other with msg. It would
exhausted without return and make ipc failed
2018-02-08 20:23:47 +00:00
Liam Girdwood b6ab4a18e7 platform: apl: update dma platform data to use HDA driver
Add the HDA driver to the DMA platform data and clean up alignment.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 17:00:37 +00:00
Keyon Jie c610c64299 dma: hda dma: Add HDA host and link DMA driver
Add a host and link DMA driver for Intel HDA DMA gateway.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-08 17:00:37 +00:00
Keyon Jie 616f1e57ef dw-dma: enable DW_USE_HW_LLI mode for APL/CNL.
Fix the dma not stop issue for using Hardware Link List mode.
Only enable it for APL/CNL at the moment.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-08 17:00:36 +00:00
Liam Girdwood 3600a8eab6 audio: host: Add host GW DMA support to host component.
Host GW DMA has no callback so host component has to manually notify
DMA driver when to copy each period.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-08 17:00:36 +00:00
Liam Girdwood e9027fb0ad core: dma: add return value to DMA set callback.
Let clients know if they can expect a callback from DMA.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-08 16:45:58 +00:00
Liam Girdwood 8ae350fc4a core: dma: add requested channel to dma_channel_get()
Allow clients to request a particular DMA channel if supported by the DMA
driver and it's available. If requested channel is not supported by DMAC
then return another channel. If requested channel is not free then we
return an error.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-08 16:45:43 +00:00
Liam Girdwood 9a8a9ab82b core: dma: Add channel size to DMA platform data
Some DMACs have an array of register elements to config and control
DMA channels. Provide a mapping here so that FW can easily calculate
the correct channel offset.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 16:45:43 +00:00
Liam Girdwood fa8abe145c core: dma: Add DMA copy API.
This API allows clients to manually inform the DMAC when they need more
data copied. The DMAC can then copy the desired amount of data.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 16:45:43 +00:00
Liam Girdwood 378de84293 gitignore: ignore *.lo files
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 16:41:21 +00:00
Rander Wang 4502765ebe ssp: add ssp support for APL and CNL
Now it supports I2S & TDM4 master mode and no MN devide used.
For 19.2M clock, 16bit 48K stream maybe need to pack to 20bit
48K.
2018-02-08 16:41:21 +00:00
Liam Girdwood ecdc89dac9 scripts: move build-all scripts into scripts directory.
Split into architecture specific files.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 16:25:58 +00:00
Liam Girdwood 73d24a5228 gitignore: ignore *.la files
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 15:35:51 +00:00
Liam Girdwood 768acbb9b7 m4: add ax_check_compile_flag to local m4 directory.
ax_check_comile_flag is not widely available so package it locally.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-02-08 15:35:43 +00:00
Pan Xiuli 5e60d064db dai: configure its frame_fmt from topology
For dai component, it's frame_fmt may be different with host,
we usually configure it from topology, here fix it.

Contributor: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Pan Xiuli <xiuli.pan@linux.intel.com>
2018-02-06 16:35:45 +00:00
Seppo Ingalsuo 359af81a8a Audio format: Bug fix for erroneous fractional multiplication macro
Due to misplaced parentheses the computation gives half of correct
result and omits rounding. Currently this macro is not used by code
in SOF git repository. Developers who may use format.h macros should
check their code.

Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
2018-02-06 16:10:10 +00:00
Keyon Jie dde493c45b dw-dma: fix hardware link list mode
For hardware link list mode, we also need to configure address
and config registers for the first link list, here fix it.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-06 15:06:23 +00:00
Keyon Jie eea19e6578 dw-dma: add support for interrupt per channel
On Apollolake, the interrupt number for different channels of
the same controller are different, here add implementation of
it: register interrupt handler for each channel, and don't
need check channel in its specific handler anymore.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-02-06 15:06:12 +00:00
Ranjani Sridharan 0505823b96 build: add library build support for host platform
This patch provides library build support for host platform architecture.
It enables creating separate libraries for each SOF audio component.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
2018-01-27 16:56:10 +00:00
Pierre-Louis Bossart f7beb51118 sof: add git pre- and post-commit hooks
Use Linux checkpatch.pl to check for style problems on each commit
rather than waste time on mailing lists.

The hooks are installed by default with autogen.sh if there are
no pre-existing hooks, e.g. if a global template is used.

Commits can still be forced by using git commit -n (or --no-verify) if
you absolutely need to bypass checkpatch.pl in a work branch.

Note that both checkpatch.pl and spelling.txt are provided under
a GPL v2 license.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
2018-01-23 21:08:05 +00:00
Liam Girdwood 17c6bcf850 build: add build support for cannonlake
Build the Intel Cannonklake platform.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:19:59 +00:00
Rander Wang 0d09139b05 ipc: cnl: Add support for IPC on cannonlake
Support IPC on Intel Cannonlake platform.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:19:59 +00:00
Rander Wang 44c7093525 arch: xtensa: Add bootloader support
Add a support for a secondary boot loader than cant be used to bootstrap
multiple firmware modules.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:19:59 +00:00
Rander Wang aa85e2c0e9 platform: Add platform drivers for cannonlake
Add platform initialisation and drivers for Intel Cannonlake platform.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:15:51 +00:00
Rander Wang 0624f66f5f platform: cnl: Add cannonlake platform headers
Add platform headers for Intel Cannonlake platform.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:15:51 +00:00
Rander Wang 07d38c563a platform: cnl: Add xtensa headers for cannonlake
Add xtensa headers for Intel Cannonlake platform

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood e4f3b643f4 arch: xtensa: Add support for apollolake
Apollolake has reset vector in ROM and some other changes that need
configured after reset.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 095c907a3f build: add build support for apollolake
Build the Intel apollolake platform.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Keyon Jie 4239d894ec ipc: apl: Add support for IPC on apollolake
Support IPC on Intel Apollolake platform.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-01-23 16:15:51 +00:00
Keyon Jie 05df022020 platform: apl: Add platform drivers for apollolake.
Add platform initialisation and drivers for Intel Apollolake platform.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-01-23 16:15:51 +00:00
Keyon Jie 59b5e8b576 platform: apl: Add apollolake platform headers.
Add platform headers for Intel Apollolake platform.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 88456f3607 platform: apl: Add xtensa headers for apollolake
Add the xtensa ISA headers for Intel Apollolake platform.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood d721347ad9 gitignore: ignore boot loaders and binaries.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Rander Wang 9b34b4dcf1 trace: add bootloader trace point values used by bootloader
Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 2104ff80d4 trace: add gaps in macros for new items
Add gaps in the platform init tarce macros to allow other items to be
inserted.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Rander Wang a86d2d7ae2 io: Add support for 16bit register IO
Enable IO with 16 bit HW.

Signed-off-by: Rander Wang <rander.wang@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 2b5507232e drv: dw-dma: Add support for apollolake and cannonlake platforms.
Apollolake and Cannonlake have some register differences in DW-DMA HW.
Add macros to support those differences.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 5481482557 build: xtensa: fix build link order for all platforms.
Some platforms had unresolved symbols when platform was linked before
core. Fix that.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 4814b98146 uapi: manifest: Add UAPI for Intel firmware manifest
Add uapi header for Intel manifest based firmware file format.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood cc9fba353e build: configure: make sure we can include C headers in assembly
Set ASSEMBLY when we are building .S files so that C headers can
be included.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 9053e0455f ipc: trace: dma_trace cant use page tables on APL/CNL
Page tables are not used by DMA trace on CNL and APL. Make sure they
are not built in.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 46f1220ddc arch: xtensa: Support wait_for_interrupt on LX6
Add LX6 version of wait_for_interrupt() as this will be needed for
cannonlake.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Keyon Jie cfdfb8129f core: irq: Add support for nested interrupts.
Allow interrupts to have a parent and child relationship in order to
support nested interrupts between different HW interrupt controllers.

This patch allows child handler to be registered for secondary interrupt
controllers and allow multiple child interrupt sources to share a single
interrupt pin.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood efff610a50 hsw: don't include pmc header.
Not used on Haswell or Broadwell.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood 42460843ad platform: byt: move DW-DMA specific headers into DMA driver.
Lets keep all the DW-DMA register/bits in one place.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-23 16:15:51 +00:00
Liam Girdwood f198ad907c platform: hsw: Add build support for haswell and broadwell
Add build support Makefiles

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-22 12:25:12 +00:00
Liam Girdwood b5d3e7748d ipc: hsw: Add IPC support for haswell and broadwell
Add IPC support for Haswell and Broadwell platforms.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
2018-01-22 12:25:12 +00:00