aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/load.sh2
-rwxr-xr-xscripts/make-agl-xds.sh14
-rwxr-xr-xscripts/make-agl.sh22
-rwxr-xr-xscripts/test_configfs_cleanup.sh6
-rwxr-xr-xscripts/test_configfs_run.sh (renamed from scripts/test_configfs.sh)0
-rwxr-xr-xscripts/unload.sh4
6 files changed, 35 insertions, 13 deletions
diff --git a/scripts/load.sh b/scripts/load.sh
index 103a63b..e3f21b4 100755
--- a/scripts/load.sh
+++ b/scripts/load.sh
@@ -8,6 +8,6 @@ insmod dummy/snd-avirt-ap-dummy.ko
insmod loopback/snd-avirt-ap-loopback.ko
# Run the test script
-./scripts/test_configfs.sh
+./scripts/test_configfs_run.sh
echo "Drivers Loaded!"
diff --git a/scripts/make-agl-xds.sh b/scripts/make-agl-xds.sh
new file mode 100755
index 0000000..5cb8048
--- /dev/null
+++ b/scripts/make-agl-xds.sh
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+# Get SDK path
+sdk_id=$1 # first arg must be XDS_SDK_ID
+shift 1
+long_sdkpath=$(xds-cli sdks get $sdk_id | grep Path)
+sdkpath=${long_sdkpath:4}
+
+# Build
+/opt/AGL/bin/xds-cli exec --config xds-project.conf -- \
+ CONFIG_AVIRT=m CONFIG_AVIRT_BUILDLOCAL=y \
+ CONFIG_AVIRT_AP_DUMMY=m \
+ CONFIG_AVIRT_AP_LOOPBACK=m \
+ make -C $sdkpath/sysroots/aarch64-agl-linux/usr/src/kernel M=$(pwd) $@
diff --git a/scripts/make-agl.sh b/scripts/make-agl.sh
index 6c94fbb..f4a6235 100755
--- a/scripts/make-agl.sh
+++ b/scripts/make-agl.sh
@@ -1,14 +1,16 @@
#!/bin/bash
-# Get SDK path
-sdk_id=$1 # first arg must be XDS_SDK_ID
-shift 1
-long_sdkpath=$(xds-cli sdks get $sdk_id | grep Path)
-sdkpath=${long_sdkpath:4}
+SDK_ROOT=/opt/agl-sdk
+SDK_VERSION=7.0.0
+SDK_VAR=aarch64
+
+# Source environment
+unset LD_LIBRARY_PATH
+source $SDK_ROOT/$SDK_VERSION-$SDK_VAR/environment-setup-aarch64-agl-linux
# Build
-/opt/AGL/bin/xds-cli exec --config xds-project.conf -- \
- LDFLAGS= CONFIG_AVIRT=m CONFIG_AVIRT_BUILDLOCAL=y \
- CONFIG_AVIRT_AP_DUMMY=m \
- CONFIG_AVIRT_AP_LOOPBACK=m \
- make -C $sdkpath/sysroots/aarch64-agl-linux/usr/src/kernel M=$(pwd) $@
+LDFLAGS= \
+CONFIG_AVIRT=m CONFIG_AVIRT_BUILDLOCAL=y \
+CONFIG_AVIRT_AP_DUMMY=m \
+CONFIG_AVIRT_AP_LOOPBACK=m \
+make -C $SDK_ROOT/$SDK_VERSION-$SDK_VAR/sysroots/$SDK_VAR-agl-linux/usr/src/kernel M=$(pwd) $@
diff --git a/scripts/test_configfs_cleanup.sh b/scripts/test_configfs_cleanup.sh
new file mode 100755
index 0000000..9697818
--- /dev/null
+++ b/scripts/test_configfs_cleanup.sh
@@ -0,0 +1,6 @@
+#!/bin/bash
+
+rmdir /config/snd-avirt/streams/playback_media
+rmdir /config/snd-avirt/streams/playback_navigation
+rmdir /config/snd-avirt/streams/playback_emergency
+rmdir /config/snd-avirt/streams/capture_voice
diff --git a/scripts/test_configfs.sh b/scripts/test_configfs_run.sh
index b6a56f6..b6a56f6 100755
--- a/scripts/test_configfs.sh
+++ b/scripts/test_configfs_run.sh
diff --git a/scripts/unload.sh b/scripts/unload.sh
index a18e1f5..acce310 100755
--- a/scripts/unload.sh
+++ b/scripts/unload.sh
@@ -1,7 +1,7 @@
#!/bin/sh
-rmdir /config/snd-avirt/streams/playback_*
-rmdir /config/snd-avirt/streams/capture_*
+# Cleanup the configfs filesystem
+./scripts/test_configfs_cleanup.sh
rm_module() {
lsmod |grep "^$1\>" && rmmod $1 || true