From 7ef1b1f38a94bf54b215c4c56ea8d62ec607f73b Mon Sep 17 00:00:00 2001 From: Georg Veichtlbauer Date: Fri, 5 May 2023 22:54:31 +0200 Subject: Revert "kernel: Only expose su when daemon is running" This patch is no longer necessary because we no longer ship su add-ons, which is this patch initially designed for. Now it causes another issue which breaks custom root solution such as Magisk, as Magisk switches worker tmpfs dir to RO instead of RW for safety reasons and happens to satisfy MS_RDONLY check for su file, resulting in su file totally inaccessible. This reverts commit 08ff8a2e58eb226015fa68d577121137a7e0953f. Change-Id: If25a9ef7e64c79412948f4619e08faaedb18aa13 --- include/linux/dcache.h | 6 ------ 1 file changed, 6 deletions(-) (limited to 'include/linux/dcache.h') diff --git a/include/linux/dcache.h b/include/linux/dcache.h index d57e8a6c2f2c..c066f6b56e58 100644 --- a/include/linux/dcache.h +++ b/include/linux/dcache.h @@ -522,12 +522,6 @@ static inline bool d_is_fallthru(const struct dentry *dentry) return dentry->d_flags & DCACHE_FALLTHRU; } -static inline bool d_is_su(const struct dentry *dentry) -{ - return dentry && - dentry->d_name.len == 2 && - !memcmp(dentry->d_name.name, "su", 2); -} extern int sysctl_vfs_cache_pressure; -- cgit v1.2.3