Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit the platform to perform the sleepgraph test (BugFix) #1136

Merged
merged 1 commit into from
Apr 18, 2024

Conversation

KaiChuan-Hsieh
Copy link
Contributor

@KaiChuan-Hsieh KaiChuan-Hsieh commented Apr 2, 2024

Limit the platform to perform the sleepgraph test (BugFix) (#1054)

Description

  • sleepgraph trigger suspend by utilizing sysfs node without notifying systemd (an upstream bug has been opened for this)
  • However, Nvidia uses a userspace daemon that relies on systemd status, so triggering suspend using sysfs directly may lead to issues on devices with Nvidia graphics cards
  • Align the sleep delay with Windows

Resolved issues

#1054

Documentation

https://learn.microsoft.com/en-us/windows-hardware/design/device-experiences/modern-standby-stress-and-long-duration-validation#test-operation

Tests

Verify the test by running the plan

$ checkbox-cli run com.canonical.certification::stress-pm-graph

Copy link

codecov bot commented Apr 2, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 43.21%. Comparing base (2ee5cc4) to head (8572de7).
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1136   +/-   ##
=======================================
  Coverage   43.21%   43.21%           
=======================================
  Files         356      356           
  Lines       38662    38662           
  Branches     6561     6561           
=======================================
  Hits        16706    16706           
  Misses      21293    21293           
  Partials      663      663           
Flag Coverage Δ
provider-base 16.29% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@pieqq pieqq left a comment

Choose a reason for hiding this comment

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

Question inline.

I found the internal issue where this was discussed, which brought some clarification. I'll update the bug description to match this, and also I think when this lands, the commit message should include this info.

providers/base/units/stress/jobs.pxu Outdated Show resolved Hide resolved
Copy link
Collaborator

@pieqq pieqq left a comment

Choose a reason for hiding this comment

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

I think you should use

requires:
  cpuinfo.type == 'GenuineIntel'

instead of using templated jobs. It will have the same effect: the jobs will be skipped on non-Intel platforms.

providers/base/units/stress/jobs.pxu Outdated Show resolved Hide resolved
@KaiChuan-Hsieh
Copy link
Contributor Author

@pieqq

I intend to make the platform other than Intel can't see the job, is it not allowed? It is why I use template, I don't know which is better.

@KaiChuan-Hsieh KaiChuan-Hsieh self-assigned this Apr 17, 2024
@pieqq pieqq force-pushed the intel-sleepgraph branch from 0cc85c7 to c6a1b02 Compare April 17, 2024 07:39
@pieqq
Copy link
Collaborator

pieqq commented Apr 17, 2024

@KaiChuan-Hsieh it's one way to do it, indeed, but we usually just go with the requires section instead, since we don't mind having skipped tests in our submissions. This is why you will see a lot of requires sections with a condition on cpuinfo.* in the CPU jobs, for instance.

@KaiChuan-Hsieh KaiChuan-Hsieh force-pushed the intel-sleepgraph branch 2 times, most recently from 0f496e9 to efaca2e Compare April 17, 2024 23:24
@KaiChuan-Hsieh
Copy link
Contributor Author

@pieqq

Hello,
I got my PR updated, would you please check it again?

Thanks,

Copy link
Collaborator

@pieqq pieqq left a comment

Choose a reason for hiding this comment

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

I wanted to find a better way to skip these jobs if a Nvidia GPU is detected, but the resource expressions in Checkbox are very tricky, and I couldn't find something simple.

That said, I made a comment inline and a suggestion. You will need to apply them to both stress/s3_pm-graph_30 and stress/s2idle_pm-graph_30 jobs and their related attachment jobs.

providers/base/units/stress/jobs.pxu Outdated Show resolved Hide resolved
providers/base/units/stress/jobs.pxu Show resolved Hide resolved
@KaiChuan-Hsieh
Copy link
Contributor Author

Upload submission of executing $ checkbox-cli run com.canonical.certification::stress-pm-graph
s2idle-no-nvidia.tar.gz
s2idle-nvidia.tar.gz

Copy link
Collaborator

@pieqq pieqq left a comment

Choose a reason for hiding this comment

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

Thanks!

@pieqq pieqq merged commit e1f796b into main Apr 18, 2024
13 checks passed
@pieqq pieqq deleted the intel-sleepgraph branch April 18, 2024 12:48
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