Remove the KSU_COMPAT_GET_CRED_RCU flag from the Makefile and add a compile check for the path_umount function to ensure that the necessary validation is done before compilation.
This commit is contained in:
@@ -140,7 +140,6 @@ ifeq ($(shell grep -q "CONFIG_KDP_CRED" $(srctree)/kernel/cred.c; echo $$?),0)
|
|||||||
ccflags-y += -DSAMSUNG_UH_DRIVER_EXIST
|
ccflags-y += -DSAMSUNG_UH_DRIVER_EXIST
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ccflags-y += -DKSU_COMPAT_GET_CRED_RCU
|
|
||||||
ccflags-y += -DKSU_UMOUNT
|
ccflags-y += -DKSU_UMOUNT
|
||||||
|
|
||||||
# Add the get_cred_rcu function to cred.h if not already present
|
# Add the get_cred_rcu function to cred.h if not already present
|
||||||
@@ -206,6 +205,14 @@ $(shell sed -i '/^extern void __init mnt_init/a int path_umount(struct path *pat
|
|||||||
$(info -- SukiSU compat: adding 'int path_umount(struct path *path, int flags);' to $(srctree)/fs/internal.h)
|
$(info -- SukiSU compat: adding 'int path_umount(struct path *path, int flags);' to $(srctree)/fs/internal.h)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# Do checks before compile
|
||||||
|
ifeq ($(shell grep -q "int\s\+\path_umount" $(srctree)/fs/namespace.c; echo $$?),0)
|
||||||
|
$(info -- SukiSU: checks ok. Found path_umount)
|
||||||
|
else
|
||||||
|
$(info -- SukiSU: checks failed, abort.)
|
||||||
|
$(error -- Backporting path_umount is mandatory !! Read: https://kernelsu.org/guide/how-to-integrate-for-non-gki.html#how-to-backport-path-umount)
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
## For susfs stuff ##
|
## For susfs stuff ##
|
||||||
ifeq ($(shell test -e $(srctree)/fs/susfs.c; echo $$?),0)
|
ifeq ($(shell test -e $(srctree)/fs/susfs.c; echo $$?),0)
|
||||||
|
|||||||
Reference in New Issue
Block a user