-
Notifications
You must be signed in to change notification settings - Fork 90
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
Fix manual TDP being set too frequent #880
Conversation
Manual TDP was set every 1000 msec, in practice the SMU cannot handle faster then 1 Hz. Due to timing inaccuracies of the interval, sometimes this would be faster then 1000 msec, resulting odd issues like TDP not applying or worse, BSOD. Side note, this is also what AutoTDP is set to 1010 msec.
WalkthroughThe Changes
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on X ? TipsChat with CodeRabbit Bot (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files selected for processing (1)
- HandheldCompanion/Managers/PerformanceManager.cs (2 hunks)
Additional comments: 3
HandheldCompanion/Managers/PerformanceManager.cs (3)
35-37: The update to the
INTERVAL_DEFAULT
constant from 1000 to 3000 milliseconds aligns with the PR objective to mitigate issues with the SMU's handling of frequent TDP updates. This change should help avoid the timing inaccuracies that led to the TDP not being applied correctly or system crashes. Ensure that all related timers and operations that depend on this constant are tested to confirm that the new interval does not introduce any new issues.36-36: The
INTERVAL_AUTO
constant is set to 1010 milliseconds, which is slightly longer than the original 1000 milliseconds. This change is likely intended to avoid the timing issues mentioned in the PR objective. Verify that theautoWatchdog
Timer, which uses this constant, functions correctly with the new interval and that it does not conflict with the manual TDP setting.37-37: The
INTERVAL_DEGRADED
constant is set to 5000 milliseconds. While this change is not mentioned in the PR objective or the AI-generated summary, it's important to ensure that the degraded mode interval is appropriate for the system's needs and does not negatively impact the user experience during degraded operation.
Manual TDP was set every 1000 msec, in practice the SMU cannot handle faster then 1 Hz. Due to timing inaccuracies of the interval, sometimes this would be faster then 1000 msec, resulting odd issues like TDP not applying or worse, BSOD.
Side note, this is also what AutoTDP is set to 1010 msec.
Summary by CodeRabbit