Skip to content

Fix thermal zone index issue in thermal sensor tests (Bugfix)#2311

Open
bnbhat wants to merge 1 commit intomainfrom
bnbhat/thermal-zone-fix-1
Open

Fix thermal zone index issue in thermal sensor tests (Bugfix)#2311
bnbhat wants to merge 1 commit intomainfrom
bnbhat/thermal-zone-fix-1

Conversation

@bnbhat
Copy link
Contributor

@bnbhat bnbhat commented Jan 27, 2026

Description

Thermal zone indices can change across reboots, making name-based identification unreliable. This change uses the zone type field instead, ensuring consistent test execution.

Additionally, thermal zone interfaces are sometimes repurposed for monitoring non-thermal parameters (e.g., voltages on Qualcomm RB3, RB8 platforms). These edge cases are excluded from test plans using regex patterns matched against the type field.

When both pre-suspend and after-suspend tests are generated from templates, a watchdog-triggered reboot can cause zone index changes, invalidating regex exclusions based on zone names and causing previously excluded tests to run unexpectedly.

This PR makes the test use type such as cpu5-thermal instead of index thermal_zone8

Resolved issues

https://warthogs.atlassian.net/browse/PECA-1263

@bnbhat bnbhat requested a review from weizhenwu January 27, 2026 12:40
@bnbhat bnbhat force-pushed the bnbhat/thermal-zone-fix-1 branch 2 times, most recently from 07d876c to a9e2ead Compare January 27, 2026 13:19
Thermal zone indices can change across reboots, making name-based
identification unreliable. This change uses the zone type field
instead, ensuring consistent test execution.

Additionally, thermal zone interfaces are sometimes repurposed for
monitoring non-thermal parameters (e.g., voltages on Qualcomm RB3,
RB8 platforms). These edge cases are excluded from test plans using
regex patterns matched against the type field.

When both pre-suspend and after-suspend tests are generated from
templates, a watchdog-triggered reboot can cause zone index changes,
invalidating regex exclusions based on zone names and causing
previously excluded tests to run unexpectedly.
@bnbhat bnbhat force-pushed the bnbhat/thermal-zone-fix-1 branch from a9e2ead to 17767ff Compare January 27, 2026 13:26
@bnbhat bnbhat changed the title Use type instead of name in thermal sensor tests (Bugfix) Fix thermal zone index issue in thermal sensor tests (Bugfix) Feb 2, 2026
@weizhenwu
Copy link
Contributor

Thanks for the PR!
I’m more concerned about the job execution order. I tried list-bootstrapped the test plan and noticed that cold boot, warm boot, and watchdog jobs are interleaved with other tests. This isn’t ideal, as they reset the system and can clear the “after-suspend” state. These boot-related tests should run either before all other tests or after all “after-suspend” tests.
For now, I will prefer to keep it as is, and I’m looking into how to make sure the execution order is what we expect.

@stanley31huang stanley31huang self-requested a review February 13, 2026 07:18
@stanley31huang
Copy link
Collaborator

will take a look after LNY holiday.

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.

3 participants