Skip to content
Commit 278be836 authored by Icenowy Zheng's avatar Icenowy Zheng Committed by Huacai Chen
Browse files

LoongArch: Disable WUC for pgprot_writecombine() like ioremap_wc()



Currently the code disables WUC only disables it for ioremap_wc(), which
is only used when mapping writecombine pages like ioremap() (mapped to
the kernel space). But for VRAM mapped in TTM/GEM, it is mapped with a
crafted pgprot by the pgprot_writecombine() function, in which case WUC
isn't disabled now.

Disable WUC for pgprot_writecombine() (fallback to SUC) if needed, like
ioremap_wc().

This improves the AMDGPU driver's stability (solves some misrendering)
on Loongson-3A5000/3A6000 machines.

Signed-off-by: default avatarIcenowy Zheng <uwu@icenowy.me>
Signed-off-by: default avatarHuacai Chen <chenhuacai@loongson.cn>
parent 477a0ebe
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment