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

[linux-6.6.y] LoongArch: Update the flush cache policy #326

Merged
merged 1 commit into from
Jul 18, 2024

Conversation

MingcongBai
Copy link
Contributor

@MingcongBai MingcongBai commented Jul 18, 2024

fix when LoongArch s3 resume, Can't find image information

Ref: https://lore.kernel.org/loongarch/20240507074357.2156083-1-lijun01@kylinos.cn/

fix when LoongArch s3 resume, Can't find image information

Signed-off-by: Li Jun <lijun01@kylinos.cn>
Signed-off-by: Baoqi Zhang <zhangbaoqi@loongson.cn>
Signed-off-by: Jianmin Lv <lvjianmin@loongson.cn>
Signed-off-by: Biao Dong <dongbiao@loongson.cn>
@deepin-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign tsic404 for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@deepin-ci-robot
Copy link

deepin pr auto review

关键摘要:

  • flush_cache_last_level 函数中硬编码的地址 CSR_DMW1_BASE 可能不适用于所有Loongson架构,需要确认是否是正确的偏移量。
  • flush_cache_last_level 函数中的循环次数(cdesc->ways * 3cdesc->sets)可能会导致性能问题,应该评估是否有必要进行这样的循环。
  • flush_cache_last_level 函数中的 addr += 0x100000000000; 操作可能会导致地址溢出,应该检查是否有必要进行这样的操作。
  • flush_cache_last_level 函数缺少对 loongson_sysconf.nr_nodes 变量的有效性检查,可能会导致未定义行为。
  • flush_cache_last_level 函数缺少注释说明其用途和行为,应该添加相应的注释以提高代码的可读性。

是否建议立即修改:

@MingcongBai
Copy link
Contributor Author

Tested good on a Lemote 3A6000 board.

@MingcongBai MingcongBai changed the title LoongArch: Update the flush cache policy [linux-6.6.y] LoongArch: Update the flush cache policy Jul 18, 2024
@opsiff opsiff merged commit 9b99013 into linux-6.6.y Jul 18, 2024
6 of 9 checks passed
@MingcongBai MingcongBai deleted the bai/linux-6.6.y/loongarch64-sleep-fix branch July 22, 2024 06:06
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.

4 participants