Skip to content

Conversation

smuppand
Copy link
Contributor

Key Enhancements

Robust environment sourcing

  • Added reliable sourcing of init_env and functestlib.sh to ensure consistent runtime environment across test environments.

Argument parsing

  • Supports --arch, --repeat, and --timeout options.
  • Defaults to REPEAT=1, no timeout, and auto-detects architecture if not specified.

Architecture auto-detection

  • Detects SoC ID from /sys/devices/soc0/soc_id and maps to known DSP architecture (v68, v73, v75) with fallback warning for unknown IDs.

Dependency checks

  • Ensures fastrpc_test binary and required tools (e.g., grep) are available before execution.
  • Falls back to script if stdbuf is unavailable for unbuffered output, with a warning if neither is found.

CI-debug friendly logging

  • Added detailed logs for iteration count, SoC ID, detected architecture, and pass/fail counts per run.
  • Captures and displays full output from each run to aid CI debugging.

Result file handling

  • Writes standardized .res for CI parsers.
  • Pass/fail determined by number of successful iterations vs total runs.

README.md update
Documented new script usage options, example runs, logging behavior, and CI integration notes.

Benefits

  • Improved maintainability and portability across platforms.
  • Better visibility in CI/CD pipelines with detailed logs and consistent result files.
  • Flexible test execution with configurable parameters.

@abbajaj806
Copy link
Contributor

  1. Currently the script is assuming that fastrpc_test is present in /usr/bin. Ideally, fastrpc_test should be moved or installed in /usr/share/bin/

  2. Even after moving fastrpc_test and other related packages from /usr/share/bin to /usr/bin, we are seeing below issue.
    [INFO] 1970-01-07 06:22:35 - Buffering: stdbuf -oL -eL | Timeout: none | Arch: v75
    [INFO] 1970-01-07 06:22:35 - Running iter1/1 | start: 1970-01-07T06:22:35Z | cmd: fastrpc_test -d 3 -U 1 -t linux -a v75
    Error resolving path /var/Runner/suites/Multimedia/CDSP/fastrpc_test/linux: No such file or directory
    [FAIL] 1970-01-07 06:22:35 - iter1: fastrpc_test exited 255 (see ./logs_fastrpc_test_19700107-062235/iter1.out)

  3. fastrpc_test should be executed from the folder where fastrpc_test bin is present. As it will look for dependent packages in that folder only. For this reason only we implemented via stdbuf.

…, argument parsing, and arch detection

- Added robust sourcing of init_env and functestlib.sh
- Implemented argument parsing for --arch, --repeat, and --timeout with defaults
- Auto-detect architecture from /sys/devices/soc0/soc_id if not provided
- Added dependency checks for fastrpc_test and grep
- Fallback to 'script' if 'stdbuf' is unavailable for unbuffered output
- Added CI-debug friendly logging for test iterations, SoC ID, arch, and pass/fail counts
- Improved result file handling for CI result parsing
- Updated README.md with new usage instructions, logging details, and CI notes

Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
@smuppand
Copy link
Contributor Author

  1. Currently the script is assuming that fastrpc_test is present in /usr/bin. Ideally, fastrpc_test should be moved or installed in /usr/share/bin/

The script has now been improved to automatically detect the required environment paths. Additionally, users can explicitly specify the directory where the fastrpc_test binary is located.

  1. Even after moving fastrpc_test and other related packages from /usr/share/bin to /usr/bin, we are seeing below issue.
    [INFO] 1970-01-07 06:22:35 - Buffering: stdbuf -oL -eL | Timeout: none | Arch: v75
    [INFO] 1970-01-07 06:22:35 - Running iter1/1 | start: 1970-01-07T06:22:35Z | cmd: fastrpc_test -d 3 -U 1 -t linux -a v75
    Error resolving path /var/Runner/suites/Multimedia/CDSP/fastrpc_test/linux: No such file or directory
    [FAIL] 1970-01-07 06:22:35 - iter1: fastrpc_test exited 255 (see ./logs_fastrpc_test_19700107-062235/iter1.out)

This issue is addressed now

  1. fastrpc_test should be executed from the folder where fastrpc_test bin is present. As it will look for dependent packages in that folder only. For this reason only we implemented via stdbuf.

This also taken care.

Copy link
Contributor

@abbajaj806 abbajaj806 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks Good to Me

@abbajaj806 abbajaj806 merged commit f6e0d55 into qualcomm-linux:main Aug 14, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants