Skip to content

Commit 2d1768e

Browse files
authored
Fix ramdisk unpack and repack logic for fastrpc validation (#238)
* CI: Switch all reusable workflow references to 'development' branch - Ensures CI uses latest logic from development branch Signed-off-by: Tharun Kumar Merugu <mtharu@qti.qualcomm.com> * CI Fix: Ensure proper packaging of ramdisk contents into cpio archive - Added missing directory creation for ramdisk_test before decompression - Ensured only contents of ramdisk_fastrpc are archived (not the folder itself) - Applied safe and consistent cpio and gzip usage - Improved error handling and quoting for robustness Signed-off-by: Tharun Kumar Merugu <mtharu@qti.qualcomm.com> --------- Signed-off-by: Tharun Kumar Merugu <mtharu@qti.qualcomm.com>
1 parent e7929db commit 2d1768e

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

.github/actions/build/action.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,7 @@ runs:
8787
cp -rf src/adsprpcd src/cdsprpcd src/sdsprpcd ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/usr/bin/
8888
8989
echo "Copy fastrpc test files"
90-
cp -rf test/fastrpc_test ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/usr/bin
91-
cp -rf test/linux/* ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/usr/bin
92-
cp -rf test/v75/* ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/usr/bin
90+
cp -rf test/* ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/usr/bin
9391
9492
echo "Package FastRPC firmware files"
9593
cp -r ${{ inputs.workspace_path }}/firmware_dir/* ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/
@@ -100,7 +98,9 @@ runs:
10098
ls -la ${{ inputs.workspace_path }}/artifacts/ramdisk_fastrpc/usr/lib/
10199
102100
cd ${{ inputs.workspace_path }}/artifacts/
103-
find ramdisk_fastrpc | cpio -o -H newc > ramdisk_fastrpc.cpio
101+
cd ramdisk_fastrpc
102+
find . | cpio -o -H newc > ../ramdisk_fastrpc.cpio
103+
cd ..
104104
gzip -9 ramdisk_fastrpc.cpio
105105
mv ramdisk_fastrpc.cpio.gz ramdisk_fastrpc.gz
106106
@@ -109,8 +109,7 @@ runs:
109109
run: |
110110
echo "Unpack and mount ramdisk"
111111
cd ${{ inputs.workspace_path }}/artifacts
112-
113-
# Decompress the ramdisk.gz safely
112+
mkdir -p ramdisk_test
114113
gunzip -c ramdisk_fastrpc.gz > ramdisk_test/ramdisk
115114
116115
echo "Unpacking ramdisk"

.github/actions/loading/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ runs:
3939
core.setFailed(`Failed to load or parse MACHINES.json: ${err.message}`);
4040
return;
4141
}
42-
# Slim matrix for better job visibility
42+
// Slim matrix for better job visibility
4343
const slim_matrix = Object.entries(file).map(([machine, [firmware]]) => ({ machine, firmware }));
4444
core.setOutput('build_matrix', JSON.stringify(slim_matrix));
4545
console.log(slim_matrix);
4646
47-
# Full matrix to pass to test jobs
47+
// Full matrix to pass to test jobs
4848
const complete_matrix = Object.entries(file).map(([machine, [firmware, lavaname]]) => ({
4949
machine,
5050
firmware,

0 commit comments

Comments
 (0)