Răsfoiți Sursa

fix(susfs-patches): add __fold_filemap_fixup_entry stub for <=30 kernels

The SUSFS patch calls __fold_filemap_fixup_entry() inside
CONFIG_KSU_SUSFS_OPEN_REDIRECT to fold fixup VMAs for 16K page size
compatibility. This function was added to the Android common kernel in
January 2026. For 6.6.30 and earlier kernels (2024-07), the header
<linux/pgsize_migration.h> exists but predates this function, causing
an 'undeclared function' compile error.

Add a guarded no-op inline stub that provides the function when the
kernel doesn't declare it yet.
TheWildJames 1 lună în urmă
părinte
comite
b435a9d699
1 a modificat fișierele cu 2 adăugiri și 0 ștergeri
  1. 2 0
      .github/actions/susfs-patches/action.yml

+ 2 - 0
.github/actions/susfs-patches/action.yml

@@ -104,6 +104,8 @@ runs:
         if [ "${{ inputs.sublevel }}" -le "30" ]; then
           echo "Applying taskmmu.c Android 15 6.6 Fake Patch"
           python3 -c 'import re;c=open("fs/proc/task_mmu.c").read();c=re.sub(r"(\t+\t\tif\s*\(\s*vma->vm_end\s*>\s*last_vma_end\s*\))\n(\t+\t\t\tsmap_gather_stats\(vma,\s*&mss,\s*last_vma_end\);)\n(\t+)\}",lambda m:m.group(1)+" {\n"+m.group(2)+"\n"+m.group(3)+"\t\tlast_vma_end = vma->vm_end;\n"+m.group(3)+"\t}\n"+m.group(3)+"}",c,count=1);open("fs/proc/task_mmu.c","w").write(c)'
+          echo "Adding __fold_filemap_fixup_entry stub for pre-2026 kernels"
+          sed -i '/^#include <asm\/elf.h>$/i #ifndef __fold_filemap_fixup_entry\nstatic inline void __fold_filemap_fixup_entry(struct vma_iterator *iter, unsigned long *end) { }\n#endif /* __fold_filemap_fixup_entry */\n' fs/proc/task_mmu.c
         fi
         if [ "${{ inputs.sublevel }}" -le "92" ]; then
           echo "Applying base.c Android 15 6.6 Fake Patch"