Added CTI, TGU, and Node Access DEBUG Suites#307
Added CTI, TGU, and Node Access DEBUG Suites#307Rohan-in-Qualcomm wants to merge 1 commit intoqualcomm-linux:mainfrom
Conversation
|
@Rohan-in-Qualcomm Please provide a clear commit message explaining the reason for your changes. Also, rebase your patch, as it currently shows commits from others. #304 Please also resolve the issues identified by shelllint and ensure that the execute bit permissions are set correctly. |
183837a to
5562584
Compare
- CTI-Enable-Disable: tests for enabling/disabling Cross Trigger Interface - CTI-Test: functional validation of CTI trigger channels - Node-Access: verifies QDSS debug node accessibility via sysfs - TGU-Enable-Disable: tests for Trigger Generation Unit enable/disable flow Signed-off-by: Rohan Dutta <rohadutt@qti.qualcomm.com>
5562584 to
2115e04
Compare
| * **Disable**: Writes `0` to the `enable` file. | ||
| * **Verify**: Reads the `enable` file; expects `0`. | ||
| 4. **Cleanup**: Resets all devices to disabled state. | ||
|
|
There was a problem hiding this comment.
please add the sample output while executing the run.sh and steps to run the file. please see other README for the same
|
|
||
| res_file="./$TESTNAME.res" | ||
| rm -f "$res_file" | ||
| touch "$res_file" |
|
|
||
| reset_devices() { | ||
| log_info "Resetting Coresight devices..." | ||
| if [ -f "$CS_BASE/tmc_etf0/enable_sink" ]; then |
There was a problem hiding this comment.
what if any or all of the paths are not present? Can you handle that aswell?
| done | ||
| fi | ||
|
|
||
| reset_devices |
There was a problem hiding this comment.
This is wrong, you will have to reset to state to the values before reset_devices is called
|
|
||
| if [ "$FAIL_COUNT" -eq 0 ]; then | ||
| log_pass "CTI Enable/Disable Test Completed Successfully" | ||
| echo "$TESTNAME PASS" >> "$res_file" |
There was a problem hiding this comment.
Please give > instead of >>
| echo "$TESTNAME PASS" >> "$res_file" | ||
| else | ||
| log_fail "CTI Enable/Disable Test Failed ($FAIL_COUNT errors)" | ||
| echo "$TESTNAME FAIL" >> "$res_file" |
There was a problem hiding this comment.
Please give > instead of >>
| [ -e "$_dev" ] || continue | ||
| CTI_LIST="$CTI_LIST $(basename "$_dev")" | ||
| done | ||
| CTI_LIST="${CTI_LIST# }" |
|
|
||
| if [ -z "$CTI_LIST" ]; then | ||
| log_fail "No CTI devices found." | ||
| FAIL_COUNT=$((FAIL_COUNT + 1)) |
There was a problem hiding this comment.
Can we exit and mark fail if there are no CTI devices?
| @@ -0,0 +1,20 @@ | |||
| metadata: | |||
| name: CTI-Trigger-Map | |||
| description: "Validates Coresight Cross Trigger Interface (CTI) by mapping and unmapping triggers to channels." | |||
There was a problem hiding this comment.
Below are needed aswell
name: <>
format: "Lava-Test Test Definition 1.0"
description: <>
maintainer:
- <>
| @@ -0,0 +1,20 @@ | |||
| metadata: | |||
| name: CTI-Enable-Disable | |||
| description: "Verifies that all Coresight CTI devices can be successfully enabled and disabled via sysfs." | |||
There was a problem hiding this comment.
Below are needed aswell
name: <>
format: "Lava-Test Test Definition 1.0"
description: <>
maintainer:
- <>
| run: | ||
| steps: | ||
| - REPO_PATH=$PWD | ||
| - cd Runner/suites/Kernel/DEBUG/CTI-Test |
|
|
||
| run: | ||
| steps: | ||
| - REPO_PATH=$PWD |
|
|
||
| run: | ||
| steps: | ||
| - REPO_PATH=$PWD |
| run: | ||
| steps: | ||
| - REPO_PATH=$PWD | ||
| - cd Runner/suites/Kernel/DEBUG/CTI-Enable-Disable |
| * **Attach**: writes `channel trigger` to `trigin_attach` / `trigout_attach`. | ||
| * **Verify**: Reads back via `chan_xtrigs_sel` and `chan_xtrigs_in`/`out` to confirm mapping. | ||
| * **Detach**: Unmaps the trigger and confirms the entry is cleared. | ||
| 6. **Cleanup**: Restores the original LPM sleep setting. |
There was a problem hiding this comment.
please add the sample output while executing the run.sh and steps to run the file. please see other README for the same
| * Performs a `cat` operation. | ||
| * Repeats the process for the `mgmt/` subdirectory if it exists. | ||
| 6. **Verification**: Any read failure (exit code non-zero) increments the failure counter. | ||
|
|
There was a problem hiding this comment.
please add the sample output while executing the run.sh and steps to run the file. please see other README for the same
| * **Verify**: Checks the exit code of the write operation. | ||
| * **Disable**: Writes `0` to `enable_tgu`. | ||
| * **Verify**: Checks the exit code. | ||
| 4. **Cleanup**: Disables the sink before the next iteration. |
There was a problem hiding this comment.
please add the sample output while executing the run.sh and steps to run the file. please see other README for the same
|
|
||
| res_file="./$TESTNAME.res" | ||
| rm -f "$res_file" | ||
| touch "$res_file" |
There was a problem hiding this comment.
i dont think this is required
|
|
||
| CTI_MAX_TRIGGERS=8 | ||
| CTI_MAX_CHANNELS=4 | ||
| # CTI_TRIGGERS_TO_TEST=1 |
There was a problem hiding this comment.
can be removed if not used?
This PR adds new DEBUG suites for CTI, TGU, and Node Access testing.
Added folders
Purpose
These suites extend the kernel debugging and trace validation coverage for CTI, TGU, and node-level operations.
Commit is independent of other DEBUG-related PRs.