]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/ttm: add pgprot handling for RISC-V
authorIcenowy Zheng <uwu@icenowy.me>
Mon, 20 Oct 2025 05:35:23 +0000 (13:35 +0800)
committerChristian König <christian.koenig@amd.com>
Tue, 28 Oct 2025 08:19:46 +0000 (09:19 +0100)
commit4f9ffd2c80a2fa09dcc8dfa0482cb7e0fb6fcf6c
tree88218ab9ced7217263c31201516f1c4a366b7224
parenta80c98b6f0d900f820ea9c76c367348804c1e895
drm/ttm: add pgprot handling for RISC-V

The RISC-V Svpbmt privileged extension provides support for overriding
page memory coherency attributes, and, along with vendor extensions like
Xtheadmae, supports pgprot_{writecombine,noncached} on RISC-V.

Adapt the codepath that maps ttm_write_combined to pgprot_writecombine
and ttm_noncached to pgprot_noncached to RISC-V, to allow proper page
access attributes.

Signed-off-by: Icenowy Zheng <uwu@icenowy.me>
Tested-by: Han Gao <rabenda.cn@gmail.com>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
Link: https://lore.kernel.org/r/20251020053523.731353-1-uwu@icenowy.me
drivers/gpu/drm/ttm/ttm_module.c