fix: from dmidecode get cpu num error#587
Merged
deepin-bot[bot] merged 1 commit intolinuxdeepin:develop/eaglefrom Dec 18, 2025
Merged
fix: from dmidecode get cpu num error#587deepin-bot[bot] merged 1 commit intolinuxdeepin:develop/eaglefrom
deepin-bot[bot] merged 1 commit intolinuxdeepin:develop/eaglefrom
Conversation
max-lvs
approved these changes
Dec 18, 2025
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: add-uos, max-lvs The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
fix from dmidecode get cpu num maybe error log: fix from dmidecode get cpu num maybe error bug: https://pms.uniontech.com/bug-view-343951.html
340558d to
5112422
Compare
deepin pr auto review我来对这个代码变更进行审查:
改进建议:
// 检查并更新核心数
if (coreNum_dmi > coreNum && coreNum_dmi <= MAX_CORE_COUNT) { // MAX_CORE_COUNT = 512
// 当/proc/cpuinfo的数据可能不准确时,使用dmidecode的数据作为参考
if (logicalNum != logicalNum_dmi) {
coreNum = coreNum_dmi;
}
}
// 检查并更新逻辑处理器数量
if (logicalNum_dmi > logicalNum && logicalNum_dmi <= MAX_LOGICAL_COUNT) { // MAX_LOGICAL_COUNT = 1024
logicalNum = logicalNum_dmi;
}
这些改进将使代码更加健壮、可维护,并且更容易理解。 |
Contributor
Author
|
/forcemerge |
Contributor
|
This pr force merged! (status: unstable) |
ac96bf6
into
linuxdeepin:develop/eagle
15 of 17 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix from dmidecode get cpu num maybe error
log: fix from dmidecode get cpu num maybe error
bug: https://pms.uniontech.com/bug-view-343951.html