Hi,
On 7/24/25 00:59, Bastian Blank wrote:
this is a set of backported patches to make the Xe driver in the stable
kernel not Oops when run on a machine with a page size that isn't 4k.
I see that patches on stable@, we won't take patches that can go this
way usually.
The full patchset[1] for later kernels has a bunch of extra changes, but
the stable kernel is old enough that we can get by with a number of
simple substitutions:
- replace SZ_4K with PAGE_SIZE when finding an alignment palatable to
the CPU
- replace PAGE_SIZE with SZ_4K when describing a memory layout in GPU
memory that uses 4k alignment regardless of host page size.
So on 4k, where PAGE_SIZE *is* SZ_4K, this does nothing, but it fixes
the Oops on boot for 16k (aarch64, loong64) and 64k (ppc64le) users.
Since these are derived from the proper fix, you can easily see when
they are no longer required.
Simon
[1]
https://lore.kernel.org/all/20250604-upstream-xe-non-4k-v2-v2-0-ce7905da7...@aosc.io/