Add a pre-compile check in the kernel Makefile to ensure that the path_umount function must be backtracked on
This commit is contained in:
@@ -24,10 +24,6 @@ obj-$(CONFIG_KSU) += kernelsu.o
|
||||
|
||||
obj-$(CONFIG_KPM) += kpm/
|
||||
|
||||
# Do checks before compile
|
||||
ifneq ($(shell grep -q "int path_umount" $(srctree)/fs/namespace.c; echo $$?),0)
|
||||
$(error -- Backporting path_umount is mandatory !! Read: https://kernelsu.org/guide/how-to-integrate-for-non-gki.html#how-to-backport-path-umount)
|
||||
endif
|
||||
|
||||
# https://github.com/tiann/KernelSU/pull/2102/files#diff-3a325663233178293ee38b8161f3be511a466af7e0156b9d03d5aed0497564bfR19
|
||||
IS_GKI := $(strip $(shell \
|
||||
@@ -250,6 +246,12 @@ ifneq ($(shell grep -Eq "^int path_umount" $(srctree)/fs/internal.h; echo $$?),0
|
||||
$(shell sed -i '/^extern void __init mnt_init/a int path_umount(struct path *path, int flags);' $(srctree)/fs/internal.h;)
|
||||
endif
|
||||
|
||||
# Do checks before compile
|
||||
ifneq ($(shell grep -q "int path_umount" $(srctree)/fs/namespace.c; echo $$?),0)
|
||||
$(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 ##
|
||||
ifeq ($(shell test -e $(srctree)/fs/susfs.c; echo $$?),0)
|
||||
$(eval SUSFS_VERSION=$(shell cat $(srctree)/include/linux/susfs.h | grep -E '^#define SUSFS_VERSION' | cut -d' ' -f3 | sed 's/"//g'))
|
||||
|
||||
Reference in New Issue
Block a user