Sound-open-firmware
Threads by month
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
January 2018
- 15 participants
- 44 discussions
[Sound-open-firmware] [PATCH 1/2] ipc: add missing braces for multi-line macro in block
by Pierre-Louis Bossart 19 Jan '18
by Pierre-Louis Bossart 19 Jan '18
19 Jan '18
Detected with Coverity and fix with braces.
Details:
Code that is meant to be executed conditionally may be executed
unconditionally
In do_notify: The indentation of this code suggests it is nested when
it is not. (CWE-483)
multi_stmt_macro: The macro on this line expands into multiple
statements, only the first of which is nested within the preceding
parent while the rest are not.
http://cwe.mitre.org/data/definitions/483.html
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart(a)linux.intel.com>
---
src/ipc/byt-ipc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/ipc/byt-ipc.c b/src/ipc/byt-ipc.c
index 8897bb9..b5da4b6 100644
--- a/src/ipc/byt-ipc.c
+++ b/src/ipc/byt-ipc.c
@@ -67,8 +67,9 @@ static void do_notify(void)
goto out;
/* copy the data returned from DSP */
- if (msg->rx_size && msg->rx_size < SOF_IPC_MSG_MAX_SIZE)
+ if (msg->rx_size && msg->rx_size < SOF_IPC_MSG_MAX_SIZE) {
mailbox_dspbox_read(msg->rx_data, 0, msg->rx_size);
+ }
/* any callback ? */
if (msg->cb)
--
2.14.1
4
4
We don't need set host buffer size in each sg_elem, instead,
we can set it only one time, here set it in params().
Signed-off-by: Keyon Jie <yang.jie(a)linux.intel.com>
---
Sanity test passed on minnow turbot with rt5651.
SOF #master: commit 83fec1559716d5a06137b43848abc18c244bc9e6
SOF Tool #master: commit a6bb8de907acd642302a227f403bb9fb2c18d075
Kernel: git@github.com:plbossart/sound.git #topic/sof-v4.14:
commit 772ab0da7a8298d08edd42ab9a4f4177ec37aec6
src/audio/host.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/audio/host.c b/src/audio/host.c
index 0a047b3..bdf947c 100644
--- a/src/audio/host.c
+++ b/src/audio/host.c
@@ -390,6 +390,7 @@ static int host_params(struct comp_dev *dev)
trace_host("par");
/* host params always installed by pipeline IPC */
+ hd->host_size = dev->params.buffer.size;
/* determine source and sink buffer elems */
if (dev->params.direction == SOF_IPC_STREAM_PLAYBACK) {
@@ -559,7 +560,6 @@ static int host_buffer(struct comp_dev *dev, struct dma_sg_elem *elem,
return -ENOMEM;
*e = *elem;
- hd->host_size = host_size;
list_item_append(&e->list, &hd->host.elem_list);
return 0;
--
2.11.0
2
2
[Sound-open-firmware] [PATCH] trace: don't copy uninitialized field from dma_sw_elem parameter
by Pierre-Louis Bossart 18 Jan '18
by Pierre-Louis Bossart 18 Jan '18
18 Jan '18
Coverity issue: 254842 Uninitialized scalar variable
The variable will contain an arbitrary value left from earlier
computations.
In parse_page_descriptors: Use of an uninitialized variable (CWE-457)
The elem.src variable is not initialized, but in
dma_trace_host_buffer() the code reads this initialized value.
Break
*e = *elem;
in
e->dest = elem->dest;
e->size = elem->size;
to only access relevant fields.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart(a)linux.intel.com>
---
src/lib/dma-trace.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/lib/dma-trace.c b/src/lib/dma-trace.c
index 7569d5d..429c7b6 100644
--- a/src/lib/dma-trace.c
+++ b/src/lib/dma-trace.c
@@ -185,7 +185,10 @@ int dma_trace_host_buffer(struct dma_trace_data *d, struct dma_sg_elem *elem,
if (e == NULL)
return -ENOMEM;
- *e = *elem;
+ /* copy fields - excluding possibly non-initialized elem->src */
+ e->dest = elem->dest;
+ e->size = elem->size;
+
d->host_size = host_size;
list_item_append(&e->list, &d->config.elem_list);
--
2.14.1
1
0
17 Jan '18
We don't need to report xrun every time it can't do real
copy(buffer avail/free not enough), e.g. we actually don't
need copy if sink buffer is full, we should do empty copy
and return success to let pipeline schedule continue.
The xrun will be checked in scheduling component (usually
is dai) only and reported there.
Todo: remove xrun check in other components also, e.g.
mixer, src, etc.
Signed-off-by: Keyon Jie <yang.jie(a)linux.intel.com>
---
Sanity test passed on minnow turbot with rt5651.
SOF #master: commit 83fec1559716d5a06137b43848abc18c244bc9e6
SOF Tool #master: commit a6bb8de907acd642302a227f403bb9fb2c18d075
Kernel: git@github.com:plbossart/sound.git #topic/sof-v4.14:
commit 772ab0da7a8298d08edd42ab9a4f4177ec37aec6
src/audio/host.c | 6 +++---
src/audio/volume.c | 12 ++++++------
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/src/audio/host.c b/src/audio/host.c
index 7cba6df..0a047b3 100644
--- a/src/audio/host.c
+++ b/src/audio/host.c
@@ -622,9 +622,9 @@ static int host_copy(struct comp_dev *dev)
if (dma_buffer->free < local_elem->size) {
/* make sure there is free bytes for next period */
- trace_host_error("xro");
- comp_overrun(dev, dma_buffer, local_elem->size, 0);
- return -EIO;
+ /* dont be too nervous, just warning and return */
+ trace_host("xo?");
+ return 0;
}
} else {
diff --git a/src/audio/volume.c b/src/audio/volume.c
index 05459b8..9ea3c92 100644
--- a/src/audio/volume.c
+++ b/src/audio/volume.c
@@ -577,14 +577,14 @@ static int volume_copy(struct comp_dev *dev)
* the sink component buffer has enough free bytes for copy. Also
* check for XRUNs */
if (source->avail < cd->source_period_bytes) {
- trace_volume_error("xru");
- comp_underrun(dev, source, cd->source_period_bytes, 0);
- return -EIO; /* xrun */
+ /* dont be too nervous, just warning if can't copy this time */
+ trace_volume("xu?");
+ return 0; /* don't break the pipeline */
}
if (sink->free < cd->sink_period_bytes) {
- trace_volume_error("xro");
- comp_overrun(dev, sink, cd->sink_period_bytes, 0);
- return -EIO; /* xrun */
+ /* dont be too nervous, just warning if can't copy this time */
+ trace_volume_error("xo?");
+ return 0; /* don't break the pipeline */
}
/* copy and scale volume */
--
2.11.0
3
5
[Sound-open-firmware] [PATCH v2 1/2] build: add library build support for host platform
by Ranjani Sridharan 17 Jan '18
by Ranjani Sridharan 17 Jan '18
17 Jan '18
This patch provides library build support for host platform architecture.
q!It enables creating separate libraries for each SOF audio component.
Signed-off-by: Ranjani Sridharan <ranjani.sridharan(a)linux.intel.com>
---
Makefile.am | 16 +
README | 7 +
build-all.sh | 5 +
configure.ac | 103 ++-
src/Makefile.am | 11 +-
src/arch/Makefile.am | 4 +
src/arch/host/Makefile.am | 1 +
src/arch/host/include/Makefile.am | 1 +
src/arch/host/include/arch/Makefile.am | 8 +
src/arch/host/include/arch/cache.h | 43 ++
src/arch/host/include/arch/interrupt.h | 54 ++
src/arch/host/include/arch/reef.h | 41 ++
src/arch/host/include/arch/spinlock.h | 46 ++
src/arch/host/include/arch/timer.h | 52 ++
src/audio/Makefile.am | 1011 +++++++++++++++++++++++++++++-
src/include/reef/Makefile.am | 4 +-
src/include/reef/audio/Makefile.am | 8 +-
src/include/uapi/Makefile.am | 2 +-
src/ipc/Makefile.am | 28 +-
src/library/Makefile.am | 1 +
src/library/include/Makefile.am | 1 +
src/library/include/platform/Makefile.am | 12 +
src/library/include/platform/clk.h | 42 ++
src/library/include/platform/dma.h | 42 ++
src/library/include/platform/interrupt.h | 78 +++
src/library/include/platform/mailbox.h | 72 +++
src/library/include/platform/memory.h | 87 +++
src/library/include/platform/platform.h | 54 ++
src/library/include/platform/pmc.h | 41 ++
src/library/include/platform/shim.h | 40 ++
src/library/include/platform/timer.h | 54 ++
src/math/Makefile.am | 22 +-
32 files changed, 1956 insertions(+), 35 deletions(-)
create mode 100644 src/arch/host/Makefile.am
create mode 100644 src/arch/host/include/Makefile.am
create mode 100644 src/arch/host/include/arch/Makefile.am
create mode 100644 src/arch/host/include/arch/cache.h
create mode 100644 src/arch/host/include/arch/interrupt.h
create mode 100644 src/arch/host/include/arch/reef.h
create mode 100644 src/arch/host/include/arch/spinlock.h
create mode 100644 src/arch/host/include/arch/timer.h
create mode 100644 src/library/Makefile.am
create mode 100644 src/library/include/Makefile.am
create mode 100644 src/library/include/platform/Makefile.am
create mode 100644 src/library/include/platform/clk.h
create mode 100644 src/library/include/platform/dma.h
create mode 100644 src/library/include/platform/interrupt.h
create mode 100644 src/library/include/platform/mailbox.h
create mode 100644 src/library/include/platform/memory.h
create mode 100644 src/library/include/platform/platform.h
create mode 100644 src/library/include/platform/pmc.h
create mode 100644 src/library/include/platform/shim.h
create mode 100644 src/library/include/platform/timer.h
diff --git a/Makefile.am b/Makefile.am
index c05f042..4d5a7a2 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -17,6 +17,22 @@ export ARCH_INCDIR = \
export PLATFORM_INCDIR = \
-I $(SRC_DIR)/platform/$(PLATFORM)/include
+if BUILD_HOST
+export ARCH_INCDIR = \
+ -I $(SRC_DIR)/arch/$(ARCH)/include
+
+if BUILD_LIB
+export PLATFORM_INCDIR = \
+ -I $(SRC_DIR)/library/include
+else
+export PLATFORM_INCDIR = \
+ -I $(SRC_DIR)/platform/$(PLATFORM)/include
+endif
+else
+BUILT_SOURCES = $(top_srcdir)/src/include/version.h
+endif
+
+
dist-hook:
./version.sh $(top_srcdir)
cat .version > $(distdir)/.tarball-version
diff --git a/README b/README
index 9ca5b12..463fc42 100644
--- a/README
+++ b/README
@@ -13,6 +13,13 @@ Cherrytrail :-
./configure --with-arch=xtensa --with-platform=cherrytrail --with-root-dir=$PWD/../xtensa-root/xtensa-byt-elf --host=xtensa-byt-elf
+Library for Host Platform :-
+If building library for host platform, run the following configure. Please modify
+the --prefix option to choose the directory for installing the library files and
+headers
+
+./configure --with-arch=host --enable-library=yes --host=x86_64-unknown-linux-gnu --prefix=$pwd/../host-root/
+
3) make
4) make bin
diff --git a/build-all.sh b/build-all.sh
index 2e015f6..5bd273d 100755
--- a/build-all.sh
+++ b/build-all.sh
@@ -9,6 +9,11 @@ pwd=`pwd`
rm -fr src/arch/xtensa/*.ri
+# build library for host platform architecture
+./configure --with-arch=host --enable-library=yes --host=x86_64-unknown-linux-gnu --prefix=$pwd/../host-root/
+make
+make install
+
# Build for Baytrail
./configure --with-arch=xtensa --with-platform=baytrail --with-root-dir=$pwd/../xtensa-root/xtensa-byt-elf --host=xtensa-byt-elf
make clean
diff --git a/configure.ac b/configure.ac
index 00c377f..a66b968 100644
--- a/configure.ac
+++ b/configure.ac
@@ -25,10 +25,13 @@ CFLAGS="${CFLAGS:+$CFLAGS } -O2 -g -Wall -Werror -Wl,-EL -fno-inline-functions -
AC_ARG_WITH([root-dir],
AS_HELP_STRING([--with-root-dir], [Specify location of cross gcc libraries and headers]),
[], [with_root_dir=no])
-AS_IF([test "x$with_root_dir" = xno],
- AC_MSG_ERROR([Please specify cross compiler root header directory]),
- [ROOT_DIR=$with_root_dir])
-AC_SUBST(ROOT_DIR)
+
+# check if we are building FW image or library
+AC_ARG_ENABLE(library, [AS_HELP_STRING([--enable-library],[build library])], have_library=$enableval, have_library=no)
+if test "$have_library" = "yes"; then
+ AC_DEFINE([CONFIG_LIB], [1], [Configure for Shared Library])
+fi
+AM_CONDITIONAL(BUILD_LIB, test "$have_library" = "yes")
# Architecture support
AC_ARG_WITH([arch],
@@ -53,6 +56,23 @@ case "$with_arch" in
ARCH="xtensa"
AC_SUBST(ARCH)
+
+ AS_IF([test "x$with_root_dir" = xno],
+ AC_MSG_ERROR([Please specify cross compiler root header directory]),
+ [ROOT_DIR=$with_root_dir])
+ AC_SUBST(ROOT_DIR)
+ ;;
+ host*)
+
+ ARCH_CFLAGS="-g"
+ AC_SUBST(ARCH_CFLAGS)
+
+ # extra CFLAGS defined here otherwise configure working gcc tests fails.
+ CFLAGS="${CFLAGS:+$CFLAGS } -O3"
+ LDFLAGS="${LDFLAGS:+$LDFLAGS }-lpthread"
+
+ ARCH="host"
+ AC_SUBST(ARCH)
;;
*)
AC_MSG_ERROR([DSP architecture not specified])
@@ -60,7 +80,7 @@ case "$with_arch" in
esac
AM_CONDITIONAL(BUILD_XTENSA, test "$ARCH" = "xtensa")
-
+AM_CONDITIONAL(BUILD_HOST, test "$ARCH" = "host")
# Platform support
AC_ARG_WITH([platform],
@@ -103,7 +123,11 @@ case "$with_platform" in
AC_DEFINE([CONFIG_HOST_PTABLE], [1], [Configure handling host page table])
;;
*)
- AC_MSG_ERROR([Host platform not specified])
+ if test "$ARCH" = "host"; then
+ PLATFORM="host"
+ else
+ AC_MSG_ERROR([Host platform not specified])
+ fi
;;
esac
@@ -136,6 +160,70 @@ AS_IF([test "x$enable_dma_trace" != "xno"], [
AM_CONDITIONAL(BUILD_DMA_TRACE, test "x$enable_dma_trace" != "xno")
+# Optimisation settings and checks
+
+# SSE4_2 support
+AC_ARG_ENABLE(sse42, [AS_HELP_STRING([--enable-sse42],[enable SSE42 optimizations])], have_sse42=$enableval, have_sse42=yes)
+AX_CHECK_COMPILE_FLAG(-msse4.2, [SSE42_CFLAGS="-DOPS_SSE42 -msse4.2 -ffast-math -ftree-vectorizer-verbose=0"],
+ [have_sse42=no])
+if test "$have_sse42" = "yes"; then
+ AC_DEFINE(HAVE_SSE42,1,[Define to enable SSE42 optimizations.])
+fi
+AM_CONDITIONAL(HAVE_SSE42, test "$have_sse42" = "yes")
+AC_SUBST(SSE42_CFLAGS)
+
+# AVX support
+AC_ARG_ENABLE(avx, [AS_HELP_STRING([--enable-avx],[enable AVX optimizations])], have_avx=$enableval, have_avx=yes)
+AX_CHECK_COMPILE_FLAG(-mavx, [AVX_CFLAGS="-DOPS_AVX -mavx -ffast-math -ftree-vectorizer-verbose=0"],
+ [have_avx=no])
+if test "$have_avx" = "yes"; then
+ AC_DEFINE(HAVE_AVX,1,[Define to enable AVX optimizations.])
+fi
+AM_CONDITIONAL(HAVE_AVX, test "$have_avx" = "yes")
+AC_SUBST(AVX_CFLAGS)
+
+
+# AVX2 support
+AC_ARG_ENABLE(avx2, [AS_HELP_STRING([--enable-avx2],[enable AVX2 optimizations])], have_avx2=$enableval, have_avx2=yes)
+AX_CHECK_COMPILE_FLAG(-mavx2, [AVX2_CFLAGS="-DOPS_AVX2 -mavx2 -ffast-math -ftree-vectorizer-verbose=0"],
+ [have_avx2=no])
+if test "$have_avx2" = "yes"; then
+ AC_DEFINE(HAVE_AVX2,1,[Define to enable AVX2 optimizations.])
+fi
+AM_CONDITIONAL(HAVE_AVX2, test "$have_avx2" = "yes")
+AC_SUBST(AVX2_CFLAGS)
+
+
+# FMA support
+AC_ARG_ENABLE(fma, [AS_HELP_STRING([--enable-fma],[enable FMA optimizations])], have_fma=$enableval, have_fma=yes)
+AX_CHECK_COMPILE_FLAG(-mfma, [FMA_CFLAGS="-DOPS_FMA -mfma -ffast-math -ftree-vectorizer-verbose=0"],
+ [have_fma=no])
+if test "$have_fma" = "yes"; then
+ AC_DEFINE(HAVE_FMA,1,[Define to enable FMA optimizations.])
+fi
+AM_CONDITIONAL(HAVE_FMA, test "$have_fma" = "yes")
+AC_SUBST(FMA_CFLAGS)
+
+# Hifi2EP
+AC_ARG_ENABLE(hifi2ep, [AS_HELP_STRING([--enable-hifi2ep],[enable HiFi2EP optimizations])], have_hifi2ep=$enableval, have_hifi2ep=yes)
+AX_CHECK_COMPILE_FLAG(-mhifi2ep, [FMA_CFLAGS="-DOPS_HIFI2EP -mhifi2ep -ffast-math -ftree-vectorizer-verbose=0"],
+ [have_hifi2ep=no])
+if test "$have_hifi2ep" = "yes"; then
+ AC_DEFINE(HAVE_HIFI2EP,1,[Define to enable Hifi2 EP optimizations.])
+fi
+AM_CONDITIONAL(HAVE_HIFI2EP, test "$have_hifi2ep" = "yes")
+AC_SUBST(HIFI2EP_CFLAGS)
+
+# Hifi3
+AC_ARG_ENABLE(hifi3, [AS_HELP_STRING([--enable-hifi3],[enable HiFi3 optimizations])], have_hifi3=$enableval, have_hifi3=yes)
+AX_CHECK_COMPILE_FLAG(-mhihi3, [FMA_CFLAGS="-DOPS_HIFI3 -mhifi3 -ffast-math -ftree-vectorizer-verbose=0"],
+ [have_hifi3=no])
+if test "$have_hifi3" = "yes"; then
+ AC_DEFINE(HAVE_HIFI3,1,[Define to enable Hifi3 optimizations.])
+fi
+AM_CONDITIONAL(HAVE_HIFI3, test "$have_hifi3" = "yes")
+AC_SUBST(HIFI3_CFLAGS)
+
# Test after CFLAGS set othewise test of cross compiler fails.
AM_PROG_AS
AM_PROG_AR
@@ -161,6 +249,9 @@ AC_CONFIG_FILES([
src/arch/xtensa/include/xtensa/config/Makefile
src/arch/xtensa/hal/Makefile
src/arch/xtensa/xtos/Makefile
+ src/arch/host/Makefile
+ src/arch/host/include/Makefile
+ src/arch/host/include/arch/Makefile
src/audio/Makefile
src/math/Makefile
src/drivers/Makefile
diff --git a/src/Makefile.am b/src/Makefile.am
index fb82330..ed21692 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1 +1,10 @@
-SUBDIRS = include init math audio platform tasks drivers ipc lib arch
+export COMMON_INCDIR = \
+ $(REEF_INCDIR) \
+ $(ARCH_INCDIR) \
+ $(PLATFORM_INCDIR)
+
+if BUILD_LIB
+SUBDIRS = ipc math audio arch include library
+else
+SUBDIRS = init math audio platform tasks drivers ipc lib arch include
+endif
diff --git a/src/arch/Makefile.am b/src/arch/Makefile.am
index d0d1b15..e924254 100644
--- a/src/arch/Makefile.am
+++ b/src/arch/Makefile.am
@@ -1,3 +1,7 @@
if BUILD_XTENSA
SUBDIRS = xtensa
endif
+
+if BUILD_HOST
+SUBDIRS = host
+endif
diff --git a/src/arch/host/Makefile.am b/src/arch/host/Makefile.am
new file mode 100644
index 0000000..7b92e00
--- /dev/null
+++ b/src/arch/host/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = include
diff --git a/src/arch/host/include/Makefile.am b/src/arch/host/include/Makefile.am
new file mode 100644
index 0000000..f0ac9b7
--- /dev/null
+++ b/src/arch/host/include/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = arch
diff --git a/src/arch/host/include/arch/Makefile.am b/src/arch/host/include/arch/Makefile.am
new file mode 100644
index 0000000..6dddb35
--- /dev/null
+++ b/src/arch/host/include/arch/Makefile.am
@@ -0,0 +1,8 @@
+includedir = $(prefix)/include/sof/arch
+
+include_HEADERS = \
+ cache.h \
+ interrupt.h \
+ reef.h \
+ spinlock.h \
+ timer.h
diff --git a/src/arch/host/include/arch/cache.h b/src/arch/host/include/arch/cache.h
new file mode 100644
index 0000000..e64a6c5
--- /dev/null
+++ b/src/arch/host/include/arch/cache.h
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2017, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __INCLUDE_ARCH_CACHE__
+#define __INCLUDE_ARCH_CACHE__
+
+#include <stdint.h>
+#include <stddef.h>
+
+static inline void dcache_writeback_region(void *addr, size_t size) {}
+static inline void dcache_invalidate_region(void *addr, size_t size) {}
+static inline void icache_invalidate_region(void *addr, size_t size) {}
+static inline void dcache_writeback_invalidate_region(void *addr,
+ size_t size) {}
+
+#endif
diff --git a/src/arch/host/include/arch/interrupt.h b/src/arch/host/include/arch/interrupt.h
new file mode 100644
index 0000000..68493e5
--- /dev/null
+++ b/src/arch/host/include/arch/interrupt.h
@@ -0,0 +1,54 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ *
+ */
+
+#ifndef __ARCH_INTERRUPT_H
+#define __ARCH_INTERRUPT_H
+
+#include <reef/interrupt-map.h>
+#include <stdint.h>
+#include <stdlib.h>
+#include <unistd.h>
+#include <pthread.h>
+
+static inline int arch_interrupt_register(int irq,
+ void (*handler)(void *arg), void *arg) {return 0; }
+static inline void arch_interrupt_unregister(int irq) {}
+static inline uint32_t arch_interrupt_enable_mask(uint32_t mask) {return 0; }
+static inline uint32_t arch_interrupt_disable_mask(uint32_t mask) {return 0; }
+static inline void arch_interrupt_set(int irq) {}
+static inline void arch_interrupt_clear(int irq) {}
+static inline uint32_t arch_interrupt_get_enabled(void) {return 0; }
+static inline uint32_t arch_interrupt_get_status(void) {return 0; }
+static inline uint32_t arch_interrupt_global_disable(void) {return 0; }
+static inline void arch_interrupt_global_enable(uint32_t flags) {}
+static inline int arch_interrupt_init(void) {return 0; }
+
+#endif
diff --git a/src/arch/host/include/arch/reef.h b/src/arch/host/include/arch/reef.h
new file mode 100644
index 0000000..29090a2
--- /dev/null
+++ b/src/arch/host/include/arch/reef.h
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ *
+ */
+
+#ifndef __INCLUDE_ARCH_REEF__
+#define __INCLUDE_ARCH_REEF__
+
+#include <stdint.h>
+#include <stddef.h>
+
+#define arch_memcpy(dest, src, size) \
+ memcpy(dest, src, size)
+
+#endif
diff --git a/src/arch/host/include/arch/spinlock.h b/src/arch/host/include/arch/spinlock.h
new file mode 100644
index 0000000..ea59769
--- /dev/null
+++ b/src/arch/host/include/arch/spinlock.h
@@ -0,0 +1,46 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ *
+ */
+
+#ifndef __ARCH_SPINLOCK_H_
+#define __ARCH_SPINLOCK_H_
+
+#include <stdint.h>
+#include <errno.h>
+#include <pthread.h>
+
+typedef struct {
+} spinlock_t;
+
+static inline void arch_spinlock_init(spinlock_t *lock) {}
+static inline void arch_spin_lock(spinlock_t *lock) {}
+static inline void arch_spin_unlock(spinlock_t *lock) {}
+
+#endif
diff --git a/src/arch/host/include/arch/timer.h b/src/arch/host/include/arch/timer.h
new file mode 100644
index 0000000..c650da3
--- /dev/null
+++ b/src/arch/host/include/arch/timer.h
@@ -0,0 +1,52 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ *
+ */
+
+#ifndef __ARCH_TIMER_H_
+#define __ARCH_TIMER_H_
+
+#include <arch/interrupt.h>
+#include <stdint.h>
+#include <errno.h>
+
+struct timer {
+};
+
+static inline int arch_timer_register(struct timer *timer,
+ void (*handler)(void *arg), void *arg) {return 0; }
+static inline void arch_timer_unregister(struct timer *timer) {}
+static inline void arch_timer_enable(struct timer *timer) {}
+static inline void arch_timer_disable(struct timer *timer) {}
+static inline uint32_t arch_timer_get_system(struct timer *timer) {return 0; }
+static inline int arch_timer_set(struct timer *timer,
+ uint64_t ticks) {return 0; }
+static inline void arch_timer_clear(struct timer *timer) {}
+
+#endif
diff --git a/src/audio/Makefile.am b/src/audio/Makefile.am
index d19dff7..bccedbf 100644
--- a/src/audio/Makefile.am
+++ b/src/audio/Makefile.am
@@ -1,12 +1,1003 @@
-noinst_LIBRARIES = libaudio.a
+includedir = $(prefix)/include/sof/audio
-noinst_HEADERS = \
- eq_fir.h \
+include_HEADERS = \
eq_iir.h \
- fir.h \
- iir.h \
- src_config.h \
- src_core.h
+ eq_fir.h
+
+COMP_SRC = \
+ eq_iir.c \
+ iir.c \
+ eq_fir.c \
+ fir.c \
+ tone.c \
+ src.c \
+ src_core.c \
+ mixer.c \
+ mux.c \
+ volume.c \
+ switch.c \
+ dai.c \
+ host.c \
+ pipeline.c \
+ component.c \
+ buffer.c
+
+SOF_SRC = \
+ dai.c \
+ host.c \
+ pipeline.c \
+ component.c \
+ buffer.c
+
+SRC_SRC = \
+ src.c \
+ src_core.c
+
+EQ_FIR_SRC = \
+ eq_fir.c \
+ fir.c
+
+EQ_IIR_SRC = \
+ eq_iir.c \
+ iir.c
+
+if BUILD_LIB
+
+# only host builds shared libraries, the rest are static
+if BUILD_HOST
+
+# libsof
+lib_LTLIBRARIES = libsof.la
+
+libsof_la_SOURCES = $(SOF_SRC)
+
+libsof_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src.la
+
+libsof_src_la_SOURCES = $(SRC_SRC)
+
+libsof_src_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir.la
+
+libsof_eq_fir_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir.la
+
+libsof_eq_iir_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume.la
+
+libsof_volume_la_SOURCES = volume.c
+
+libsof_volume_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux.la
+
+libsof_mux_la_SOURCES = mux.c
+
+libsof_mux_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch.la
+
+libsof_switch_la_SOURCES = switch.c
+
+libsof_switch_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer.la
+
+libsof_mixer_la_SOURCES = mixer.c
+
+libsof_mixer_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone.la
+
+libsof_tone_la_SOURCES = tone.c
+
+libsof_tone_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+if HAVE_SSE42
+# libsof
+lib_LTLIBRARIES += libsof_sse42.la
+
+libsof_sse42_la_SOURCES = $(SOF_SRC)
+
+libsof_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_sse42.la
+
+libsof_src_sse42_la_SOURCES = $(SRC_SRC)
+
+libsof_src_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_sse42.la
+
+libsof_eq_fir_sse42_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_sse42.la
+
+libsof_eq_iir_sse42_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_sse42.la
+
+libsof_volume_sse42_la_SOURCES = volume.c
+
+libsof_volume_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_sse42.la
+
+libsof_mux_sse42_la_SOURCES = mux.c
+
+libsof_mux_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_sse42.la
+
+libsof_switch_sse42_la_SOURCES = switch.c
+
+libsof_switch_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_sse42.la
+
+libsof_mixer_sse42_la_SOURCES = mixer.c
+
+libsof_mixer_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_sse42.la
+
+libsof_tone_sse42_la_SOURCES = tone.c
+
+libsof_tone_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_sse42_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+endif
+
+if HAVE_AVX
+# libsof
+lib_LTLIBRARIES += libsof_avx.la
+
+libsof_avx_la_SOURCES = $(SOF_SRC)
+
+libsof_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx.la
+
+libsof_src_avx_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx.la
+
+libsof_eq_fir_avx_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx.la
+
+libsof_eq_iir_avx_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx.la
+
+libsof_volume_avx_la_SOURCES = volume.c
+
+libsof_volume_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx.la
+
+libsof_mux_avx_la_SOURCES = mux.c
+
+libsof_mux_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx.la
+
+libsof_switch_avx_la_SOURCES = switch.c
+
+libsof_switch_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx.la
+
+libsof_mixer_avx_la_SOURCES = mixer.c
+
+libsof_mixer_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx.la
+
+libsof_tone_avx_la_SOURCES = tone.c
+
+libsof_tone_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+endif
+
+if HAVE_AVX2
+# libsof
+lib_LTLIBRARIES += libsof_avx2.la
+
+libsof_avx2_la_SOURCES = $(SOF_SRC)
+
+libsof_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx2.la
+
+libsof_src_avx2_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx2.la
+
+libsof_eq_fir_avx2_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx2.la
+
+libsof_eq_iir_avx2_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx2.la
+
+libsof_volume_avx2_la_SOURCES = volume.c
+
+libsof_volume_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx2.la
+
+libsof_mux_avx2_la_SOURCES = mux.c
+
+libsof_mux_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx2.la
+
+libsof_switch_avx2_la_SOURCES = switch.c
+
+libsof_switch_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx2.la
+
+libsof_mixer_avx2_la_SOURCES = mixer.c
+
+libsof_mixer_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx2.la
+
+libsof_tone_avx2_la_SOURCES = tone.c
+
+libsof_tone_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx2_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+endif
+
+if HAVE_FMA
+# libsof
+lib_LTLIBRARIES += libsof_fma.la
+
+libsof_fma_la_SOURCES = $(SOF_SRC)
+
+libsof_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_fma.la
+
+libsof_src_fma_la_SOURCES = $(SRC_SRC)
+
+libsof_src_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_fma.la
+
+libsof_eq_fir_fma_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_fma.la
+
+libsof_eq_iir_fma_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_fma.la
+
+libsof_volume_fma_la_SOURCES = volume.c
+
+libsof_volume_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_fma.la
+
+libsof_mux_fma_la_SOURCES = mux.c
+
+libsof_mux_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_fma.la
+
+libsof_switch_fma_la_SOURCES = switch.c
+
+libsof_switch_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_fma.la
+
+libsof_mixer_fma_la_SOURCES = mixer.c
+
+libsof_mixer_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_fma.la
+
+libsof_tone_fma_la_SOURCES = tone.c
+
+libsof_tone_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_fma_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+endif
+
+else
+
+# Build for non host targets
+
+# libsof
+lib_LIBRARIES = libsof.a
+
+libsof_a_SOURCES = $(SOF_SRC)
+
+libsof_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src.a
+
+libsof_src_a_SOURCES = $(SRC_SRC)
+
+libsof_src_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir.a
+
+libsof_eq_fir_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir.a
+
+libsof_eq_iir_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume.a
+
+libsof_volume_a_SOURCES = volume.c
+
+libsof_volume_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux.a
+
+libsof_mux_a_SOURCES = mux.c
+
+libsof_mux_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch.a
+
+libsof_switch_a_SOURCES = switch.c
+
+libsof_switch_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer.a
+
+libsof_mixer_a_SOURCES = mixer.c
+
+libsof_mixer_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone.a
+
+libsof_tone_a_SOURCES = tone.c
+
+libsof_tone_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+
+if HAVE_HIFI2EP
+# libsof
+lib_LIBRARIES += libsof_hifi2ep.a
+
+libsof_hifi2ep_a_SOURCES = $(SOF_SRC)
+
+libsof_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi2ep.a
+
+libsof_src_hifi2ep_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi2ep.a
+
+libsof_eq_fir_hifi2ep_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi2ep.a
+
+libsof_eq_iir_hifi2ep_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi2ep.a
+
+libsof_volume_hifi2ep_a_SOURCES = volume.c
+
+libsof_volume_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi2ep.a
+
+libsof_mux_hifi2ep_a_SOURCES = mux.c
+
+libsof_mux_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi2ep.a
+
+libsof_switch_hifi2ep_a_SOURCES = switch.c
+
+libsof_switch_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi2ep.a
+
+libsof_mixer_hifi2ep_a_SOURCES = mixer.c
+
+libsof_mixer_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi2ep.a
+
+libsof_tone_hifi2ep_a_SOURCES = tone.c
+
+libsof_tone_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
+
+if HAVE_HIFI3
+# libsof
+lib_LIBRARIES += libsof_hifi3.a
+
+libsof_hifi3_a_SOURCES = $(COMP_SRC)
+
+libsof_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi3.a
+
+libsof_src_hifi3_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi3.a
+
+libsof_eq_fir_hifi3_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi3.a
+
+libsof_eq_iir_hifi3_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi3.a
+
+libsof_volume_hifi3_a_SOURCES = volume.c
+
+libsof_volume_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi3.a
+
+libsof_mux_hifi3_a_SOURCES = mux.c
+
+libsof_mux_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi3.a
+
+libsof_switch_hifi3_a_SOURCES = switch.c
+
+libsof_switch_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi3.a
+
+libsof_mixer_hifi3_a_SOURCES = mixer.c
+
+libsof_mixer_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi3.a
+
+libsof_tone_hifi3_a_SOURCES = tone.c
+
+libsof_tone_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
+
+endif
+
+else
+
+# build for firmware image
+
+noinst_LIBRARIES = libaudio.a
libaudio_a_SOURCES = \
eq_iir.c \
@@ -29,6 +1020,6 @@ libaudio_a_SOURCES = \
libaudio_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+endif
diff --git a/src/include/reef/Makefile.am b/src/include/reef/Makefile.am
index 3f90e90..31bd091 100644
--- a/src/include/reef/Makefile.am
+++ b/src/include/reef/Makefile.am
@@ -1,6 +1,8 @@
SUBDIRS = audio math
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef
+
+include_HEADERS = \
alloc.h \
clock.h \
dai.h \
diff --git a/src/include/reef/audio/Makefile.am b/src/include/reef/audio/Makefile.am
index 60b7145..1d2b9cb 100644
--- a/src/include/reef/audio/Makefile.am
+++ b/src/include/reef/audio/Makefile.am
@@ -1,7 +1,9 @@
SUBDIRS = coefficients
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef/audio
+
+include_HEADERS = \
component.h \
pipeline.h \
- buffer.h \
- format.h
+ format.h \
+ buffer.h
diff --git a/src/include/uapi/Makefile.am b/src/include/uapi/Makefile.am
index 103d692..f202eca 100644
--- a/src/include/uapi/Makefile.am
+++ b/src/include/uapi/Makefile.am
@@ -1,4 +1,4 @@
-includedir = $(prefix)/include/sof
+includedir = $(prefix)/include/sof/uapi
include_HEADERS = \
ipc.h \
diff --git a/src/ipc/Makefile.am b/src/ipc/Makefile.am
index 7e63ca6..359ae03 100644
--- a/src/ipc/Makefile.am
+++ b/src/ipc/Makefile.am
@@ -1,7 +1,22 @@
-noinst_LIBRARIES = libipc.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_ipc.la
+
+libsof_ipc_la_SOURCES = \
+ ipc.c
+
+libsof_ipc_la_LDFLAGS = \
+ -version-info `echo $(VERSION) | cut -d '.' -f 1` \
+ -no-undefined \
+ -export-dynamic
+
+libsof_ipc_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_ipc.a
if BUILD_BAYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -10,7 +25,7 @@ libipc_a_SOURCES = \
endif
if BUILD_CHERRYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -18,9 +33,8 @@ libipc_a_SOURCES = \
dma-copy.c
endif
-libipc_a_CFLAGS = \
+libsof_ipc_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(ARCH_INCDIR) \
- $(REEF_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+endif
diff --git a/src/library/Makefile.am b/src/library/Makefile.am
new file mode 100644
index 0000000..7b92e00
--- /dev/null
+++ b/src/library/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = include
diff --git a/src/library/include/Makefile.am b/src/library/include/Makefile.am
new file mode 100644
index 0000000..912728c
--- /dev/null
+++ b/src/library/include/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = platform
diff --git a/src/library/include/platform/Makefile.am b/src/library/include/platform/Makefile.am
new file mode 100644
index 0000000..5a735ae
--- /dev/null
+++ b/src/library/include/platform/Makefile.am
@@ -0,0 +1,12 @@
+includedir = $(prefix)/include/sof/platform
+
+include_HEADERS = \
+ clk.h \
+ dma.h \
+ interrupt.h \
+ mailbox.h \
+ memory.h \
+ platform.h \
+ pmc.h \
+ shim.h \
+ timer.h
diff --git a/src/library/include/platform/clk.h b/src/library/include/platform/clk.h
new file mode 100644
index 0000000..0dd11e6
--- /dev/null
+++ b/src/library/include/platform/clk.h
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __PLATFORM_HOST_CLOCK__
+#define __PLATFORM_HOST_CLOCK__
+
+#define CLK_CPU 0
+#define CLK_SSP 1
+
+#define CLK_DEFAULT_CPU_HZ 50000000
+#define CLK_MAX_CPU_HZ 343000000
+
+void init_platform_clocks(void);
+
+#endif
diff --git a/src/library/include/platform/dma.h b/src/library/include/platform/dma.h
new file mode 100644
index 0000000..457da8a
--- /dev/null
+++ b/src/library/include/platform/dma.h
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __PLATFORM_HOST_DMA_H__
+#define __PLATFORM_HOST_DMA_H__
+
+#include <stdint.h>
+
+#define DMA_ID_DMAC0 0
+#define DMA_ID_DMAC1 1
+
+#define DMA_DEV_PCM 0
+#define DMA_DEV_WAV 1
+
+#endif
diff --git a/src/library/include/platform/interrupt.h b/src/library/include/platform/interrupt.h
new file mode 100644
index 0000000..eb0fbfd
--- /dev/null
+++ b/src/library/include/platform/interrupt.h
@@ -0,0 +1,78 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __INCLUDE_PLATFORM_HOST_INTERRUPT__
+#define __INCLUDE_PLATFORM_HOST_INTERRUPT__
+
+#include <stdint.h>
+#include <reef/interrupt-map.h>
+
+/* IRQ numbers */
+#define IRQ_NUM_SOFTWARE0 0 /* Level 1 */
+#define IRQ_NUM_TIMER1 1 /* Level 1 */
+#define IRQ_NUM_SOFTWARE1 2 /* Level 1 */
+#define IRQ_NUM_SOFTWARE2 3 /* Level 1 */
+#define IRQ_NUM_TIMER2 5 /* Level 2 */
+#define IRQ_NUM_SOFTWARE3 6 /* Level 2 */
+#define IRQ_NUM_TIMER3 7 /* Level 3 */
+#define IRQ_NUM_SOFTWARE4 8 /* Level 3 */
+#define IRQ_NUM_SOFTWARE5 9 /* Level 3 */
+#define IRQ_NUM_EXT_IA 10 /* Level 4 */
+#define IRQ_NUM_EXT_PMC 11 /* Level 4 */
+#define IRQ_NUM_SOFTWARE6 12 /* Level 5 */
+#define IRQ_NUM_EXT_DMAC0 13 /* Level 5 */
+#define IRQ_NUM_EXT_DMAC1 14 /* Level 5 */
+#define IRQ_NUM_EXT_TIMER 15 /* Level 5 */
+#define IRQ_NUM_EXT_SSP0 16 /* Level 5 */
+#define IRQ_NUM_EXT_SSP1 17 /* Level 5 */
+#define IRQ_NUM_EXT_SSP2 18 /* Level 5 */
+#define IRQ_NUM_NMI 20 /* Level 7 */
+
+/* IRQ Masks */
+#define IRQ_MASK_SOFTWARE0 (1 << IRQ_NUM_SOFTWARE0)
+#define IRQ_MASK_TIMER1 (1 << IRQ_NUM_TIMER1)
+#define IRQ_MASK_SOFTWARE1 (1 << IRQ_NUM_SOFTWARE1)
+#define IRQ_MASK_SOFTWARE2 (1 << IRQ_NUM_SOFTWARE2)
+#define IRQ_MASK_TIMER2 (1 << IRQ_NUM_TIMER2)
+#define IRQ_MASK_SOFTWARE3 (1 << IRQ_NUM_SOFTWARE3)
+#define IRQ_MASK_TIMER3 (1 << IRQ_NUM_TIMER3)
+#define IRQ_MASK_SOFTWARE4 (1 << IRQ_NUM_SOFTWARE4)
+#define IRQ_MASK_SOFTWARE5 (1 << IRQ_NUM_SOFTWARE5)
+#define IRQ_MASK_EXT_IA (1 << IRQ_NUM_EXT_IA)
+#define IRQ_MASK_EXT_PMC (1 << IRQ_NUM_EXT_PMC)
+#define IRQ_MASK_SOFTWARE6 (1 << IRQ_NUM_SOFTWARE6)
+#define IRQ_MASK_EXT_DMAC0 (1 << IRQ_NUM_EXT_DMAC0)
+#define IRQ_MASK_EXT_DMAC1 (1 << IRQ_NUM_EXT_DMAC1)
+#define IRQ_MASK_EXT_TIMER (1 << IRQ_NUM_EXT_TIMER)
+#define IRQ_MASK_EXT_SSP0 (1 << IRQ_NUM_EXT_SSP0)
+#define IRQ_MASK_EXT_SSP1 (1 << IRQ_NUM_EXT_SSP1)
+#define IRQ_MASK_EXT_SSP2 (1 << IRQ_NUM_EXT_SSP2)
+
+#endif
diff --git a/src/library/include/platform/mailbox.h b/src/library/include/platform/mailbox.h
new file mode 100644
index 0000000..650ab47
--- /dev/null
+++ b/src/library/include/platform/mailbox.h
@@ -0,0 +1,72 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __INCLUDE_PLATFORM_HOST_MAILBOX__
+#define __INCLUDE_PLATFORM_HOST_MAILBOX__
+
+#include <platform/memory.h>
+
+#define MAILBOX_HOST_OFFSET 0x144000
+
+#define MAILBOX_OUTBOX_OFFSET 0x0
+#define MAILBOX_OUTBOX_SIZE 0x400
+#define MAILBOX_OUTBOX_BASE \
+ (MAILBOX_BASE + MAILBOX_OUTBOX_OFFSET)
+
+#define MAILBOX_INBOX_OFFSET MAILBOX_OUTBOX_SIZE
+#define MAILBOX_INBOX_SIZE 0x400
+#define MAILBOX_INBOX_BASE \
+ (MAILBOX_BASE + MAILBOX_INBOX_OFFSET)
+
+#define MAILBOX_EXCEPTION_OFFSET \
+ (MAILBOX_INBOX_SIZE + MAILBOX_OUTBOX_SIZE)
+#define MAILBOX_EXCEPTION_SIZE 0x100
+#define MAILBOX_EXCEPTION_BASE \
+ (MAILBOX_BASE + MAILBOX_EXCEPTION_OFFSET)
+
+#define MAILBOX_DEBUG_OFFSET \
+ (MAILBOX_EXCEPTION_SIZE + MAILBOX_EXCEPTION_OFFSET)
+#define MAILBOX_DEBUG_SIZE 0x100
+#define MAILBOX_DEBUG_BASE \
+ (MAILBOX_BASE + MAILBOX_DEBUG_OFFSET)
+
+#define MAILBOX_STREAM_OFFSET \
+ (MAILBOX_DEBUG_SIZE + MAILBOX_DEBUG_OFFSET)
+#define MAILBOX_STREAM_SIZE 0x200
+#define MAILBOX_STREAM_BASE \
+ (MAILBOX_BASE + MAILBOX_STREAM_OFFSET)
+
+#define MAILBOX_TRACE_OFFSET \
+ (MAILBOX_STREAM_SIZE + MAILBOX_STREAM_OFFSET)
+#define MAILBOX_TRACE_SIZE 0x380
+#define MAILBOX_TRACE_BASE \
+ (MAILBOX_BASE + MAILBOX_TRACE_OFFSET)
+
+#endif
diff --git a/src/library/include/platform/memory.h b/src/library/include/platform/memory.h
new file mode 100644
index 0000000..78541e7
--- /dev/null
+++ b/src/library/include/platform/memory.h
@@ -0,0 +1,87 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __PLATFORM_HOST_MEMORY_H__
+#define __PLATFORM_HOST_MEMORY_H__
+
+#include <config.h>
+
+#if CONFIG_HT_BAYTRAIL
+#include <baytrail/include/platform/memory.h>
+#endif
+
+#define HEAP_BUFFER_SIZE (1024 * 128)
+
+#if 0
+/* physical DSP addresses */
+
+#define IRAM_BASE 0xFF2C0000
+#define IRAM_SIZE 0x00014000
+
+#define DRAM0_BASE 0xFF300000
+#define DRAM0_SIZE 0x00028000
+#define DRAM0_VBASE 0xC0000000
+
+#define MAILBOX_BASE (DRAM0_BASE + DRAM0_SIZE - 0x2000)
+
+
+/* HEAP Constants - WARNING this MUST be aligned with the linker script */
+/* TODO:preproces linker script with this header to align automatically. */
+
+/* Heap section sizes for module pool */
+#define HEAP_MOD_COUNT8 0
+#define HEAP_MOD_COUNT16 256
+#define HEAP_MOD_COUNT32 128
+#define HEAP_MOD_COUNT64 64
+#define HEAP_MOD_COUNT128 32
+#define HEAP_MOD_COUNT256 16
+#define HEAP_MOD_COUNT512 8
+#define HEAP_MOD_COUNT1024 4
+
+/* total Heap for modules - must be aligned with linker script !!! */
+#define HEAP_MOD_SIZE \
+ (HEAP_MOD_COUNT8 * 8 + HEAP_MOD_COUNT16 * 16 + \
+ HEAP_MOD_COUNT32 * 32 + HEAP_MOD_COUNT64 * 64 + \
+ HEAP_MOD_COUNT128 * 128 + HEAP_MOD_COUNT256 * 256 + \
+ HEAP_MOD_COUNT512 * 512 + HEAP_MOD_COUNT1024 * 1024)
+
+/* Heap for buffers */
+#define HEAP_BUF_BLOCK_SIZE 1024
+#define HEAP_BUF_COUNT 111
+#define HEAP_BUF_SIZE (HEAP_BUF_BLOCK_SIZE * HEAP_BUF_COUNT)
+
+/* Remaining DRAM for Stack, data and BSS.
+ * TODO: verify no overflow during build
+ */
+#define SYSTEM_MEM \
+ (DRAM0_SIZE - HEAP_MOD_SIZE - HEAP_BUF_SIZE)
+
+#endif
+#endif
diff --git a/src/library/include/platform/platform.h b/src/library/include/platform/platform.h
new file mode 100644
index 0000000..a429e84
--- /dev/null
+++ b/src/library/include/platform/platform.h
@@ -0,0 +1,54 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ * Keyon Jie <yang.jie(a)linux.intel.com>
+ */
+
+#ifndef __PLATFORM_HOST_PLATFORM_H__
+#define __PLATFORM_HOST_PLATFORM_H__
+
+#include <platform/shim.h>
+#include <platform/interrupt.h>
+#include <stdio.h>
+#include <stdlib.h>
+
+/* Host page size */
+#define HOST_PAGE_SIZE 4096
+
+/* Platform stream capabilities */
+#define PLATFORM_MAX_CHANNELS 4
+#define PLATFORM_MAX_STREAMS 5
+
+/* DMA channel drain timeout in microseconds */
+#define PLATFORM_DMA_TIMEOUT 1333
+
+/* IPC page data copy timeout */
+#define PLATFORM_IPC_DMA_TIMEOUT 2000
+
+
+#endif
diff --git a/src/library/include/platform/pmc.h b/src/library/include/platform/pmc.h
new file mode 100644
index 0000000..d54fc1c
--- /dev/null
+++ b/src/library/include/platform/pmc.h
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __PLATFORM_HOST_PMC_H__
+#define __PLATFORM_HOST_PMC_H__
+
+#include <stdint.h>
+
+
+int platform_ipc_pmc_init(void);
+int ipc_pmc_send_msg(uint32_t message);
+int pmc_process_msg_queue(void);
+
+#endif
diff --git a/src/library/include/platform/shim.h b/src/library/include/platform/shim.h
new file mode 100644
index 0000000..d6d94d4
--- /dev/null
+++ b/src/library/include/platform/shim.h
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+#ifndef __PLATFORM_HOST_SHIM_H__
+#define __PLATFORM_HOST_SHIM_H__
+
+#include <platform/memory.h>
+#include <stdint.h>
+
+static inline uint32_t shim_read(uint32_t reg) {return 0; }
+static inline void shim_write(uint32_t reg, uint32_t val) {}
+
+#endif
diff --git a/src/library/include/platform/timer.h b/src/library/include/platform/timer.h
new file mode 100644
index 0000000..3521e4c
--- /dev/null
+++ b/src/library/include/platform/timer.h
@@ -0,0 +1,54 @@
+/*
+ * Copyright (c) 2016, Intel Corporation
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of the Intel Corporation nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
+ */
+
+
+#ifndef __PLATFORM_HOST_TIMER_H__
+#define __PLATFORM_HOST_TIMER_H__
+
+#include <stdint.h>
+#include <reef/timer.h>
+#include <platform/interrupt.h>
+
+struct comp_dev;
+struct sof_ipc_stream_posn;
+
+/* get timestamp for host stream DMA position */
+static inline void platform_host_timestamp(struct comp_dev *host,
+ struct sof_ipc_stream_posn *posn) {}
+
+/* get timestamp for DAI stream DMA position */
+static inline void platform_dai_timestamp(struct comp_dev *dai,
+ struct sof_ipc_stream_posn *posn) {}
+
+/* get current wallclock for componnent */
+static inline void platform_dai_wallclock(struct comp_dev *dai,
+ uint64_t *wallclock) {}
+
+#endif
diff --git a/src/math/Makefile.am b/src/math/Makefile.am
index b795afa..6a48e29 100644
--- a/src/math/Makefile.am
+++ b/src/math/Makefile.am
@@ -1,11 +1,21 @@
-noinst_LIBRARIES = libmath.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_math.la
-libmath_a_SOURCES = \
+libsof_math_la_SOURCES = \
trig.c \
numbers.c
-libmath_a_CFLAGS = \
+libsof_math_la_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_math.a
+
+libsof_math_a_SOURCES = \
+ trig.c \
+ numbers.c
+
+libsof_math_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
--
2.11.0
1
1
[Sound-open-firmware] [PATCH] topology: test: fix m4 macro expansion for MCLK argument
by Pierre-Louis Bossart 16 Jan '18
by Pierre-Louis Bossart 16 Jan '18
16 Jan '18
M4 expands $10 as $1 followed by 0, so test .conf topology files contained
mclk_freq "codec0" instead of the expected value (e.g. 19200000).
Parenthesis are required when there are more than 9 arguments to a
macro...
Reported-by: "Wang, Yan" <yan.wang(a)intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart(a)linux.intel.com>
---
topology/test/tplg-build.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/topology/test/tplg-build.sh b/topology/test/tplg-build.sh
index 2392135..d322ce7 100755
--- a/topology/test/tplg-build.sh
+++ b/topology/test/tplg-build.sh
@@ -39,7 +39,7 @@ function simple_test {
-DTEST_SSP_FORMAT=$6 \
-DTEST_PIPE_FORMAT=$4 \
-DTEST_SSP_BCLK=$9 \
- -DTEST_SSP_MCLK=$10 \
+ -DTEST_SSP_MCLK=${10} \
-DTEST_SSP_PHY_BITS=$7 \
-DTEST_SSP_DATA_BITS=$8 \
$i.m4 > ${TFILE}.conf
--
2.14.1
2
1
[Sound-open-firmware] [PATCH] build: add library build support for host platform
by Ranjani Sridharan 12 Jan '18
by Ranjani Sridharan 12 Jan '18
12 Jan '18
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(a)linux.intel.com>
---
README | 7 +
build-all.sh | 6 +
configure.ac | 3 +
src/Makefile.am | 11 +
src/arch/host/include/Makefile.am | 1 +
src/arch/host/include/arch/Makefile.am | 8 +
src/audio/Makefile.am | 1005 +++++++++++++++++++++++++++++-
src/include/reef/Makefile.am | 4 +-
src/include/reef/audio/Makefile.am | 8 +-
src/include/uapi/Makefile.am | 2 +-
src/ipc/Makefile.am | 28 +-
src/library/include/platform/Makefile.am | 12 +
src/math/Makefile.am | 22 +-
13 files changed, 1096 insertions(+), 21 deletions(-)
create mode 100644 src/arch/host/include/Makefile.am
create mode 100644 src/arch/host/include/arch/Makefile.am
create mode 100644 src/library/include/platform/Makefile.am
diff --git a/README b/README
index 9ca5b12..463fc42 100644
--- a/README
+++ b/README
@@ -13,6 +13,13 @@ Cherrytrail :-
./configure --with-arch=xtensa --with-platform=cherrytrail --with-root-dir=$PWD/../xtensa-root/xtensa-byt-elf --host=xtensa-byt-elf
+Library for Host Platform :-
+If building library for host platform, run the following configure. Please modify
+the --prefix option to choose the directory for installing the library files and
+headers
+
+./configure --with-arch=host --enable-library=yes --host=x86_64-unknown-linux-gnu --prefix=$pwd/../host-root/
+
3) make
4) make bin
diff --git a/build-all.sh b/build-all.sh
index 2e015f6..a0ce575 100755
--- a/build-all.sh
+++ b/build-all.sh
@@ -9,6 +9,12 @@ pwd=`pwd`
rm -fr src/arch/xtensa/*.ri
+# build library for host platform architecture
+./configure --with-arch=host --enable-library=yes
+--host=x86_64-unknown-linux-gnu --prefix=$pwd/../host-root/
+make
+make install
+
# Build for Baytrail
./configure --with-arch=xtensa --with-platform=baytrail --with-root-dir=$pwd/../xtensa-root/xtensa-byt-elf --host=xtensa-byt-elf
make clean
diff --git a/configure.ac b/configure.ac
index 00c377f..6c559fc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -161,6 +161,9 @@ AC_CONFIG_FILES([
src/arch/xtensa/include/xtensa/config/Makefile
src/arch/xtensa/hal/Makefile
src/arch/xtensa/xtos/Makefile
+ src/arch/host/Makefile
+ src/arch/host/include/Makefile
+ src/arch/host/include/arch/Makefile
src/audio/Makefile
src/math/Makefile
src/drivers/Makefile
diff --git a/src/Makefile.am b/src/Makefile.am
index fb82330..8944a8d 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1 +1,12 @@
SUBDIRS = include init math audio platform tasks drivers ipc lib arch
+
+export COMMON_INCDIR = \
+ $(REEF_INCDIR) \
+ $(ARCH_INCDIR) \
+ $(PLATFORM_INCDIR)
+
+if BUILD_LIB
+SUBDIRS = ipc math audio arch include library
+else
+SUBDIRS = init math audio platform tasks drivers ipc lib arch include
+endif
diff --git a/src/arch/host/include/Makefile.am b/src/arch/host/include/Makefile.am
new file mode 100644
index 0000000..f0ac9b7
--- /dev/null
+++ b/src/arch/host/include/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = arch
diff --git a/src/arch/host/include/arch/Makefile.am b/src/arch/host/include/arch/Makefile.am
new file mode 100644
index 0000000..6dddb35
--- /dev/null
+++ b/src/arch/host/include/arch/Makefile.am
@@ -0,0 +1,8 @@
+includedir = $(prefix)/include/sof/arch
+
+include_HEADERS = \
+ cache.h \
+ interrupt.h \
+ reef.h \
+ spinlock.h \
+ timer.h
diff --git a/src/audio/Makefile.am b/src/audio/Makefile.am
index d19dff7..9441e7e 100644
--- a/src/audio/Makefile.am
+++ b/src/audio/Makefile.am
@@ -1,3 +1,1002 @@
+includedir = $(prefix)/include/sof/audio
+
+include_HEADERS = \
+ eq_iir.h \
+ eq_fir.h
+
+COMP_SRC = \
+ eq_iir.c \
+ iir.c \
+ eq_fir.c \
+ fir.c \
+ tone.c \
+ src.c \
+ src_core.c \
+ mixer.c \
+ mux.c \
+ volume.c \
+ switch.c \
+ dai.c \
+ host.c \
+ pipeline.c \
+ component.c \
+ buffer.c
+
+SOF_SRC = \
+ dai.c \
+ host.c \
+ pipeline.c \
+ component.c \
+ buffer.c
+
+SRC_SRC = \
+ src.c \
+ src_core.c
+
+EQ_FIR_SRC = \
+ eq_fir.c \
+ fir.c
+
+EQ_IIR_SRC = \
+ eq_iir.c \
+ iir.c
+
+if BUILD_LIB
+
+# only host builds shared libraries, the rest are static
+if BUILD_HOST
+
+# libsof
+lib_LTLIBRARIES = libsof.la
+
+libsof_la_SOURCES = $(SOF_SRC)
+
+libsof_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src.la
+
+libsof_src_la_SOURCES = $(SRC_SRC)
+
+libsof_src_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir.la
+
+libsof_eq_fir_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir.la
+
+libsof_eq_iir_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume.la
+
+libsof_volume_la_SOURCES = volume.c
+
+libsof_volume_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux.la
+
+libsof_mux_la_SOURCES = mux.c
+
+libsof_mux_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch.la
+
+libsof_switch_la_SOURCES = switch.c
+
+libsof_switch_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer.la
+
+libsof_mixer_la_SOURCES = mixer.c
+
+libsof_mixer_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone.la
+
+libsof_tone_la_SOURCES = tone.c
+
+libsof_tone_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+if HAVE_SSE42
+# libsof
+lib_LTLIBRARIES += libsof_sse42.la
+
+libsof_sse42_la_SOURCES = $(SOF_SRC)
+
+libsof_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_sse42.la
+
+libsof_src_sse42_la_SOURCES = $(SRC_SRC)
+
+libsof_src_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_sse42.la
+
+libsof_eq_fir_sse42_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_sse42.la
+
+libsof_eq_iir_sse42_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_sse42.la
+
+libsof_volume_sse42_la_SOURCES = volume.c
+
+libsof_volume_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_sse42.la
+
+libsof_mux_sse42_la_SOURCES = mux.c
+
+libsof_mux_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_sse42.la
+
+libsof_switch_sse42_la_SOURCES = switch.c
+
+libsof_switch_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_sse42.la
+
+libsof_mixer_sse42_la_SOURCES = mixer.c
+
+libsof_mixer_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_sse42.la
+
+libsof_tone_sse42_la_SOURCES = tone.c
+
+libsof_tone_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+endif
+
+if HAVE_AVX
+# libsof
+lib_LTLIBRARIES += libsof_avx.la
+
+libsof_avx_la_SOURCES = $(SOF_SRC)
+
+libsof_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx.la
+
+libsof_src_avx_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx.la
+
+libsof_eq_fir_avx_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx.la
+
+libsof_eq_iir_avx_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx.la
+
+libsof_volume_avx_la_SOURCES = volume.c
+
+libsof_volume_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx.la
+
+libsof_mux_avx_la_SOURCES = mux.c
+
+libsof_mux_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx.la
+
+libsof_switch_avx_la_SOURCES = switch.c
+
+libsof_switch_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx.la
+
+libsof_mixer_avx_la_SOURCES = mixer.c
+
+libsof_mixer_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx.la
+
+libsof_tone_avx_la_SOURCES = tone.c
+
+libsof_tone_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+endif
+
+if HAVE_AVX2
+# libsof
+lib_LTLIBRARIES += libsof_avx2.la
+
+libsof_avx2_la_SOURCES = $(SOF_SRC)
+
+libsof_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx2.la
+
+libsof_src_avx2_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx2.la
+
+libsof_eq_fir_avx2_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx2.la
+
+libsof_eq_iir_avx2_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx2.la
+
+libsof_volume_avx2_la_SOURCES = volume.c
+
+libsof_volume_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx2.la
+
+libsof_mux_avx2_la_SOURCES = mux.c
+
+libsof_mux_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx2.la
+
+libsof_switch_avx2_la_SOURCES = switch.c
+
+libsof_switch_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx2.la
+
+libsof_mixer_avx2_la_SOURCES = mixer.c
+
+libsof_mixer_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx2.la
+
+libsof_tone_avx2_la_SOURCES = tone.c
+
+libsof_tone_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+endif
+
+if HAVE_FMA
+# libsof
+lib_LTLIBRARIES += libsof_fma.la
+
+libsof_fma_la_SOURCES = $(SOF_SRC)
+
+libsof_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_fma.la
+
+libsof_src_fma_la_SOURCES = $(SRC_SRC)
+
+libsof_src_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_fma.la
+
+libsof_eq_fir_fma_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_fma.la
+
+libsof_eq_iir_fma_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_fma.la
+
+libsof_volume_fma_la_SOURCES = volume.c
+
+libsof_volume_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_fma.la
+
+libsof_mux_fma_la_SOURCES = mux.c
+
+libsof_mux_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_fma.la
+
+libsof_switch_fma_la_SOURCES = switch.c
+
+libsof_switch_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_fma.la
+
+libsof_mixer_fma_la_SOURCES = mixer.c
+
+libsof_mixer_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_fma.la
+
+libsof_tone_fma_la_SOURCES = tone.c
+
+libsof_tone_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+endif
+
+else
+
+# Build for non host targets
+
+# libsof
+lib_LIBRARIES = libsof.a
+
+libsof_a_SOURCES = $(SOF_SRC)
+
+libsof_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src.a
+
+libsof_src_a_SOURCES = $(SRC_SRC)
+
+libsof_src_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir.a
+
+libsof_eq_fir_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir.a
+
+libsof_eq_iir_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume.a
+
+libsof_volume_a_SOURCES = volume.c
+
+libsof_volume_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux.a
+
+libsof_mux_a_SOURCES = mux.c
+
+libsof_mux_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch.a
+
+libsof_switch_a_SOURCES = switch.c
+
+libsof_switch_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer.a
+
+libsof_mixer_a_SOURCES = mixer.c
+
+libsof_mixer_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone.a
+
+libsof_tone_a_SOURCES = tone.c
+
+libsof_tone_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+
+if HAVE_HIFI2EP
+# libsof
+lib_LIBRARIES += libsof_hifi2ep.a
+
+libsof_hifi2ep_a_SOURCES = $(SOF_SRC)
+
+libsof_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi2ep.a
+
+libsof_src_hifi2ep_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi2ep.a
+
+libsof_eq_fir_hifi2ep_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi2ep.a
+
+libsof_eq_iir_hifi2ep_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi2ep.a
+
+libsof_volume_hifi2ep_a_SOURCES = volume.c
+
+libsof_volume_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi2ep.a
+
+libsof_mux_hifi2ep_a_SOURCES = mux.c
+
+libsof_mux_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi2ep.a
+
+libsof_switch_hifi2ep_a_SOURCES = switch.c
+
+libsof_switch_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi2ep.a
+
+libsof_mixer_hifi2ep_a_SOURCES = mixer.c
+
+libsof_mixer_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi2ep.a
+
+libsof_tone_hifi2ep_a_SOURCES = tone.c
+
+libsof_tone_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
+
+if HAVE_HIFI3
+# libsof
+lib_LIBRARIES += libsof_hifi3.a
+
+libsof_hifi3_a_SOURCES = $(COMP_SRC)
+
+libsof_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi3.a
+
+libsof_src_hifi3_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi3.a
+
+libsof_eq_fir_hifi3_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi3.a
+
+libsof_eq_iir_hifi3_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi3.a
+
+libsof_volume_hifi3_a_SOURCES = volume.c
+
+libsof_volume_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi3.a
+
+libsof_mux_hifi3_a_SOURCES = mux.c
+
+libsof_mux_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi3.a
+
+libsof_switch_hifi3_a_SOURCES = switch.c
+
+libsof_switch_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi3.a
+
+libsof_mixer_hifi3_a_SOURCES = mixer.c
+
+libsof_mixer_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi3.a
+
+libsof_tone_hifi3_a_SOURCES = tone.c
+
+libsof_tone_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
+
+endif
+
+else
+
+# build for firmware image
+
noinst_LIBRARIES = libaudio.a
noinst_HEADERS = \
@@ -29,6 +1028,6 @@ libaudio_a_SOURCES = \
libaudio_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+endif
diff --git a/src/include/reef/Makefile.am b/src/include/reef/Makefile.am
index 3f90e90..31bd091 100644
--- a/src/include/reef/Makefile.am
+++ b/src/include/reef/Makefile.am
@@ -1,6 +1,8 @@
SUBDIRS = audio math
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef
+
+include_HEADERS = \
alloc.h \
clock.h \
dai.h \
diff --git a/src/include/reef/audio/Makefile.am b/src/include/reef/audio/Makefile.am
index 60b7145..1d2b9cb 100644
--- a/src/include/reef/audio/Makefile.am
+++ b/src/include/reef/audio/Makefile.am
@@ -1,7 +1,9 @@
SUBDIRS = coefficients
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef/audio
+
+include_HEADERS = \
component.h \
pipeline.h \
- buffer.h \
- format.h
+ format.h \
+ buffer.h
diff --git a/src/include/uapi/Makefile.am b/src/include/uapi/Makefile.am
index 103d692..f202eca 100644
--- a/src/include/uapi/Makefile.am
+++ b/src/include/uapi/Makefile.am
@@ -1,4 +1,4 @@
-includedir = $(prefix)/include/sof
+includedir = $(prefix)/include/sof/uapi
include_HEADERS = \
ipc.h \
diff --git a/src/ipc/Makefile.am b/src/ipc/Makefile.am
index 7e63ca6..9878273 100644
--- a/src/ipc/Makefile.am
+++ b/src/ipc/Makefile.am
@@ -1,7 +1,22 @@
-noinst_LIBRARIES = libipc.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_ipc.la
+
+libsof_ipc_la_SOURCES = \
+ ipc.c
+
+libsof_ipc_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+libsof_ipc_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_ipc.a
if BUILD_BAYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -10,7 +25,7 @@ libipc_a_SOURCES = \
endif
if BUILD_CHERRYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -18,9 +33,8 @@ libipc_a_SOURCES = \
dma-copy.c
endif
-libipc_a_CFLAGS = \
+libsof_ipc_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(ARCH_INCDIR) \
- $(REEF_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+endif
diff --git a/src/library/include/platform/Makefile.am b/src/library/include/platform/Makefile.am
new file mode 100644
index 0000000..5a735ae
--- /dev/null
+++ b/src/library/include/platform/Makefile.am
@@ -0,0 +1,12 @@
+includedir = $(prefix)/include/sof/platform
+
+include_HEADERS = \
+ clk.h \
+ dma.h \
+ interrupt.h \
+ mailbox.h \
+ memory.h \
+ platform.h \
+ pmc.h \
+ shim.h \
+ timer.h
diff --git a/src/math/Makefile.am b/src/math/Makefile.am
index b795afa..6a48e29 100644
--- a/src/math/Makefile.am
+++ b/src/math/Makefile.am
@@ -1,11 +1,21 @@
-noinst_LIBRARIES = libmath.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_math.la
-libmath_a_SOURCES = \
+libsof_math_la_SOURCES = \
trig.c \
numbers.c
-libmath_a_CFLAGS = \
+libsof_math_la_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_math.a
+
+libsof_math_a_SOURCES = \
+ trig.c \
+ numbers.c
+
+libsof_math_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
--
2.11.0
2
1
[Sound-open-firmware] [PATCH] build: dist: make sure agent.h is added to make dist.
by Liam Girdwood 11 Jan '18
by Liam Girdwood 11 Jan '18
11 Jan '18
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
src/include/reef/Makefile.am | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/include/reef/Makefile.am b/src/include/reef/Makefile.am
index 3f90e90..50ffada 100644
--- a/src/include/reef/Makefile.am
+++ b/src/include/reef/Makefile.am
@@ -1,6 +1,7 @@
SUBDIRS = audio math
noinst_HEADERS = \
+ agent.h \
alloc.h \
clock.h \
dai.h \
--
2.14.1
1
0
[Sound-open-firmware] [PATCHv2] build: fix version script to use correct version in tarball build
by Liam Girdwood 11 Jan '18
by Liam Girdwood 11 Jan '18
11 Jan '18
make sure the tarball build and worktree build uses the correct version.
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
version.sh | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/version.sh b/version.sh
index 1f57c53..4f25ecd 100755
--- a/version.sh
+++ b/version.sh
@@ -10,8 +10,8 @@ else
DIR=$1
fi
-# create git version if we are a git repo
-if [ ! -d $DIR/.git ]; then
+# create git version if we are a git repo or git worktree
+if [ -e $DIR/.git -o -d $DIR/.git ]; then
# version for make dist
git describe --abbrev=4 > $DIR/.version
git describe --abbrev=4 > $DIR/.tarball-version
@@ -19,7 +19,7 @@ if [ ! -d $DIR/.git ]; then
# git commit for IPC
echo "#define REEF_TAG \"`git log --pretty=format:\"%h\" -1 | cut -c1-5`\"" > $DIR/src/include/version.h
else
- echo "#define REEF_TAG 0" > $DIR/src/include/version.h
+ echo "#define REEF_TAG \"0\"" > $DIR/src/include/version.h
fi
# build counter
--
2.14.1
1
0
[Sound-open-firmware] [PATCH] build: fix version script to use correct version in tarball build
by Liam Girdwood 11 Jan '18
by Liam Girdwood 11 Jan '18
11 Jan '18
make sure the tarball build uses the correct version.
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
version.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/version.sh b/version.sh
index 1f57c53..33b1451 100755
--- a/version.sh
+++ b/version.sh
@@ -11,7 +11,7 @@ else
fi
# create git version if we are a git repo
-if [ ! -d $DIR/.git ]; then
+if [ -d $DIR/.git ]; then
# version for make dist
git describe --abbrev=4 > $DIR/.version
git describe --abbrev=4 > $DIR/.tarball-version
@@ -19,7 +19,7 @@ if [ ! -d $DIR/.git ]; then
# git commit for IPC
echo "#define REEF_TAG \"`git log --pretty=format:\"%h\" -1 | cut -c1-5`\"" > $DIR/src/include/version.h
else
- echo "#define REEF_TAG 0" > $DIR/src/include/version.h
+ echo "#define REEF_TAG \"0\"" > $DIR/src/include/version.h
fi
# build counter
--
2.14.1
1
0
11 Jan '18
Incorrect BCLK macro name used to specify MCLK. Fix.
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
topology/test/tplg-build.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/topology/test/tplg-build.sh b/topology/test/tplg-build.sh
index 71bb120..2392135 100755
--- a/topology/test/tplg-build.sh
+++ b/topology/test/tplg-build.sh
@@ -39,7 +39,7 @@ function simple_test {
-DTEST_SSP_FORMAT=$6 \
-DTEST_PIPE_FORMAT=$4 \
-DTEST_SSP_BCLK=$9 \
- -DTEST_SSP_BCLK=$10 \
+ -DTEST_SSP_MCLK=$10 \
-DTEST_SSP_PHY_BITS=$7 \
-DTEST_SSP_DATA_BITS=$8 \
$i.m4 > ${TFILE}.conf
--
2.14.1
1
0
[Sound-open-firmware] [PATCH v5] [host-1.0] library: split SOF library into separate component libraries
by Ranjani Sridharan 10 Jan '18
by Ranjani Sridharan 10 Jan '18
10 Jan '18
This patch enables creating a separate library per component and
a common library for pipeline, buffer etc
Signed-off-by: Ranjani Sridharan <ranjani.sridharan(a)linux.intel.com>
---
configure.ac | 1 +
src/Makefile.am | 7 +-
src/arch/host/include/Makefile.am | 1 +
src/arch/host/include/arch/Makefile.am | 8 +
src/audio/Makefile.am | 909 +++++++++++++++++++++++++++++--
src/include/reef/Makefile.am | 6 +-
src/include/reef/audio/Makefile.am | 5 +-
src/include/uapi/Makefile.am | 2 +-
src/ipc/Makefile.am | 28 +-
src/library/include/platform/Makefile.am | 4 +-
src/math/Makefile.am | 22 +-
11 files changed, 941 insertions(+), 52 deletions(-)
create mode 100644 src/arch/host/include/arch/Makefile.am
diff --git a/configure.ac b/configure.ac
index 925d450..a0ae651 100644
--- a/configure.ac
+++ b/configure.ac
@@ -243,6 +243,7 @@ AC_CONFIG_FILES([
src/arch/xtensa/xtos/Makefile
src/arch/host/Makefile
src/arch/host/include/Makefile
+ src/arch/host/include/arch/Makefile
src/audio/Makefile
src/math/Makefile
src/drivers/Makefile
diff --git a/src/Makefile.am b/src/Makefile.am
index 57c40e8..ed21692 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,5 +1,10 @@
+export COMMON_INCDIR = \
+ $(REEF_INCDIR) \
+ $(ARCH_INCDIR) \
+ $(PLATFORM_INCDIR)
+
if BUILD_LIB
-SUBDIRS = math audio arch include library
+SUBDIRS = ipc math audio arch include library
else
SUBDIRS = init math audio platform tasks drivers ipc lib arch include
endif
diff --git a/src/arch/host/include/Makefile.am b/src/arch/host/include/Makefile.am
index e69de29..f0ac9b7 100644
--- a/src/arch/host/include/Makefile.am
+++ b/src/arch/host/include/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = arch
diff --git a/src/arch/host/include/arch/Makefile.am b/src/arch/host/include/arch/Makefile.am
new file mode 100644
index 0000000..6dddb35
--- /dev/null
+++ b/src/arch/host/include/arch/Makefile.am
@@ -0,0 +1,8 @@
+includedir = $(prefix)/include/sof/arch
+
+include_HEADERS = \
+ cache.h \
+ interrupt.h \
+ reef.h \
+ spinlock.h \
+ timer.h
diff --git a/src/audio/Makefile.am b/src/audio/Makefile.am
index 4a2ee0f..b968c4b 100644
--- a/src/audio/Makefile.am
+++ b/src/audio/Makefile.am
@@ -1,3 +1,9 @@
+includedir = $(prefix)/include/sof/audio
+
+include_HEADERS = \
+ eq_iir.h \
+ eq_fir.h
+
COMP_SRC = \
eq_iir.c \
iir.c \
@@ -16,126 +22,885 @@ COMP_SRC = \
component.c \
buffer.c
+SOF_SRC = \
+ dai.c \
+ host.c \
+ pipeline.c \
+ component.c \
+ buffer.c
+
+SRC_SRC = \
+ src.c \
+ src_core.c
+
+EQ_FIR_SRC = \
+ eq_fir.c \
+ fir.c
+
+EQ_IIR_SRC = \
+ eq_iir.c \
+ iir.c
+
if BUILD_LIB
# only host builds shared libraries, the rest are static
if BUILD_HOST
+# libsof
lib_LTLIBRARIES = libsof.la
-libsof_la_SOURCES = $(COMP_SRC)
+libsof_la_SOURCES = $(SOF_SRC)
libsof_la_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+# libsof_src
+lib_LTLIBRARIES += libsof_src.la
+
+libsof_src_la_SOURCES = $(SRC_SRC)
+
+libsof_src_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir.la
+
+libsof_eq_fir_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir.la
+
+libsof_eq_iir_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume.la
+
+libsof_volume_la_SOURCES = volume.c
+
+libsof_volume_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux.la
+
+libsof_mux_la_SOURCES = mux.c
+
+libsof_mux_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch.la
+
+libsof_switch_la_SOURCES = switch.c
+
+libsof_switch_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer.la
+
+libsof_mixer_la_SOURCES = mixer.c
+
+libsof_mixer_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone.la
+
+libsof_tone_la_SOURCES = tone.c
+
+libsof_tone_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
if HAVE_SSE42
+# libsof
lib_LTLIBRARIES += libsof_sse42.la
-libsof_sse42_la_SOURCES = $(COMP_SRC)
+libsof_sse42_la_SOURCES = $(SOF_SRC)
libsof_sse42_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(SSE42_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_sse42_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_sse42.la
+
+libsof_src_sse42_la_SOURCES = $(SRC_SRC)
+
+libsof_src_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_sse42.la
+
+libsof_eq_fir_sse42_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_sse42.la
+
+libsof_eq_iir_sse42_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_sse42.la
+
+libsof_volume_sse42_la_SOURCES = volume.c
+
+libsof_volume_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_sse42.la
+
+libsof_mux_sse42_la_SOURCES = mux.c
+
+libsof_mux_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_sse42.la
+
+libsof_switch_sse42_la_SOURCES = switch.c
+
+libsof_switch_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_sse42.la
+
+libsof_mixer_sse42_la_SOURCES = mixer.c
+
+libsof_mixer_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_sse42.la
+
+libsof_tone_sse42_la_SOURCES = tone.c
+
+libsof_tone_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
endif
if HAVE_AVX
+# libsof
lib_LTLIBRARIES += libsof_avx.la
-libsof_avx_la_SOURCES = $(COMP_SRC)
+libsof_avx_la_SOURCES = $(SOF_SRC)
libsof_avx_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(AVX_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_avx_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx.la
+
+libsof_src_avx_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx.la
+
+libsof_eq_fir_avx_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx.la
+
+libsof_eq_iir_avx_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx.la
+
+libsof_volume_avx_la_SOURCES = volume.c
+
+libsof_volume_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx.la
+
+libsof_mux_avx_la_SOURCES = mux.c
+
+libsof_mux_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx.la
+
+libsof_switch_avx_la_SOURCES = switch.c
+
+libsof_switch_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx.la
+
+libsof_mixer_avx_la_SOURCES = mixer.c
+
+libsof_mixer_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx.la
+
+libsof_tone_avx_la_SOURCES = tone.c
+
+libsof_tone_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
endif
if HAVE_AVX2
+# libsof
lib_LTLIBRARIES += libsof_avx2.la
-libsof_avx2_la_SOURCES = $(COMP_SRC)
+libsof_avx2_la_SOURCES = $(SOF_SRC)
libsof_avx2_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(AVX2_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_avx2_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx2.la
+
+libsof_src_avx2_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx2.la
+
+libsof_eq_fir_avx2_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx2.la
+
+libsof_eq_iir_avx2_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx2.la
+
+libsof_volume_avx2_la_SOURCES = volume.c
+
+libsof_volume_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx2.la
+
+libsof_mux_avx2_la_SOURCES = mux.c
+
+libsof_mux_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx2.la
+
+libsof_switch_avx2_la_SOURCES = switch.c
+
+libsof_switch_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx2.la
+
+libsof_mixer_avx2_la_SOURCES = mixer.c
+
+libsof_mixer_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx2.la
+
+libsof_tone_avx2_la_SOURCES = tone.c
+
+libsof_tone_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
endif
if HAVE_FMA
+# libsof
lib_LTLIBRARIES += libsof_fma.la
-libsof_fma_la_SOURCES = $(COMP_SRC)
+libsof_fma_la_SOURCES = $(SOF_SRC)
libsof_fma_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(FMA_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_fma_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_fma.la
+
+libsof_src_fma_la_SOURCES = $(SRC_SRC)
+
+libsof_src_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_fma.la
+
+libsof_eq_fir_fma_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_fma.la
+
+libsof_eq_iir_fma_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_fma.la
+
+libsof_volume_fma_la_SOURCES = volume.c
+
+libsof_volume_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_fma.la
+
+libsof_mux_fma_la_SOURCES = mux.c
+
+libsof_mux_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_fma.la
+
+libsof_switch_fma_la_SOURCES = switch.c
+
+libsof_switch_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_fma.la
+
+libsof_mixer_fma_la_SOURCES = mixer.c
+
+libsof_mixer_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_fma.la
+
+libsof_tone_fma_la_SOURCES = tone.c
+
+libsof_tone_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
endif
else
# Build for non host targets
+# libsof
lib_LIBRARIES = libsof.a
-libsof_a_SOURCES = $(COMP_SRC)
+libsof_a_SOURCES = $(SOF_SRC)
libsof_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src.a
+
+libsof_src_a_SOURCES = $(SRC_SRC)
+
+libsof_src_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir.a
+
+libsof_eq_fir_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir.a
+
+libsof_eq_iir_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume.a
+
+libsof_volume_a_SOURCES = volume.c
+
+libsof_volume_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux.a
+
+libsof_mux_a_SOURCES = mux.c
+
+libsof_mux_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch.a
+
+libsof_switch_a_SOURCES = switch.c
+
+libsof_switch_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer.a
+
+libsof_mixer_a_SOURCES = mixer.c
+
+libsof_mixer_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone.a
+
+libsof_tone_a_SOURCES = tone.c
+
+libsof_tone_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
if HAVE_HIFI2EP
+# libsof
lib_LIBRARIES += libsof_hifi2ep.a
-libsof_hifi2ep_a_SOURCES = $(COMP_SRC)
+libsof_hifi2ep_a_SOURCES = $(SOF_SRC)
libsof_hifi2ep_a_CFLAGS = \
$(ARCH_CFLAGS) \
$(SSE42_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi2ep.a
+
+libsof_src_hifi2ep_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi2ep.a
+
+libsof_eq_fir_hifi2ep_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi2ep.a
+
+libsof_eq_iir_hifi2ep_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi2ep.a
+
+libsof_volume_hifi2ep_a_SOURCES = volume.c
+
+libsof_volume_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi2ep.a
+
+libsof_mux_hifi2ep_a_SOURCES = mux.c
+
+libsof_mux_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi2ep.a
+
+libsof_switch_hifi2ep_a_SOURCES = switch.c
+
+libsof_switch_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi2ep.a
+
+libsof_mixer_hifi2ep_a_SOURCES = mixer.c
+
+libsof_mixer_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi2ep.a
+
+libsof_tone_hifi2ep_a_SOURCES = tone.c
+
+libsof_tone_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
endif
if HAVE_HIFI3
+# libsof
lib_LIBRARIES += libsof_hifi3.a
libsof_hifi3_a_SOURCES = $(COMP_SRC)
@@ -143,9 +908,87 @@ libsof_hifi3_a_SOURCES = $(COMP_SRC)
libsof_hifi3_a_CFLAGS = \
$(ARCH_CFLAGS) \
$(SSE42_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi3.a
+
+libsof_src_hifi3_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi3.a
+
+libsof_eq_fir_hifi3_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi3.a
+
+libsof_eq_iir_hifi3_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi3.a
+
+libsof_volume_hifi3_a_SOURCES = volume.c
+
+libsof_volume_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi3.a
+
+libsof_mux_hifi3_a_SOURCES = mux.c
+
+libsof_mux_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi3.a
+
+libsof_switch_hifi3_a_SOURCES = switch.c
+
+libsof_switch_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi3.a
+
+libsof_mixer_hifi3_a_SOURCES = mixer.c
+
+libsof_mixer_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi3.a
+
+libsof_tone_hifi3_a_SOURCES = tone.c
+
+libsof_tone_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
endif
endif
@@ -177,8 +1020,6 @@ libaudio_a_SOURCES = \
libaudio_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
endif
diff --git a/src/include/reef/Makefile.am b/src/include/reef/Makefile.am
index f690e2a..d098036 100644
--- a/src/include/reef/Makefile.am
+++ b/src/include/reef/Makefile.am
@@ -1,13 +1,17 @@
SUBDIRS = audio
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef
+
+include_HEADERS = \
alloc.h \
clock.h \
dai.h \
debug.h \
dma.h \
+ dma-trace.h \
dw-dma.h \
init.h \
+ intel-ipc.h \
interrupt.h \
interrupt-map.h \
io.h \
diff --git a/src/include/reef/audio/Makefile.am b/src/include/reef/audio/Makefile.am
index b02684c..2e0e8d6 100644
--- a/src/include/reef/audio/Makefile.am
+++ b/src/include/reef/audio/Makefile.am
@@ -1,4 +1,7 @@
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef/audio
+
+include_HEADERS = \
component.h \
pipeline.h \
+ format.h \
buffer.h
diff --git a/src/include/uapi/Makefile.am b/src/include/uapi/Makefile.am
index 103d692..f202eca 100644
--- a/src/include/uapi/Makefile.am
+++ b/src/include/uapi/Makefile.am
@@ -1,4 +1,4 @@
-includedir = $(prefix)/include/sof
+includedir = $(prefix)/include/sof/uapi
include_HEADERS = \
ipc.h \
diff --git a/src/ipc/Makefile.am b/src/ipc/Makefile.am
index 7e63ca6..9878273 100644
--- a/src/ipc/Makefile.am
+++ b/src/ipc/Makefile.am
@@ -1,7 +1,22 @@
-noinst_LIBRARIES = libipc.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_ipc.la
+
+libsof_ipc_la_SOURCES = \
+ ipc.c
+
+libsof_ipc_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+libsof_ipc_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_ipc.a
if BUILD_BAYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -10,7 +25,7 @@ libipc_a_SOURCES = \
endif
if BUILD_CHERRYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -18,9 +33,8 @@ libipc_a_SOURCES = \
dma-copy.c
endif
-libipc_a_CFLAGS = \
+libsof_ipc_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(ARCH_INCDIR) \
- $(REEF_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+endif
diff --git a/src/library/include/platform/Makefile.am b/src/library/include/platform/Makefile.am
index 5775230..898867f 100644
--- a/src/library/include/platform/Makefile.am
+++ b/src/library/include/platform/Makefile.am
@@ -1,4 +1,6 @@
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/platform
+
+include_HEADERS = \
clk.h \
dma.h \
interrupt.h \
diff --git a/src/math/Makefile.am b/src/math/Makefile.am
index b795afa..6a48e29 100644
--- a/src/math/Makefile.am
+++ b/src/math/Makefile.am
@@ -1,11 +1,21 @@
-noinst_LIBRARIES = libmath.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_math.la
-libmath_a_SOURCES = \
+libsof_math_la_SOURCES = \
trig.c \
numbers.c
-libmath_a_CFLAGS = \
+libsof_math_la_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_math.a
+
+libsof_math_a_SOURCES = \
+ trig.c \
+ numbers.c
+
+libsof_math_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
--
2.11.0
2
1
10 Jan '18
make dist will now include the topology files.
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
configure.ac | 6 +++++-
topology/Makefile.am | 15 ++++++++++++++-
topology/common/Makefile.am | 3 +++
topology/dsps/Makefile.am | 7 +++++++
topology/m4/Makefile.am | 3 +++
topology/sof/Makefile.am | 14 ++++++++++++++
topology/test/Makefile.am | 9 +++++++++
7 files changed, 55 insertions(+), 2 deletions(-)
create mode 100644 topology/common/Makefile.am
create mode 100644 topology/dsps/Makefile.am
create mode 100644 topology/m4/Makefile.am
create mode 100644 topology/sof/Makefile.am
diff --git a/configure.ac b/configure.ac
index 1b4f59b..8c65760 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,6 +1,6 @@
AC_PREREQ([2.69])
-AC_INIT([rimage], [0.1])
+AC_INIT([sof-tools], [1.0.1])
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_SRCDIR([rimage/rimage.c])
AC_CONFIG_HEADERS([config.h])
@@ -17,6 +17,10 @@ AC_OUTPUT([
rimage/Makefile
rmbox/Makefile
topology/Makefile
+ topology/common/Makefile
+ topology/dsps/Makefile
+ topology/m4/Makefile
+ topology/sof/Makefile
topology/test/Makefile
])
diff --git a/topology/Makefile.am b/topology/Makefile.am
index 3cbc5e6..3b5a3a9 100644
--- a/topology/Makefile.am
+++ b/topology/Makefile.am
@@ -3,7 +3,7 @@
# Dependencies
#
-SUBDIRS = test
+SUBDIRS = test m4 sof common dsps
DEPS = \
dsps/*.m4 \
@@ -44,3 +44,16 @@ clean:
rm -f *.conf
rm -f *.tplg
+EXTRA_DIST = \
+ reef-cht-nocodec.m4 \
+ reef-cht-max98090.m4 \
+ reef-apl-nocodec.m4 \
+ reef-bxt-nocodec.m4 \
+ reef-byt-nocodec.m4 \
+ reef-bdw-rt286.m4 \
+ reef-bdw-rt5640.m4 \
+ reef-byt-rt5640.m4 \
+ reef-byt-rt5645.m4 \
+ reef-byt-rt5651.m4 \
+ reef-byt-da7212.m4 \
+ reef-hsw-rt5640.m4
diff --git a/topology/common/Makefile.am b/topology/common/Makefile.am
new file mode 100644
index 0000000..980f0ce
--- /dev/null
+++ b/topology/common/Makefile.am
@@ -0,0 +1,3 @@
+EXTRA_DIST = \
+ tlv.m4
+
diff --git a/topology/dsps/Makefile.am b/topology/dsps/Makefile.am
new file mode 100644
index 0000000..9bbade7
--- /dev/null
+++ b/topology/dsps/Makefile.am
@@ -0,0 +1,7 @@
+EXTRA_DIST = \
+ bdw.m4 \
+ bxt.m4 \
+ byt.m4 \
+ cht.m4 \
+ hsw.m4
+
diff --git a/topology/m4/Makefile.am b/topology/m4/Makefile.am
new file mode 100644
index 0000000..35b3f81
--- /dev/null
+++ b/topology/m4/Makefile.am
@@ -0,0 +1,3 @@
+EXTRA_DIST = \
+ build.m4 \
+ local.m4
diff --git a/topology/sof/Makefile.am b/topology/sof/Makefile.am
new file mode 100644
index 0000000..fc92591
--- /dev/null
+++ b/topology/sof/Makefile.am
@@ -0,0 +1,14 @@
+EXTRA_DIST = \
+ pipe-dai-capture.m4 \
+ pipe-dai-playback.m4 \
+ pipe-low-latency-capture.m4 \
+ pipe-low-latency-playback.m4 \
+ pipe-passthrough-capture.m4 \
+ pipe-passthrough-playback.m4 \
+ pipe-pcm-media.m4 \
+ pipe-src-capture.m4 \
+ pipe-src-playback.m4 \
+ pipe-tone.m4 \
+ pipe-volume-capture.m4 \
+ pipe-volume-playback.m4 \
+ tokens.m4
diff --git a/topology/test/Makefile.am b/topology/test/Makefile.am
index 7da075d..49f2240 100644
--- a/topology/test/Makefile.am
+++ b/topology/test/Makefile.am
@@ -3,6 +3,8 @@
# Dependencies
#
+
+
DEPS = \
../dsps/*.m4 \
../common/*.m4 \
@@ -18,3 +20,10 @@ all : *.m4 ${DEPS}
clean:
rm -f *.conf
rm -f *.tplg
+
+
+EXTRA_DIST = \
+ test-capture-ssp.m4 \
+ test-playback-ssp.m4 \
+ test-ssp.m4 \
+ tplg-build.sh
--
2.14.1
1
0
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index a47a714..00c377f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
AC_PREREQ([2.69])
-AC_INIT([Reef],[m4_esyscmd(./version.sh)],[sound-open-firmware(a)alsa-project.org])
+AC_INIT([sof],[m4_esyscmd(./version.sh)],[sound-open-firmware(a)alsa-project.org])
AC_CONFIG_SRCDIR([src/init/init.c])
AC_CONFIG_HEADERS([src/include/config.h])
AC_CONFIG_MACRO_DIRS([m4])
--
2.14.1
1
0
10 Jan '18
The mclk may be different for different platforms, here make it
configurable for test topology files.
Signed-off-by: Keyon Jie <yang.jie(a)linux.intel.com>
---
topology/test/test-capture-ssp.m4 | 3 ++-
topology/test/test-playback-ssp.m4 | 3 ++-
topology/test/test-ssp.m4 | 3 ++-
topology/test/tplg-build.sh | 43 ++++++++++++++++++++++----------------
4 files changed, 31 insertions(+), 21 deletions(-)
diff --git a/topology/test/test-capture-ssp.m4 b/topology/test/test-capture-ssp.m4
index 613e666..2c808ba 100644
--- a/topology/test/test-capture-ssp.m4
+++ b/topology/test/test-capture-ssp.m4
@@ -23,6 +23,7 @@ include(`dsps/byt.m4')
# TEST_SSP_PORT - SSP port number e.g. 2
# TEST_SSP_FORMAT - SSP data format e.g s16le
# TEST_PIPE_FORMAT - Pipeline format e.g. s16le
+# TEST_SSP_MCLK - SSP MCLK in Hz
# TEST_SSP_BCLK - SSP BCLK in Hz
# TEST_SSP_PHY_BITS - SSP physical slot size
# TEST_SSP_DATA_BITS - SSP data slot size
@@ -66,7 +67,7 @@ PCM_CAPTURE_ADD(Passthrough, 3, 0, 0, PIPELINE_PCM_2)
# TEST_SSP_DATA_BITS bit I2S using TEST_SSP_PHY_BITS bit sample conatiner on SSP TEST_SSP_PORT
#
DAI_CONFIG(SSP, TEST_SSP_PORT, TEST_DAI_LINK_NAME, I2S, TEST_SSP_DATA_BITS,
- DAI_CLOCK(mclk, 19200000, slave),
+ DAI_CLOCK(mclk, TEST_SSP_MCLK, slave),
DAI_CLOCK(bclk, TEST_SSP_BCLK, slave),
DAI_CLOCK(fsync, 48000, slave),
DAI_TDM(2, TEST_SSP_PHY_BITS, 3, 3))
diff --git a/topology/test/test-playback-ssp.m4 b/topology/test/test-playback-ssp.m4
index 351b8af..093ad17 100644
--- a/topology/test/test-playback-ssp.m4
+++ b/topology/test/test-playback-ssp.m4
@@ -23,6 +23,7 @@ include(`dsps/byt.m4')
# TEST_SSP_PORT - SSP port number e.g. 2
# TEST_SSP_FORMAT - SSP data format e.g s16le
# TEST_PIPE_FORMAT - Pipeline format e.g. s16le
+# TEST_SSP_MCLK - SSP MCLK in Hz
# TEST_SSP_BCLK - SSP BCLK in Hz
# TEST_SSP_PHY_BITS - SSP physical slot size
# TEST_SSP_DATA_BITS - SSP data slot size
@@ -66,7 +67,7 @@ PCM_PLAYBACK_ADD(Passthrough, 3, 0, 0, PIPELINE_PCM_1)
# TEST_SSP_DATA_BITS bit I2S using TEST_SSP_PHY_BITS bit sample conatiner on SSP TEST_SSP_PORT
#
DAI_CONFIG(SSP, TEST_SSP_PORT, TEST_DAI_LINK_NAME, I2S, TEST_SSP_DATA_BITS,
- DAI_CLOCK(mclk, 19200000, slave),
+ DAI_CLOCK(mclk, TEST_SSP_MCLK, slave),
DAI_CLOCK(bclk, TEST_SSP_BCLK, slave),
DAI_CLOCK(fsync, 48000, slave),
DAI_TDM(2, TEST_SSP_PHY_BITS, 3, 3))
diff --git a/topology/test/test-ssp.m4 b/topology/test/test-ssp.m4
index 92e91bf..304aab9 100644
--- a/topology/test/test-ssp.m4
+++ b/topology/test/test-ssp.m4
@@ -23,6 +23,7 @@ include(`dsps/byt.m4')
# TEST_SSP_PORT - SSP port number e.g. 2
# TEST_SSP_FORMAT - SSP data format e.g s16le
# TEST_PIPE_FORMAT - Pipeline format e.g. s16le
+# TEST_SSP_MCLK - SSP BCLK in Hz
# TEST_SSP_BCLK - SSP BCLK in Hz
# TEST_SSP_PHY_BITS - SSP physical slot size
# TEST_SSP_DATA_BITS - SSP data slot size
@@ -84,7 +85,7 @@ PCM_DUPLEX_ADD(Passthrough, 3, 0, 0, PIPELINE_PCM_1, PIPELINE_PCM_2)
# TEST_SSP_DATA_BITS bit I2S using TEST_SSP_PHY_BITS bit sample conatiner on SSP TEST_SSP_PORT
#
DAI_CONFIG(SSP, TEST_SSP_PORT, TEST_DAI_LINK_NAME, I2S, TEST_SSP_DATA_BITS,
- DAI_CLOCK(mclk, 19200000, slave),
+ DAI_CLOCK(mclk, TEST_SSP_MCLK, slave),
DAI_CLOCK(bclk, TEST_SSP_BCLK, slave),
DAI_CLOCK(fsync, 48000, slave),
DAI_TDM(2, TEST_SSP_PHY_BITS, 3, 3))
diff --git a/topology/test/tplg-build.sh b/topology/test/tplg-build.sh
index 5d7cd49..71bb120 100755
--- a/topology/test/tplg-build.sh
+++ b/topology/test/tplg-build.sh
@@ -25,6 +25,7 @@ SIMPLE_TESTS=(test-ssp test-capture-ssp test-playback-ssp)
# 7) dai_phy_bits - SSP physical number of BLKCs per slot/channel
# 8) dai_data_bits - SSP number of valid daat bits per slot/channel
# 9) dai_bclk - SSP BCLK in HZ
+# 10) dai_mclk - SSP MCLK in HZ
#
function simple_test {
for i in ${SIMPLE_TESTS[@]}
@@ -38,6 +39,7 @@ function simple_test {
-DTEST_SSP_FORMAT=$6 \
-DTEST_PIPE_FORMAT=$4 \
-DTEST_SSP_BCLK=$9 \
+ -DTEST_SSP_BCLK=$10 \
-DTEST_SSP_PHY_BITS=$7 \
-DTEST_SSP_DATA_BITS=$8 \
$i.m4 > ${TFILE}.conf
@@ -47,23 +49,28 @@ function simple_test {
}
# Pre-process the simple tests
-simple_test nocodec passthrough "NoCodec" s16le 2 s16le 20 16 1920000
-simple_test nocodec passthrough "NoCodec" s24le 2 s24le 25 24 2400000
-simple_test nocodec volume "NoCodec" s16le 2 s16le 20 16 1920000
-simple_test nocodec volume "NoCodec" s24le 2 s24le 25 24 2400000
-simple_test nocodec volume "NoCodec" s16le 2 s24le 25 24 2400000
-simple_test nocodec src "NoCodec" s24le 2 s24le 25 24 2400000
+simple_test nocodec passthrough "NoCodec" s16le 2 s16le 20 16 1920000 19200000
+simple_test nocodec passthrough "NoCodec" s24le 2 s24le 25 24 2400000 19200000
+simple_test nocodec volume "NoCodec" s16le 2 s16le 20 16 1920000 19200000
+simple_test nocodec volume "NoCodec" s24le 2 s24le 25 24 2400000 19200000
+simple_test nocodec volume "NoCodec" s16le 2 s24le 25 24 2400000 19200000
+simple_test nocodec src "NoCodec" s24le 2 s24le 25 24 2400000 19200000
+
+simple_test codec passthrough "SSP2-Codec" s16le 2 s16le 20 16 1920000 19200000
+simple_test codec passthrough "SSP2-Codec" s24le 2 s24le 25 24 2400000 19200000
+simple_test codec volume "SSP2-Codec" s16le 2 s16le 20 16 1920000 19200000
+simple_test codec volume "SSP2-Codec" s24le 2 s24le 25 24 2400000 19200000
+simple_test codec volume "SSP2-Codec" s16le 2 s24le 25 24 2400000 19200000
+simple_test codec src "SSP2-Codec" s24le 2 s24le 25 24 2400000 19200000
+
+simple_test baytrail passthrough "Baytrail Audio" s16le 2 s16le 20 16 1920000 19200000
+simple_test baytrail passthrough "Baytrail Audio" s24le 2 s24le 25 24 2400000 19200000
+simple_test baytrail volume "Baytrail Audio" s16le 2 s16le 20 16 1920000 19200000
+simple_test baytrail volume "Baytrail Audio" s24le 2 s24le 25 24 2400000 19200000
+simple_test baytrail volume "Baytrail Audio" s16le 2 s24le 25 24 2400000 19200000
+simple_test baytrail src "Baytrail Audio" s24le 2 s24le 25 24 2400000 19200000
+
+simple_test nocodec passthrough "NoCodec" s16le 4 s16le 16 16 1536000 24576000
+simple_test apollolake passthrough "SSP4-Codec" s16le 4 s16le 16 16 1536000 24576000
-simple_test codec passthrough "SSP2-Codec" s16le 2 s16le 20 16 1920000
-simple_test codec passthrough "SSP2-Codec" s24le 2 s24le 25 24 2400000
-simple_test codec volume "SSP2-Codec" s16le 2 s16le 20 16 1920000
-simple_test codec volume "SSP2-Codec" s24le 2 s24le 25 24 2400000
-simple_test codec volume "SSP2-Codec" s16le 2 s24le 25 24 2400000
-simple_test codec src "SSP2-Codec" s24le 2 s24le 25 24 2400000
-simple_test baytrail passthrough "Baytrail Audio" s16le 2 s16le 20 16 1920000
-simple_test baytrail passthrough "Baytrail Audio" s24le 2 s24le 25 24 2400000
-simple_test baytrail volume "Baytrail Audio" s16le 2 s16le 20 16 1920000
-simple_test baytrail volume "Baytrail Audio" s24le 2 s24le 25 24 2400000
-simple_test baytrail volume "Baytrail Audio" s16le 2 s24le 25 24 2400000
-simple_test baytrail src "Baytrail Audio" s24le 2 s24le 25 24 2400000
--
2.11.0
2
1
[Sound-open-firmware] [PATCH] build: version Add micro version to supporting versioning stable releases
by Liam Girdwood 10 Jan '18
by Liam Girdwood 10 Jan '18
10 Jan '18
Currently SOF is version as x.y. Add a z so that the version is x.y.z and
can represent different stable versions.
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
configure.ac | 2 ++
version.sh | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 5ade40b..a47a714 100644
--- a/configure.ac
+++ b/configure.ac
@@ -11,8 +11,10 @@ AM_MAINTAINER_MODE([enable])
# get version info from git
m4_define(reef_major, `cat .version | cut -dv -f2 | cut -d. -f1`)
m4_define(reef_minor, `cat .version | cut -d. -f2 | cut -d- -f1`)
+m4_define(reef_micro, `cat .version | cut -d. -f3 | cut -d- -f1`)
AC_DEFINE_UNQUOTED([REEF_MAJOR], reef_major, [Reef major version])
AC_DEFINE_UNQUOTED([REEF_MINOR], reef_minor, [Reef minor version])
+AC_DEFINE_UNQUOTED([REEF_MICRO], reef_micro, [Reef micro version])
AC_CANONICAL_HOST
diff --git a/version.sh b/version.sh
index fb5f3e4..1f57c53 100755
--- a/version.sh
+++ b/version.sh
@@ -35,5 +35,5 @@ echo "#define REEF_BUILD $num" >> $DIR/src/include/version.h
#echo version for AC_INIT
if [ -e $DIR/.version ]; then
- echo -n `cat $DIR/.version | cut -dv -f2 | cut -d. -f1`.`cat $DIR/.version | cut -d. -f2 | cut -d- -f1`
+ echo -n `cat $DIR/.version | cut -dv -f2 | cut -d. -f1`.`cat $DIR/.version | cut -d. -f2 | cut -d- -f1`.`cat $DIR/.version | cut -d. -f3 | cut -d- -f1`
fi
--
2.14.1
1
0
[Sound-open-firmware] [PATCH] build: fix install and dist build targets.
by Liam Girdwood 10 Jan '18
by Liam Girdwood 10 Jan '18
10 Jan '18
Make install/dist were missing some headers files and dirs. Add them and
make sure version generation works for building from the dist directory
where there is no git versioning information available.
Signed-off-by: Liam Girdwood <liam.r.girdwood(a)linux.intel.com>
---
Makefile.am | 9 ++--
configure.ac | 8 ++-
git-version.sh | 24 ---------
src/Makefile.am | 2 +-
src/arch/xtensa/Makefile.am | 5 +-
src/arch/xtensa/hal/Makefile.am | 2 +-
src/arch/xtensa/include/Makefile.am | 13 +----
src/arch/xtensa/include/arch/Makefile.am | 7 +++
src/arch/xtensa/include/xtensa/Makefile.am | 33 ++++++++++++
src/arch/xtensa/include/xtensa/config/Makefile.am | 2 +
src/arch/xtensa/xtos/Makefile.am | 11 +++-
src/audio/Makefile.am | 8 +++
src/include/Makefile.am | 7 +++
src/include/reef/Makefile.am | 4 +-
src/include/reef/audio/Makefile.am | 5 +-
src/include/reef/audio/coefficients/Makefile.am | 1 +
.../reef/audio/coefficients/src/Makefile.am | 58 ++++++++++++++++++++++
src/include/reef/math/Makefile.am | 3 ++
src/platform/baytrail/Makefile.am | 2 +
.../baytrail/include/xtensa/config/Makefile.am | 2 +
version.sh | 39 +++++++++++++++
21 files changed, 195 insertions(+), 50 deletions(-)
delete mode 100755 git-version.sh
create mode 100644 src/arch/xtensa/include/arch/Makefile.am
create mode 100644 src/arch/xtensa/include/xtensa/Makefile.am
create mode 100644 src/arch/xtensa/include/xtensa/config/Makefile.am
create mode 100644 src/include/reef/audio/coefficients/Makefile.am
create mode 100644 src/include/reef/audio/coefficients/src/Makefile.am
create mode 100644 src/include/reef/math/Makefile.am
create mode 100755 version.sh
diff --git a/Makefile.am b/Makefile.am
index 362e2bd..c05f042 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2,6 +2,8 @@ SUBDIRS = src
ACLOCAL_AMFLAGS = -I m4
+EXTRA_DIST = version.sh
+
SRC_DIR = $(abs_top_builddir)/src
export REEF_INCDIR = \
@@ -15,13 +17,8 @@ export ARCH_INCDIR = \
export PLATFORM_INCDIR = \
-I $(SRC_DIR)/platform/$(PLATFORM)/include
-BUILT_SOURCES = $(top_srcdir)/src/include/version.h
-
-$(top_srcdir)/src/include/version.h: Makefile
- ./git-version.sh
-
dist-hook:
- ./git-version.sh
+ ./version.sh $(top_srcdir)
cat .version > $(distdir)/.tarball-version
cat .version > $(distdir)/.version
diff --git a/configure.ac b/configure.ac
index 44ede24..5ade40b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
AC_PREREQ([2.69])
-AC_INIT([Reef],[m4_esyscmd(./git-version.sh)],[sound-open-firmware(a)alsa-project.org])
+AC_INIT([Reef],[m4_esyscmd(./version.sh)],[sound-open-firmware(a)alsa-project.org])
AC_CONFIG_SRCDIR([src/init/init.c])
AC_CONFIG_HEADERS([src/include/config.h])
AC_CONFIG_MACRO_DIRS([m4])
@@ -154,6 +154,9 @@ AC_CONFIG_FILES([
src/arch/Makefile
src/arch/xtensa/Makefile
src/arch/xtensa/include/Makefile
+ src/arch/xtensa/include/arch/Makefile
+ src/arch/xtensa/include/xtensa/Makefile
+ src/arch/xtensa/include/xtensa/config/Makefile
src/arch/xtensa/hal/Makefile
src/arch/xtensa/xtos/Makefile
src/audio/Makefile
@@ -162,6 +165,9 @@ AC_CONFIG_FILES([
src/include/Makefile
src/include/reef/Makefile
src/include/reef/audio/Makefile
+ src/include/reef/audio/coefficients/Makefile
+ src/include/reef/audio/coefficients/src/Makefile
+ src/include/reef/math/Makefile
src/include/uapi/Makefile
src/ipc/Makefile
src/lib/Makefile
diff --git a/git-version.sh b/git-version.sh
deleted file mode 100755
index 1c2d275..0000000
--- a/git-version.sh
+++ /dev/null
@@ -1,24 +0,0 @@
-
-# version for configure
-# echo -n `git describe --abbrev=4`
-
-# version for make dist
-git describe --abbrev=4 > .version
-git describe --abbrev=4 > .tarball-version
-
-# git commit for IPC
-echo "#define REEF_TAG \"`git log --pretty=format:\"%h\" -1 | cut -c1-5`\"" > src/include/version.h
-
-# build counter
-if [ -e .build ]; then
- num=$((`cat .build` + 1))
-else
- num=0
-fi
-
-# save and insert build counter
-echo $num > .build
-echo "#define REEF_BUILD $num" >> src/include/version.h
-
-#echo version for AC_INIT
-echo -n `cat .version | cut -dv -f2 | cut -d. -f1`:`cat .version | cut -d. -f2 | cut -d- -f1`
diff --git a/src/Makefile.am b/src/Makefile.am
index c2cc8f1..fb82330 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1 +1 @@
-SUBDIRS = init math audio platform tasks drivers ipc lib arch
+SUBDIRS = include init math audio platform tasks drivers ipc lib arch
diff --git a/src/arch/xtensa/Makefile.am b/src/arch/xtensa/Makefile.am
index 828db91..00f6b68 100644
--- a/src/arch/xtensa/Makefile.am
+++ b/src/arch/xtensa/Makefile.am
@@ -1,6 +1,6 @@
SUBDIRS = hal xtos include
-bin_PROGRAMS = \
+noinst_PROGRAMS = \
reef
# generate linker script from platform headers
@@ -79,3 +79,6 @@ vminstall-local:
clean-local:
rm -f reef-*.bin
+ rm -fr *.lst
+ rm -fr *.map
+ rm -fr *.dis
diff --git a/src/arch/xtensa/hal/Makefile.am b/src/arch/xtensa/hal/Makefile.am
index ad87877..e1e7a80 100644
--- a/src/arch/xtensa/hal/Makefile.am
+++ b/src/arch/xtensa/hal/Makefile.am
@@ -134,7 +134,7 @@ PLATFORM_DEFS = \
$(CACHE_DEFS)
endif
-lib_LIBRARIES = libhal.a
+noinst_LIBRARIES = libhal.a
libhal_a_SOURCES = \
attribute.c \
diff --git a/src/arch/xtensa/include/Makefile.am b/src/arch/xtensa/include/Makefile.am
index f114582..b2e07bf 100644
--- a/src/arch/xtensa/include/Makefile.am
+++ b/src/arch/xtensa/include/Makefile.am
@@ -1,12 +1 @@
-noinst_HEADERS = \
- xtensa/cacheasm.h \
- xtensa/coreasm.h \
- xtensa/corebits.h \
- xtensa/hal.h \
- xtensa/xtensa-xer.h \
- xtensa/config/core.h \
- arch/interrupt.h \
- arch/reef.h \
- arch/spinlock.h \
- arch/timer.h \
- arch/task.h
+SUBDIRS = arch xtensa
diff --git a/src/arch/xtensa/include/arch/Makefile.am b/src/arch/xtensa/include/arch/Makefile.am
new file mode 100644
index 0000000..d8ba0df
--- /dev/null
+++ b/src/arch/xtensa/include/arch/Makefile.am
@@ -0,0 +1,7 @@
+noinst_HEADERS = \
+ cache.h \
+ interrupt.h \
+ reef.h \
+ spinlock.h \
+ task.h \
+ timer.h
diff --git a/src/arch/xtensa/include/xtensa/Makefile.am b/src/arch/xtensa/include/xtensa/Makefile.am
new file mode 100644
index 0000000..8fd532d
--- /dev/null
+++ b/src/arch/xtensa/include/xtensa/Makefile.am
@@ -0,0 +1,33 @@
+noinst_HEADERS = \
+ board.h \
+ config \
+ hal.h \
+ overlay.h \
+ trax-api.h \
+ trax-proto.h \
+ xdm-regs.h \
+ xtensa-versions.h \
+ xtruntime.h \
+ c6x-compat.h \
+ coreasm.h \
+ overlay_os_asm.h \
+ trax-core-config.h \
+ traxreg.h \
+ xmon.h \
+ xtensa-xer.h \
+ cacheasm.h \
+ corebits.h \
+ simboard.h \
+ traxfile.h \
+ trax-util.h \
+ xtbsp.h \
+ xtruntime-core-state.h \
+ cacheattrasm.h \
+ core-macros.h \
+ specreg.h \
+ trax.h \
+ uart-16550.h \
+ xtensa-libdb-macros.h \
+ xtruntime-frames.h
+
+SUBDIRS = config
diff --git a/src/arch/xtensa/include/xtensa/config/Makefile.am b/src/arch/xtensa/include/xtensa/config/Makefile.am
new file mode 100644
index 0000000..69f1b8a
--- /dev/null
+++ b/src/arch/xtensa/include/xtensa/config/Makefile.am
@@ -0,0 +1,2 @@
+noinst_HEADERS = \
+ core.h
diff --git a/src/arch/xtensa/xtos/Makefile.am b/src/arch/xtensa/xtos/Makefile.am
index 6bf882e..9fff986 100644
--- a/src/arch/xtensa/xtos/Makefile.am
+++ b/src/arch/xtensa/xtos/Makefile.am
@@ -1,4 +1,11 @@
-lib_LIBRARIES = \
+noinst_HEADERS = \
+ xtos-internal.h \
+ xtos-params.h \
+ interrupt-pri.h \
+ window-vectors-new.S \
+ int-medpri-dispatcher.S
+
+noinst_LIBRARIES = \
libxtos.a \
libxlevel2.a \
libxlevel3.a \
@@ -26,7 +33,7 @@ endif
if BUILD_APOLLOLAKE
PLATFORM_DEFS = $(VECTOR_DEFS)
-lib_LIBRARIES += libxlevel6.a
+noinst_LIBRARIES += libxlevel6.a
VECTOR_DEFS += -D__SPLIT__level6
endif
diff --git a/src/audio/Makefile.am b/src/audio/Makefile.am
index 285422e..d19dff7 100644
--- a/src/audio/Makefile.am
+++ b/src/audio/Makefile.am
@@ -1,5 +1,13 @@
noinst_LIBRARIES = libaudio.a
+noinst_HEADERS = \
+ eq_fir.h \
+ eq_iir.h \
+ fir.h \
+ iir.h \
+ src_config.h \
+ src_core.h
+
libaudio_a_SOURCES = \
eq_iir.c \
iir.c \
diff --git a/src/include/Makefile.am b/src/include/Makefile.am
index 49f8bbf..a42403b 100644
--- a/src/include/Makefile.am
+++ b/src/include/Makefile.am
@@ -1 +1,8 @@
SUBDIRS = reef uapi
+
+version.h:
+ $(top_srcdir)/version.sh $(top_srcdir)
+
+noinst_HEADERS = \
+ config.h \
+ version.h
diff --git a/src/include/reef/Makefile.am b/src/include/reef/Makefile.am
index f690e2a..3f90e90 100644
--- a/src/include/reef/Makefile.am
+++ b/src/include/reef/Makefile.am
@@ -1,4 +1,4 @@
-SUBDIRS = audio
+SUBDIRS = audio math
noinst_HEADERS = \
alloc.h \
@@ -6,8 +6,10 @@ noinst_HEADERS = \
dai.h \
debug.h \
dma.h \
+ dma-trace.h \
dw-dma.h \
init.h \
+ intel-ipc.h \
interrupt.h \
interrupt-map.h \
io.h \
diff --git a/src/include/reef/audio/Makefile.am b/src/include/reef/audio/Makefile.am
index b02684c..60b7145 100644
--- a/src/include/reef/audio/Makefile.am
+++ b/src/include/reef/audio/Makefile.am
@@ -1,4 +1,7 @@
+SUBDIRS = coefficients
+
noinst_HEADERS = \
component.h \
pipeline.h \
- buffer.h
+ buffer.h \
+ format.h
diff --git a/src/include/reef/audio/coefficients/Makefile.am b/src/include/reef/audio/coefficients/Makefile.am
new file mode 100644
index 0000000..af437a6
--- /dev/null
+++ b/src/include/reef/audio/coefficients/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = src
diff --git a/src/include/reef/audio/coefficients/src/Makefile.am b/src/include/reef/audio/coefficients/src/Makefile.am
new file mode 100644
index 0000000..ca30972
--- /dev/null
+++ b/src/include/reef/audio/coefficients/src/Makefile.am
@@ -0,0 +1,58 @@
+noinst_HEADERS = \
+ src_small_int24_1_2_4375_5000.h \
+ src_small_int24_1_3_2188_5000.h \
+ src_small_int24_1_3_4375_5000.h \
+ src_small_int24_20_21_4020_5000.h \
+ src_small_int24_21_20_4020_5000.h \
+ src_small_int24_2_1_4375_5000.h \
+ src_small_int24_2_3_4375_5000.h \
+ src_small_int24_3_1_2188_5000.h \
+ src_small_int24_3_1_4375_5000.h \
+ src_small_int24_3_2_4375_5000.h \
+ src_small_int24_7_8_4375_5000.h \
+ src_small_int24_8_7_4375_5000.h \
+ src_small_int24_define.h \
+ src_small_int24_table.h \
+ src_std_int24_10_21_4375_5000.h \
+ src_std_int24_10_9_4375_5000.h \
+ src_std_int24_1_2_2188_5000.h \
+ src_std_int24_1_2_4375_5000.h \
+ src_std_int24_1_3_2188_5000.h \
+ src_std_int24_1_3_4375_5000.h \
+ src_std_int24_16_7_3938_5000.h \
+ src_std_int24_20_21_4020_5000.h \
+ src_std_int24_20_7_2871_5000.h \
+ src_std_int24_21_20_4020_5000.h \
+ src_std_int24_2_1_2188_5000.h \
+ src_std_int24_21_40_3828_5000.h \
+ src_std_int24_2_1_4375_5000.h \
+ src_std_int24_21_80_3828_5000.h \
+ src_std_int24_2_3_4375_5000.h \
+ src_std_int24_3_1_2188_5000.h \
+ src_std_int24_3_1_4375_5000.h \
+ src_std_int24_32_21_4375_5000.h \
+ src_std_int24_3_2_4375_5000.h \
+ src_std_int24_3_4_4375_5000.h \
+ src_std_int24_40_21_3828_5000.h \
+ src_std_int24_4_3_4375_5000.h \
+ src_std_int24_5_7_4375_5000.h \
+ src_std_int24_7_8_4375_5000.h \
+ src_std_int24_8_21_3125_5000.h\
+ src_std_int24_8_7_2381_5000.h \
+ src_std_int24_8_7_4375_5000.h \
+ src_std_int24_define.h \
+ src_std_int24_table.h \
+ src_tiny_int16_1_2_3750_5100.h \
+ src_tiny_int16_1_3_1875_5100.h \
+ src_tiny_int16_1_3_3750_5100.h \
+ src_tiny_int16_20_21_3445_5100.h \
+ src_tiny_int16_21_20_3445_5100.h \
+ src_tiny_int16_2_1_3750_5100.h \
+ src_tiny_int16_2_3_3750_5100.h \
+ src_tiny_int16_3_1_1875_5100.h \
+ src_tiny_int16_3_1_3750_5100.h \
+ src_tiny_int16_3_2_3750_5100.h \
+ src_tiny_int16_7_8_3750_5100.h \
+ src_tiny_int16_8_7_3750_5100.h \
+ src_tiny_int16_define.h \
+ src_tiny_int16_table.h
diff --git a/src/include/reef/math/Makefile.am b/src/include/reef/math/Makefile.am
new file mode 100644
index 0000000..fcd1d2f
--- /dev/null
+++ b/src/include/reef/math/Makefile.am
@@ -0,0 +1,3 @@
+noinst_HEADERS = \
+ numbers.h \
+ trig.h
diff --git a/src/platform/baytrail/Makefile.am b/src/platform/baytrail/Makefile.am
index bf9d40a..05b1235 100644
--- a/src/platform/baytrail/Makefile.am
+++ b/src/platform/baytrail/Makefile.am
@@ -1,5 +1,7 @@
SUBDIRS = include
+EXTRA_DIST = baytrail.x.in
+
noinst_LIBRARIES = libplatform.a
libplatform_a_SOURCES = \
diff --git a/src/platform/baytrail/include/xtensa/config/Makefile.am b/src/platform/baytrail/include/xtensa/config/Makefile.am
index 99c21a5..c68949b 100644
--- a/src/platform/baytrail/include/xtensa/config/Makefile.am
+++ b/src/platform/baytrail/include/xtensa/config/Makefile.am
@@ -1,5 +1,7 @@
noinst_HEADERS = \
core-isa.h \
+ core-isa-byt.h \
+ core-isa-cht.h \
core-matmap.h \
defs.h \
specreg.h \
diff --git a/version.sh b/version.sh
new file mode 100755
index 0000000..fb5f3e4
--- /dev/null
+++ b/version.sh
@@ -0,0 +1,39 @@
+
+# version for configure, make dist and FW etc
+# usage "version.sh dir"
+# Where dir is the top level directory path.
+
+# use pwd is no path argument is given
+if [ $# -eq 0 ]; then
+ DIR=`pwd`
+else
+ DIR=$1
+fi
+
+# create git version if we are a git repo
+if [ ! -d $DIR/.git ]; then
+# version for make dist
+ git describe --abbrev=4 > $DIR/.version
+ git describe --abbrev=4 > $DIR/.tarball-version
+
+ # git commit for IPC
+ echo "#define REEF_TAG \"`git log --pretty=format:\"%h\" -1 | cut -c1-5`\"" > $DIR/src/include/version.h
+else
+ echo "#define REEF_TAG 0" > $DIR/src/include/version.h
+fi
+
+# build counter
+if [ -e $DIR/.build ]; then
+ num=$((`cat $DIR/.build` + 1))
+else
+ num=0
+fi
+
+# save and insert build counter
+echo $num > $DIR/.build
+echo "#define REEF_BUILD $num" >> $DIR/src/include/version.h
+
+#echo version for AC_INIT
+if [ -e $DIR/.version ]; then
+ echo -n `cat $DIR/.version | cut -dv -f2 | cut -d. -f1`.`cat $DIR/.version | cut -d. -f2 | cut -d- -f1`
+fi
--
2.14.1
1
0
[Sound-open-firmware] [PATCH v4] [RFC][host-1.0] library: split SOF library into separate component libraries
by Ranjani Sridharan 10 Jan '18
by Ranjani Sridharan 10 Jan '18
10 Jan '18
This patch enables creating a separate library per component and
a common library for pipeline, buffer etc
Signed-off-by: Ranjani Sridharan <ranjani.sridharan(a)linux.intel.com>
---
configure.ac | 1 +
src/Makefile.am | 7 +-
src/arch/host/include/Makefile.am | 1 +
src/audio/Makefile.am | 909 +++++++++++++++++++++++++++++--
src/include/reef/Makefile.am | 6 +-
src/include/reef/audio/Makefile.am | 5 +-
src/include/uapi/Makefile.am | 2 +-
src/ipc/Makefile.am | 28 +-
src/library/include/platform/Makefile.am | 4 +-
src/math/Makefile.am | 22 +-
10 files changed, 933 insertions(+), 52 deletions(-)
diff --git a/configure.ac b/configure.ac
index 925d450..a0ae651 100644
--- a/configure.ac
+++ b/configure.ac
@@ -243,6 +243,7 @@ AC_CONFIG_FILES([
src/arch/xtensa/xtos/Makefile
src/arch/host/Makefile
src/arch/host/include/Makefile
+ src/arch/host/include/arch/Makefile
src/audio/Makefile
src/math/Makefile
src/drivers/Makefile
diff --git a/src/Makefile.am b/src/Makefile.am
index 57c40e8..ed21692 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,5 +1,10 @@
+export COMMON_INCDIR = \
+ $(REEF_INCDIR) \
+ $(ARCH_INCDIR) \
+ $(PLATFORM_INCDIR)
+
if BUILD_LIB
-SUBDIRS = math audio arch include library
+SUBDIRS = ipc math audio arch include library
else
SUBDIRS = init math audio platform tasks drivers ipc lib arch include
endif
diff --git a/src/arch/host/include/Makefile.am b/src/arch/host/include/Makefile.am
index e69de29..f0ac9b7 100644
--- a/src/arch/host/include/Makefile.am
+++ b/src/arch/host/include/Makefile.am
@@ -0,0 +1 @@
+SUBDIRS = arch
diff --git a/src/audio/Makefile.am b/src/audio/Makefile.am
index 4a2ee0f..b968c4b 100644
--- a/src/audio/Makefile.am
+++ b/src/audio/Makefile.am
@@ -1,3 +1,9 @@
+includedir = $(prefix)/include/sof/audio
+
+include_HEADERS = \
+ eq_iir.h \
+ eq_fir.h
+
COMP_SRC = \
eq_iir.c \
iir.c \
@@ -16,126 +22,885 @@ COMP_SRC = \
component.c \
buffer.c
+SOF_SRC = \
+ dai.c \
+ host.c \
+ pipeline.c \
+ component.c \
+ buffer.c
+
+SRC_SRC = \
+ src.c \
+ src_core.c
+
+EQ_FIR_SRC = \
+ eq_fir.c \
+ fir.c
+
+EQ_IIR_SRC = \
+ eq_iir.c \
+ iir.c
+
if BUILD_LIB
# only host builds shared libraries, the rest are static
if BUILD_HOST
+# libsof
lib_LTLIBRARIES = libsof.la
-libsof_la_SOURCES = $(COMP_SRC)
+libsof_la_SOURCES = $(SOF_SRC)
libsof_la_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+# libsof_src
+lib_LTLIBRARIES += libsof_src.la
+
+libsof_src_la_SOURCES = $(SRC_SRC)
+
+libsof_src_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir.la
+
+libsof_eq_fir_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir.la
+
+libsof_eq_iir_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume.la
+
+libsof_volume_la_SOURCES = volume.c
+
+libsof_volume_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux.la
+
+libsof_mux_la_SOURCES = mux.c
+
+libsof_mux_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch.la
+
+libsof_switch_la_SOURCES = switch.c
+
+libsof_switch_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer.la
+
+libsof_mixer_la_SOURCES = mixer.c
+
+libsof_mixer_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone.la
+
+libsof_tone_la_SOURCES = tone.c
+
+libsof_tone_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
if HAVE_SSE42
+# libsof
lib_LTLIBRARIES += libsof_sse42.la
-libsof_sse42_la_SOURCES = $(COMP_SRC)
+libsof_sse42_la_SOURCES = $(SOF_SRC)
libsof_sse42_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(SSE42_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_sse42_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_sse42.la
+
+libsof_src_sse42_la_SOURCES = $(SRC_SRC)
+
+libsof_src_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_sse42.la
+
+libsof_eq_fir_sse42_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_sse42.la
+
+libsof_eq_iir_sse42_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_sse42.la
+
+libsof_volume_sse42_la_SOURCES = volume.c
+
+libsof_volume_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_sse42.la
+
+libsof_mux_sse42_la_SOURCES = mux.c
+
+libsof_mux_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_sse42.la
+
+libsof_switch_sse42_la_SOURCES = switch.c
+
+libsof_switch_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_sse42.la
+
+libsof_mixer_sse42_la_SOURCES = mixer.c
+
+libsof_mixer_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_sse42.la
+
+libsof_tone_sse42_la_SOURCES = tone.c
+
+libsof_tone_sse42_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_sse42_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
endif
if HAVE_AVX
+# libsof
lib_LTLIBRARIES += libsof_avx.la
-libsof_avx_la_SOURCES = $(COMP_SRC)
+libsof_avx_la_SOURCES = $(SOF_SRC)
libsof_avx_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(AVX_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_avx_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx.la
+
+libsof_src_avx_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx.la
+
+libsof_eq_fir_avx_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx.la
+
+libsof_eq_iir_avx_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx.la
+
+libsof_volume_avx_la_SOURCES = volume.c
+
+libsof_volume_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx.la
+
+libsof_mux_avx_la_SOURCES = mux.c
+
+libsof_mux_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx.la
+
+libsof_switch_avx_la_SOURCES = switch.c
+
+libsof_switch_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx.la
+
+libsof_mixer_avx_la_SOURCES = mixer.c
+
+libsof_mixer_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx.la
+
+libsof_tone_avx_la_SOURCES = tone.c
+
+libsof_tone_avx_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
endif
if HAVE_AVX2
+# libsof
lib_LTLIBRARIES += libsof_avx2.la
-libsof_avx2_la_SOURCES = $(COMP_SRC)
+libsof_avx2_la_SOURCES = $(SOF_SRC)
libsof_avx2_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(AVX2_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_avx2_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_avx2.la
+
+libsof_src_avx2_la_SOURCES = $(SRC_SRC)
+
+libsof_src_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_avx2.la
+
+libsof_eq_fir_avx2_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_avx2.la
+
+libsof_eq_iir_avx2_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_avx2.la
+
+libsof_volume_avx2_la_SOURCES = volume.c
+
+libsof_volume_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_avx2.la
+
+libsof_mux_avx2_la_SOURCES = mux.c
+
+libsof_mux_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_avx2.la
+
+libsof_switch_avx2_la_SOURCES = switch.c
+
+libsof_switch_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_avx2.la
+
+libsof_mixer_avx2_la_SOURCES = mixer.c
+
+libsof_mixer_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_avx2.la
+
+libsof_tone_avx2_la_SOURCES = tone.c
+
+libsof_tone_avx2_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(AVX2_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_avx2_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
endif
if HAVE_FMA
+# libsof
lib_LTLIBRARIES += libsof_fma.la
-libsof_fma_la_SOURCES = $(COMP_SRC)
+libsof_fma_la_SOURCES = $(SOF_SRC)
libsof_fma_la_CFLAGS = \
$(ARCH_CFLAGS) \
$(FMA_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
libsof_fma_la_LDFLAGS = \
-version-info $(VERSION) \
-no-undefined \
-export-dynamic
+
+# libsof_src
+lib_LTLIBRARIES += libsof_src_fma.la
+
+libsof_src_fma_la_SOURCES = $(SRC_SRC)
+
+libsof_src_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_src_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_fir
+lib_LTLIBRARIES += libsof_eq_fir_fma.la
+
+libsof_eq_fir_fma_la_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_fir_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_eq_iir
+lib_LTLIBRARIES += libsof_eq_iir_fma.la
+
+libsof_eq_iir_fma_la_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_eq_iir_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_volume
+lib_LTLIBRARIES += libsof_volume_fma.la
+
+libsof_volume_fma_la_SOURCES = volume.c
+
+libsof_volume_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_volume_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mux
+lib_LTLIBRARIES += libsof_mux_fma.la
+
+libsof_mux_fma_la_SOURCES = mux.c
+
+libsof_mux_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mux_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_switch
+lib_LTLIBRARIES += libsof_switch_fma.la
+
+libsof_switch_fma_la_SOURCES = switch.c
+
+libsof_switch_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_switch_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_mixer
+lib_LTLIBRARIES += libsof_mixer_fma.la
+
+libsof_mixer_fma_la_SOURCES = mixer.c
+
+libsof_mixer_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_mixer_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+# libsof_tone
+lib_LTLIBRARIES += libsof_tone_fma.la
+
+libsof_tone_fma_la_SOURCES = tone.c
+
+libsof_tone_fma_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(FMA_CFLAGS) \
+ $(COMMON_INCDIR)
+
+libsof_tone_fma_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
endif
else
# Build for non host targets
+# libsof
lib_LIBRARIES = libsof.a
-libsof_a_SOURCES = $(COMP_SRC)
+libsof_a_SOURCES = $(SOF_SRC)
libsof_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src.a
+
+libsof_src_a_SOURCES = $(SRC_SRC)
+
+libsof_src_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir.a
+
+libsof_eq_fir_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir.a
+
+libsof_eq_iir_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume.a
+
+libsof_volume_a_SOURCES = volume.c
+
+libsof_volume_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux.a
+
+libsof_mux_a_SOURCES = mux.c
+
+libsof_mux_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch.a
+
+libsof_switch_a_SOURCES = switch.c
+
+libsof_switch_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer.a
+
+libsof_mixer_a_SOURCES = mixer.c
+
+libsof_mixer_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone.a
+
+libsof_tone_a_SOURCES = tone.c
+
+libsof_tone_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+
if HAVE_HIFI2EP
+# libsof
lib_LIBRARIES += libsof_hifi2ep.a
-libsof_hifi2ep_a_SOURCES = $(COMP_SRC)
+libsof_hifi2ep_a_SOURCES = $(SOF_SRC)
libsof_hifi2ep_a_CFLAGS = \
$(ARCH_CFLAGS) \
$(SSE42_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi2ep.a
+
+libsof_src_hifi2ep_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi2ep.a
+
+libsof_eq_fir_hifi2ep_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi2ep.a
+
+libsof_eq_iir_hifi2ep_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi2ep.a
+
+libsof_volume_hifi2ep_a_SOURCES = volume.c
+
+libsof_volume_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi2ep.a
+
+libsof_mux_hifi2ep_a_SOURCES = mux.c
+
+libsof_mux_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi2ep.a
+
+libsof_switch_hifi2ep_a_SOURCES = switch.c
+
+libsof_switch_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi2ep.a
+
+libsof_mixer_hifi2ep_a_SOURCES = mixer.c
+
+libsof_mixer_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi2ep.a
+
+libsof_tone_hifi2ep_a_SOURCES = tone.c
+
+libsof_tone_hifi2ep_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
endif
if HAVE_HIFI3
+# libsof
lib_LIBRARIES += libsof_hifi3.a
libsof_hifi3_a_SOURCES = $(COMP_SRC)
@@ -143,9 +908,87 @@ libsof_hifi3_a_SOURCES = $(COMP_SRC)
libsof_hifi3_a_CFLAGS = \
$(ARCH_CFLAGS) \
$(SSE42_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+
+# libsof_src
+lib_LIBRARIES += libsof_src_hifi3.a
+
+libsof_src_hifi3_a_SOURCES = $(SRC_SRC)
+
+libsof_src_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_fir
+lib_LIBRARIES += libsof_eq_fir_hifi3.a
+
+libsof_eq_fir_hifi3_a_SOURCES = $(EQ_FIR_SRC)
+
+libsof_eq_fir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_eq_iir
+lib_LIBRARIES += libsof_eq_iir_hifi3.a
+
+libsof_eq_iir_hifi3_a_SOURCES = $(EQ_IIR_SRC)
+
+libsof_eq_iir_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_volume
+lib_LIBRARIES += libsof_volume_hifi3.a
+
+libsof_volume_hifi3_a_SOURCES = volume.c
+
+libsof_volume_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mux
+lib_LIBRARIES += libsof_mux_hifi3.a
+
+libsof_mux_hifi3_a_SOURCES = mux.c
+
+libsof_mux_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_switch
+lib_LIBRARIES += libsof_switch_hifi3.a
+
+libsof_switch_hifi3_a_SOURCES = switch.c
+
+libsof_switch_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_mixer
+lib_LIBRARIES += libsof_mixer_hifi3.a
+
+libsof_mixer_hifi3_a_SOURCES = mixer.c
+
+libsof_mixer_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
+
+# libsof_tone
+lib_LIBRARIES += libsof_tone_hifi3.a
+
+libsof_tone_hifi3_a_SOURCES = tone.c
+
+libsof_tone_hifi3_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(SSE42_CFLAGS) \
+ $(COMMON_INCDIR)
endif
endif
@@ -177,8 +1020,6 @@ libaudio_a_SOURCES = \
libaudio_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
endif
diff --git a/src/include/reef/Makefile.am b/src/include/reef/Makefile.am
index f690e2a..d098036 100644
--- a/src/include/reef/Makefile.am
+++ b/src/include/reef/Makefile.am
@@ -1,13 +1,17 @@
SUBDIRS = audio
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef
+
+include_HEADERS = \
alloc.h \
clock.h \
dai.h \
debug.h \
dma.h \
+ dma-trace.h \
dw-dma.h \
init.h \
+ intel-ipc.h \
interrupt.h \
interrupt-map.h \
io.h \
diff --git a/src/include/reef/audio/Makefile.am b/src/include/reef/audio/Makefile.am
index b02684c..2e0e8d6 100644
--- a/src/include/reef/audio/Makefile.am
+++ b/src/include/reef/audio/Makefile.am
@@ -1,4 +1,7 @@
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/reef/audio
+
+include_HEADERS = \
component.h \
pipeline.h \
+ format.h \
buffer.h
diff --git a/src/include/uapi/Makefile.am b/src/include/uapi/Makefile.am
index 103d692..f202eca 100644
--- a/src/include/uapi/Makefile.am
+++ b/src/include/uapi/Makefile.am
@@ -1,4 +1,4 @@
-includedir = $(prefix)/include/sof
+includedir = $(prefix)/include/sof/uapi
include_HEADERS = \
ipc.h \
diff --git a/src/ipc/Makefile.am b/src/ipc/Makefile.am
index 7e63ca6..9878273 100644
--- a/src/ipc/Makefile.am
+++ b/src/ipc/Makefile.am
@@ -1,7 +1,22 @@
-noinst_LIBRARIES = libipc.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_ipc.la
+
+libsof_ipc_la_SOURCES = \
+ ipc.c
+
+libsof_ipc_la_LDFLAGS = \
+ -version-info $(VERSION) \
+ -no-undefined \
+ -export-dynamic
+
+libsof_ipc_la_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_ipc.a
if BUILD_BAYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -10,7 +25,7 @@ libipc_a_SOURCES = \
endif
if BUILD_CHERRYTRAIL
-libipc_a_SOURCES = \
+libsof_ipc_a_SOURCES = \
ipc.c \
intel-ipc.c \
byt-ipc.c \
@@ -18,9 +33,8 @@ libipc_a_SOURCES = \
dma-copy.c
endif
-libipc_a_CFLAGS = \
+libsof_ipc_a_CFLAGS = \
$(ARCH_CFLAGS) \
- $(ARCH_INCDIR) \
- $(REEF_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+endif
diff --git a/src/library/include/platform/Makefile.am b/src/library/include/platform/Makefile.am
index 5775230..898867f 100644
--- a/src/library/include/platform/Makefile.am
+++ b/src/library/include/platform/Makefile.am
@@ -1,4 +1,6 @@
-noinst_HEADERS = \
+includedir = $(prefix)/include/sof/platform
+
+include_HEADERS = \
clk.h \
dma.h \
interrupt.h \
diff --git a/src/math/Makefile.am b/src/math/Makefile.am
index b795afa..6a48e29 100644
--- a/src/math/Makefile.am
+++ b/src/math/Makefile.am
@@ -1,11 +1,21 @@
-noinst_LIBRARIES = libmath.a
+if BUILD_LIB
+lib_LTLIBRARIES = libsof_math.la
-libmath_a_SOURCES = \
+libsof_math_la_SOURCES = \
trig.c \
numbers.c
-libmath_a_CFLAGS = \
+libsof_math_la_CFLAGS = \
$(ARCH_CFLAGS) \
- $(REEF_INCDIR) \
- $(ARCH_INCDIR) \
- $(PLATFORM_INCDIR)
+ $(COMMON_INCDIR)
+else
+noinst_LIBRARIES = libsof_math.a
+
+libsof_math_a_SOURCES = \
+ trig.c \
+ numbers.c
+
+libsof_math_a_CFLAGS = \
+ $(ARCH_CFLAGS) \
+ $(COMMON_INCDIR)
+endif
--
2.11.0
1
0
I'd like to announce the 1.0 release of Sound Open Firmware (SOF) is
available for download on git.alsa-project.org.
SOF is an open source BSD licensed audio DSP firmware that currently
runs on Cadence xtensa architecture DSPs found on Intel Baytrail,
Braswell and Cherrytrail based devices, however SOF is architecture and
platform independent meaning it's not tightly coupled to xtensa DSPs or
Intel CPUs/SoCs.
The 1.0 release supports limited playback and capture topologies
alongside volume, mixing and sample format conversion.
Information about SOF can be found on the ALSA SOF wiki here :-
https://www.alsa-project.org/main/index.php/Firmware
Development for SOF 1.1 has started which will include support for
Haswell, Broadwell and Apollolake platform alongside support for SRC
and more complex topologies.
Liam
3
3